Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.
|
Forum Index : Microcontroller and PC projects : PicoMiteVGA: Mode 2 Syntax Highlighting
Author | Message | ||||
Hawk Senior Member Joined: 15/07/2021 Location: AustraliaPosts: 141 |
Who is responsible for the syntax highlighting within the editor in Mode 2? Do they want the inconsistencies reported? Mostly the ones I have found seem related to new commands in MMBASIC. I love editting on the actual machine, and the editor makes that more enjoyable. I'm gradually getting more familiar with the cut'n'paste. It's different to all other systems that I've used. I grew up with Borland Turbo Pascal and Turbo C editors. I still have muscle memory of those editors. There is also an issue when lines are longer than can be displayed on the screen. The editor does not wrap around or scroll sideways to allow these lines to be modified. I need to change back to Mode 1 to edit them. Is this intentional? Thanks, Hawk |
||||
cosmic frog Senior Member Joined: 09/02/2012 Location: United KingdomPosts: 284 |
You can type EDIT 1 and that puts you automatically into mode 1 in the editor. |
||||
matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 9129 |
The editor highlights inbuilt commands and inbuilt functions. It does not and cannot highlight secondary words in commands (e.g. IMAGE in LOAD IMAGE). Nor will it highlight pseudo commands (e.g. CAT) which are converted into real commands (INC) This is how it is designed to work and again will not be changed. Remember colour coding also works in mode 1 in the latest release Edited 2023-05-11 00:07 by matherp |
||||
Volhout Guru Joined: 05/03/2018 Location: NetherlandsPosts: 4250 |
Hi Hawk, You can type EDIT 1 to start the editor in mode 1 I have pre-programmed this under function key 1 OPTION F1 "EDIT 1"+chr$(13) Regards, Volhout PicomiteVGA PETSCII ROBOTS |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 6798 |
You can press F4 to jump from the command line to the editor in the current mode. EDIT n forces the editor to run in mode n, no matter what the current mode is. Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
Hawk Senior Member Joined: 15/07/2021 Location: AustraliaPosts: 141 |
Thanks. The reason I asked is that I have seen some secondary words highlighted and some not, for the same command. Thanks for the tip about the Edit 1. I was no aware of that, but I have upgraded to V5.07.07 and have not noticed syntax highlighting in Mode 1. Does it need to be enabled in the OPTIONs seperately to the Mode 2 syntax highlighting? Your tips will make developing on the actual machine even more enjoyable. Hawk Edited 2023-05-11 12:36 by Hawk |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 6101 |
Hawk Some parameters are also keywords so they will always be highlighted. The highlighting is system wide and not checked for context. That would be a heavy load on the pico. Jim VK7JH MMedit MMBasic Help |
||||
Hawk Senior Member Joined: 15/07/2021 Location: AustraliaPosts: 141 |
The highlighting is system wide and not checked for context. That would be a heavy load on the pico. Jim Thanks Jim, that would explain the behaviour that I'm seeing. Hawk |
||||
Hawk Senior Member Joined: 15/07/2021 Location: AustraliaPosts: 141 |
Remember colour coding also works in mode 1 in the latest release Peter, is there something special that I need to do to enable syntax colour highlighting in Mode 1? I already have syntax colour highlighting working in Mode 2, but Mode 1 is still monochrome. Oops...looks like I found the answer. Not quite what I expected. When in Mode 1, "edit" runs in monochrome using the currently set font. When in Mode 2, "edit" runs in syntax colour highlighting using the currently set font. When in Mode 1 or Mode 2, "edit 1" runs in syntax colour coding in what I assume is the default font 1 (not the currently selected font). When in Mode 1 or Mode 2, "edit 2" runs in syntax colour highlighting using the currently set font. Is this behaving as expected? I was surprised that "edit 1" changes the font, but "edit 2" doesn't. I was also surprised that "edit" in Mode 2 uses the OPTION setting for syntax colour highlighting, but "edit" in Mode 1 ignores the OPTION setting and give monochrome text. Hawk PicoMiteVGA MMBASIC Version 5.07.07 Edited 2023-05-16 21:59 by Hawk |
||||
Martin H. Guru Joined: 04/06/2022 Location: GermanyPosts: 1114 |
try "Option COLORCODE ON" to turn on Mode 1 Syntax Highlighting 'no comment |
||||
matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 9129 |
The code is doing what it should. In mode 1 only font 1 can be colour coded. In mode 2 any font will work as it is a colour mode. It doesn't change the font if already in mode 1 as you may want to use a different font (e.g. font 7) to get more characters on the screen. |
||||
Hawk Senior Member Joined: 15/07/2021 Location: AustraliaPosts: 141 |
I already have that OPTION set. The results I described are with OPTION COLOURCODE ON. Hawk |
||||
Hawk Senior Member Joined: 15/07/2021 Location: AustraliaPosts: 141 |
Thanks for the confirmation Peter. I thought that I must've had a setting wrong. Cheers, Hawk. |
||||
Hawk Senior Member Joined: 15/07/2021 Location: AustraliaPosts: 141 |
Hi @geoffg, this information regarding "edit" vs "edit 1" in Mode 1 might be good to add the PicoMiteVGA User Manual in the section on the Full Screen Editor - Colour Coded Display Editor (P.16) Cheers, Hawk |
||||
Print this page |