Page 1 of 1

Rainmeter lexer

Posted: 20.12.2022 21:38
by sl23
In Rainmeter skins, there is often a second usage for square brackets, for example:

Code: Select all

MouseOverAction=[!SetOption #CURRENTSECTION# StrokeAlpha "Stroke Color #Green#"][!SetOption #CURRENTSECTION#Free Text "##CURRENTSECTION#Name#"][!ShowMeter #CURRENTSECTION#Free][!UpdateMeter *][!Redraw]
Would it be possible to show these in a specified colour? Preferably separate from the Section colouring of square brackets.

The same for the Pipe symbol:

Code: Select all

Shape=Ellipse 0,0,5 | Extend FillColor | StrokeWidth 2 | Extend StrokeAlpha
I have very little experience programming so haven't a clue how to follow the tutorial btw, I have looked at it. I'll take a look again when i have more time.

Thanks for any advice.

Posted: 21.12.2022 09:52
by main Alexey
Pls change the title of the topic: not INI lexer, but Rainmeter lexer. You need 'Rainmeter' lexer from AddonsManager.

Posted: 21.12.2022 10:25
by sl23
I tried the Rainmeter lexer in notepad++ but didn't like how it worked. I just want to tweak the ini lexer to highlight these two things.

Can I do that or is it better to create a new lexer?

I'll give the CT version a go, didn't know there was one!
Thanks

Posted: 21.12.2022 10:27
by main Alexey
Plugins / Addons Manager / Install,
find 'Rainmeter' lexer and install it.
Pls test with it and suggest for it.

Posted: 21.12.2022 10:35
by sl23
OK thanks Alexey, I'll try that out later :D

Posted: 21.12.2022 10:38
by main Alexey
As I see, this lexer already highlightes many things, also [] and pipe-char, also quoted strings and #names# and !names.

Posted: 21.12.2022 10:41
by main Alexey
If you did not know, how to open .ini files with another lexer:
https://wiki.freepascal.org/CudaText#File_types_config

Posted: 21.12.2022 13:14
by sl23
That didn't cross my mind, but definitely required information thanks for the link! :)