You are here: PSPad forum > English discussion forum > adding 3 KeyWord sections and 1 Variable section
Posted by: Professor Bernd | Date: 2020-02-20 21:52 | IP: IP Logged
Hello Jan.
For AutoIt3 highlighter
Could you add 3 more Key Words sections and a section for variables?
Variables are easy to recognize: they start with a "$" sign. Example: $sLine
pspad:If you have more error "formats" in one output, I can offer you solution to add 2-3 log parser formats and all will be applied.
Would it be possible to add 3 log parsers, each with its own color? That would be very friendly.
Thank you very much.
Best regards,
Bernd.
Posted by: pspad | Date: 2020-02-21 05:16 | IP: IP Logged
Please note that PSPad general highlighter isn't for Autoit only.
Adding 3 another keywords sections will slow down highlighting.
Remove Value section will have influences of another languages.
I will try to find a way how to highlight variables without influence of anything else.
Posted by: pspad | Date: 2020-02-21 05:18 | IP: IP Logged
Adding another log parsers is planned. Do you really needs another 3 log parsers?
Please note, that if any logparser fits to content, PSpad will consider the line as "error" and jump there after compilation.
Posted by: pspad | Date: 2020-02-21 13:34 | IP: IP Logged
Added variable attribute with new option in User highlighter definition 'PHP style variable'
You will need to check it in user highlighter definition and remove '$' from autoit keyword chars
Edited 1 time(s). Last edit at 2020-02-21 13:34 by pspad.
Posted by: Professor Bernd | Date: 2020-02-21 15:59 | IP: IP Logged
Thanks for responding so quickly.
I didn't think it would be so difficult. Please excuse me.
.
Log parser
pspad:Adding another log parsers is planned. Do you really needs another 3 log parsers?
One additional log parser with its own color is fine.
pspad:Please note, that if any logparser fits to content, PSpad will consider the line as "error" and jump there after compilation.
The reason for a second LogParser is to highlight "Debug" messages with a different color than "Error" messages. If PSpad considers the line as "error" and jumps there after compilation, then a debug line should not look as "bad" as an error line.
Now I understand the problem, because then I also need a second function for highlighting with a different color via VBScript.
Example: markEditorLineA(integer)
Okay, one step at a time. What do you think is possible?
Posted by: Professor Bernd | Date: 2020-02-21 16:27 | IP: IP Logged
General Highlighter
pspad:Please note that PSPad general highlighter isn't for Autoit only.
Now I understand! I hadn't considered that this would affect all general highlighters.
pspad:Remove Value section will have influences of another languages
It is not necessary to remove the Value section because it has no effect on the AutoIt3 highlighter. (I had forgotten the influence on other languages.)
pspad:Adding 3 another keywords sections will slow down highlighting.
Then it must be enough if variables get their own color.
pspad:Added variable attribute with new option in User highlighter definition 'PHP style variable'You will need to check it in user highlighter definition and remove '$' from autoit keyword chars
Can you tell me more details about this? When I remove '$' from autoit keyword characters, then double-clicking on a variable in the AutoIt3 script will no longer select the variable completely.
Bernd.
Edited 2 time(s). Last edit at 2020-02-21 16:37 by Professor Bernd.
Posted by: pspad | Date: 2020-02-21 16:41 | IP: IP Logged
The new variable functionality will come in the next build
Posted by: Professor Bernd | Date: 2020-02-21 18:27 | IP: IP Logged
Thanks a lot.
Bernd.
Posted by: Professor Bernd | Date: 2020-03-02 01:23 | IP: IP Logged
The new PSPad version is available and contains 'PHP style variable' in the user highlighter.
To make the highlighting work I have to remove '$' from the autoit keyword chars. Also the '_' must be removed, otherwise you will get a broken highlighting (see screenshot).
But I cannot remove '$' and '_' from the autoit keyword char. This would prevent variable detection in all functions that use the %Word% variable, e.g. the Language Help and some of my VBScripts. Another example is when I double-click a varialbe, it is not completely marked for copying, deleting, etc.
Unfortunately I don't know a solution at the moment, but this is NOT an important feature, and you can put it on the 'Todo later' list.
Thank you very much for your hard work!
Bernd.
Posted by: pspad | Date: 2020-03-02 05:37 | IP: IP Logged
Can I get any source sample with all possible variables e.t.c.?
Editor PSPad - freeware editor, © 2001 - 2024 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR