Author |
Topic: Limitations of Syntax Coloring (Read 3162 times) |
|
Richard Russell
Administrator
member is offline


Posts: 1348
|
 |
Re: Limitations of Syntax Coloring
« Reply #27 on: Sep 24th, 2016, 08:47am » |
|
on Sep 24th, 2016, 06:41am, tsh73 wrote:| does LBB IDE uses Alt-Shift for anything? |
|
No, but something strange is happening here (Windows 10 laptop) because if I press and release Alt - rather than using Alt+letter as a menu shortcut - it seems to freeze the LBB IDE. If that's happening to you too it may well impact on your hotkey.
I'm away from home at the moment so I can't investigate further, but that should definitely not be happening.
Richard.
|
|
Logged
|
|
|
|
Richard Russell
Administrator
member is offline


Posts: 1348
|
 |
Re: Limitations of Syntax Coloring
« Reply #28 on: Sep 24th, 2016, 12:07pm » |
|
on Sep 24th, 2016, 06:41am, tsh73 wrote:| does LBB IDE uses Alt-Shift for anything? |
|
Further to my earlier reply, although LBB doesn't use Alt+Shift itself, Rich Edit controls do, and of course the LBB editing pane is a Rich Edit control. There is a list of keyboard shortcuts here and you will notice that it includes Alt+Shift+X, Alt+Shift+Ctrl+F11 and Alt+Shift+Ctrl+F12.
So it is possible that the Rich Edit control is intercepting your Alt+Shift hotkey and preventing it doing what it normally does. Probably Alt+Shift is a poor choice of hotkey if it is already used for other purposes in standard Windows components like the Rich Edit control.
Richard.
|
|
Logged
|
|
|
|
tsh73
Full Member
member is offline


Gender: 
Posts: 210
|
 |
Re: Limitations of Syntax Coloring
« Reply #29 on: Sep 24th, 2016, 4:15pm » |
|
Quote:| Probably Alt+Shift is a poor choice of hotkey |
|
It's default Windows language switching hotkey. That mean bigger part of Russia and what not uses it on daily basis, at least since Windows 3x.
|
|
Logged
|
|
|
|
Richard Russell
Administrator
member is offline


Posts: 1348
|
 |
Re: Limitations of Syntax Coloring
« Reply #30 on: Sep 24th, 2016, 9:19pm » |
|
on Sep 24th, 2016, 4:15pm, tsh73 wrote:| It's default Windows language switching hotkey. |
|
There's clearly an anomaly in Microsoft having used the same key combination as both a language-switching hotkey and as a modifier for some Rich Edit keyboard shortcuts. It's exactly the sort of thing they are usually careful to avoid.
I see that (from Windows 8 onwards anyway) you can use Windows+Space as a hotkey to bring up the language-selection menu, so I wonder if that might be a workaround for your issue. On this PC Windows+Space allows me to switch between a UK and US keyboard layout.
Richard.
|
|
|
|
Richard Russell
Administrator
member is offline


Posts: 1348
|
 |
Re: Limitations of Syntax Coloring
« Reply #31 on: Sep 25th, 2016, 12:45pm » |
|
on Sep 24th, 2016, 08:47am, Richard Russell wrote:| something strange is happening here (Windows 10 laptop) because if I press and release Alt - rather than using Alt+letter as a menu shortcut - it seems to freeze the LBB IDE. |
|
I've now had a chance to check this on other machines and the problem seems to be specific to this Windows 10 laptop. I've tested it on Windows XP, Windows 7, Windows 8.1 and a desktop Windows 10 PC and in every case pressing-and-releasing Alt works normally. So it doesn't seem likely that whatever is causing this problem is related to the Alt+Shift hotkey issue.
It has nevertheless been interesting to discover the keyboard shortcuts built into the Rich Edit control, a few of which could be genuinely useful in LBB. For example you can enter any character by typing its hexadecimal code value and then pressing Alt+X, so to enter a capital eth character you can type 00D0 followed by Alt+X giving Ð
Richard.
|
|
Logged
|
|
|
|
tsh73
Full Member
member is offline


Gender: 
Posts: 210
|
 |
Re: Limitations of Syntax Coloring
« Reply #32 on: Sep 25th, 2016, 2:20pm » |
|
Hello Richard it happens that I have previous versions of LBB saved on a harddisk so I can check.
So: Sintax coloring with richtextbox appeared in version 3.0 Versions 3.0, 3.01,3.02,3.03 - language switching with Alt-Shift works Versions 3.04,3.05,3.06 - language switching with Alt-Shift no more work.
So it is something introduced in version 3.4. May be this? Quote:IDE enhancements: The IDE now incorporates a combobox in which are listed all the branch labels, SUBs and FUNCTIONs in the currently loaded program. Selecting one of these causes the editor to jump directly to the appropriate program line. You can choose whether to sort the list alphabetically or in the order in which the items appear in the program. |
|
|
| « Last Edit: Sep 25th, 2016, 2:20pm by tsh73 » |
Logged
|
|
|
|
Richard Russell
Administrator
member is offline


Posts: 1348
|
 |
