Page 1 of 2

XML lexer not using colors

Posted: 12.04.2022 21:28
by ertank
Hello,

I have an XML that is about 1.5MB in size. This file has about 48000 lines and none of them is longer than 100 chars. When I open that file, XML lexer is used. However, It does not color highlight the file except the first line. Sample screen capture is attached.

File using end-of-line chars as LF but changing it to CRLF does not help either. I do not see any update for XML lexer in Update add-ons screen.

Manually switching to XML Lite lexer is my current work around.

I appreciate any help.

Thanks & Regards,
Ertan

Posted: 13.04.2022 15:01
by main Alexey
That is good question. I wrote the reply, now, to the wiki--
https://wiki.freepascal.org/CudaText#Wh ... _XML_lexer

Posted: 13.04.2022 20:02
by ertank
I personally liked option

Code: Select all

"ui_max_size_lexer":2
Modified it in Settings - user and all is fine now.

Thanks for the wiki.

Posted: 14.04.2022 03:32
by main Alexey
But for your case, option for 'folding' was more appropriate..

Posted: 14.04.2022 10:20
by main Alexey
Made a change. from the next version, XML lexer will show more syntax highlight even when 'folding' is blocked by the option. will be almost like lite lexer.

you can update the file "XML.lcf" from GitHub and see it.

Posted: 16.04.2022 01:45
by ertank
Right, it does work with long lined files. But, I find number color Navy to be a bit difficult to read on my theme setting. Comparing it with XML Lite lexer.

Thanks for the feature.

Edit: Navy color is better on my ViewSonic monitor and difficult to read on Asus monitor. I take it depends on the monitor capabilities, too.

Posted: 16.04.2022 12:22
by main Alexey
I see that Navy color is not okay for that theme. is it your handmade theme? seems it is. so you must adjust it-- in "Options / settings - theme - syntax". (or choose another theme. another SYNTAX theme.)

Posted: 16.04.2022 20:03
by ertank
It is stock ebony theme

Posted: 18.04.2022 07:51
by main Alexey
I think you chosen 'ebony' UI-theme + ANOTHER syntax-theme! Syntax-theme 'ebony' shows here not colors like yours, e.g. 'numbers' style is much more lighter.
check the dialog Options/Themes again - what is syntax-theme?

Posted: 18.04.2022 13:23
by ertank
I have both set to ebony in my Themes settings