Re: Limitations of Syntax Coloring
« Reply #33 on: Sep 25th, 2016, 3:44pm » |
|
on Sep 25th, 2016, 2:20pm, tsh73 wrote:| So it is something introduced in version 3.4. |
|
Well, the first thing to say is that Alt+Shift works here in LBB 3.06: If I press that key combination the language indicator in the Taskbar switches between 'ENG' and 'ENG US'. So whatever the problem is, it is not universal.
The change in v3.04 that affected your system was probably running the Rich Edit control in a separate thread in order to improve the support for Unicode, particularly the entry of complex script languages like Arabic. Up to version 3.03 the control was run in the same thread as the rest of the IDE.
As you will appreciate, I would not want to reverse that change - users who need support for Arabic (like SarmedNafi) would not be happy! Running the Rich Edit control in a separate thread also improves performance with multi-core CPUs. In any case there is no good reason why it should affect hotkeys.
So all things considered, and especially given that Alt+Shift works perfectly here in LBB 3.06, I am not contemplating making any changes.
Richard.
|
|
|
|
Richard Russell
Administrator
member is offline


Posts: 1348
|
 |
Re: Limitations of Syntax Coloring
« Reply #34 on: Sep 25th, 2016, 4:02pm » |
|
on Sep 25th, 2016, 3:44pm, Richard Russell wrote:| Well, the first thing to say is that Alt+Shift works here in LBB 3.06 |
|
Just checked it on my other machines: the Alt+Shift language switching is working perfectly in LBB 3.06 with Windows 7, Windows 8.1 and Windows 10.
Richard.
|
|
Logged
|
|
|
|
tsh73
Full Member
member is offline


Gender: 
Posts: 210
|
 |
Re: Limitations of Syntax Coloring
« Reply #35 on: Sep 25th, 2016, 5:20pm » |
|
Checked on another my machine and another virtual one, LBB 3.06. Alt-shift works. So it dosn't work only with my main home pc. Ah well. I could live with it. EDIT and on my job PC it does't work as well.
|
| « Last Edit: Sep 26th, 2016, 06:19am by tsh73 » |
Logged
|
|
|
|
CryptoMan
New Member
member is offline


Gender: 
Posts: 46
|
 |
Re: Limitations of Syntax Coloring
« Reply #36 on: Sep 26th, 2016, 2:49pm » |
|
Fixedsys Excelsior works fine with Turkish.
Thanks.
|
|
Logged
|
|
|
|
CryptoMan
New Member
member is offline


Gender: 
Posts: 46
|
 |
Re: Limitations of Syntax Coloring
« Reply #37 on: Sep 26th, 2016, 2:51pm » |
|
Alt-Shift works properly with Turkish Keyboard Windows 10.
|
|
Logged
|
|
|
|
Richard Russell
Administrator
member is offline


Posts: 1348
|
 |
Re: Limitations of Syntax Coloring
« Reply #38 on: Sep 26th, 2016, 3:40pm » |
|
on Sep 25th, 2016, 5:20pm, tsh73 wrote:| Ah well. I could live with it. |
|
Nevertheless the inconsistent behaviour is strange and annoying. Even though I keep several different PCs here, with different versions of Windows and different setups in other respects (a better test than using VirtualBox IMHO), I still can't hope to check every possible configuration.
It's evidently not just an LBB problem either; if you Google for 'Alt+Shift not working' there are many hits. You can change the hotkey (in Windows 10 it's under 'Control Panel... Clock, Language and Region... Language... Advanced settings... Switching input methods... Change language bar hot keys') so it's possible an alternative key combination might work more reliably.
Richard.
|
|
Logged
|
|
|
|
bluatigro
Full Member
member is offline


Gender: 
Posts: 111
|
 |
Re: Limitations of Syntax Coloring
« Reply #39 on: Sep 30th, 2016, 12:42pm » |
|
i wood like to have numbers a differend color then the other stuf and array's and function's too
explanation : i have a eye-problem and have difecultys whit 1's,l's and I's
|
|
Logged
|
|
|
|
Richard Russell
Administrator
member is offline


Posts: 1348
|
 |
Re: Limitations of Syntax Coloring
« Reply #40 on: Sep 30th, 2016, 2:51pm » |
|
on Sep 30th, 2016, 12:42pm, bluatigro wrote:| I wood like to have numbers a differend color |
|
Parsing numbers accurately is tricky, since there are so many different formats (leading minus sign, decimal point, exponent etc.). LBB's syntax coloring uses simple rules that can't easily be extended to numbers.
Quote:| i have a eye-problem and have difecultys whit 1's,l's and I's |
|
Unfortunately coloring numbers differently won't always solve this problem. Consider these two variable names:
Code: The first is ba followed by the number eleven and the second is the word ball but they are almost identical, even to somebody with good eyesight! Because neither of them is a number they would not be colored differently even if LBB supported that feature, and they are not colored differently either in LB 4 or in Liberty BASIC Workshop.
So you could try using LBW (it interfaces very nicely with LBB; there are instructions here) but syntax coloring is not a complete solution to the problem.
Richard.
|
|
Logged
|
|
|
|
net2014
New Member
member is offline


Posts: 37
|
 |
Re: Limitations of Syntax Coloring
« Reply #41 on: Dec 13th, 2017, 2:41pm » |
|
Although I have been using LBB for quite a long time now, I have only just discovered that the syntax colouring problem manifests itself in the same way when LBB is run with linux/wine. My language setting is English-UK and many fonts tried. My programs do not contain any foreign characters. Whether that helps or not I don't know, but I am not expecting a solution - I can live without colouring as I obviously have done for some time! Just thought I would add to the gathered knowledge.
|
|
Logged
|
|
|
|
|