no XML highlighting for 40M XML file

ertank
Posts: 61
Joined: 06.06.2021 21:56

no XML highlighting for 40M XML file

Post by ertank »

Hello,

I sometimes use considerably big XML files like 4-5MB in size. When I open such a file, I see no XML highlighting as I used to see in smaller files. I tried to find setting about highlighting file size limit but I could not.

Is there anything that I can to to make it work such files color displayed?

Thanks & Regards,
Ertan
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

This is
"ui_max_size_lexer": 2

but... for XML bigger than 2Mb you must see XML^ lite lexer active! so coloring must be present anyway. It is file data/lexliblite/XML.*
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

Pls upload that big XML file, so I can test on it.
ertank
Posts: 61
Joined: 06.06.2021 21:56

Post by ertank »

Attached is an xml file sample big in size.
Attachments
Mails.7z
(3.53 MiB) Downloaded 182 times
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

Ahh! It is 42M file which has SINGLE LINE (no EOLs). CudaText don't highlight lines >4000chars. sorry. Atom editor also does this. (VSCode too?)
ertank
Posts: 61
Joined: 06.06.2021 21:56

Post by ertank »

I don't use Atom editor or VSCode for such files. Cannot comment for them.

I confirm Notepad++ highlights that particular file as a single line.

BTW, my intention is not highlighting it as a single line. First, I "pretty print" (convert to indented multi line) it and after start working on it.

I do not know if I can set a limit for XML formatter to have it work on such file. When I check plugin options I only see tab_size and max_width
Alexey
Posts: 1633
Joined: 05.10.2012 22:10

Post by Alexey »

If you use pretty-print (in CudaText the CudaFormatter exists) you can work with it. syntax will be hilighted for lines<4000 chars.
So install CudaFormatter + XML-formatter, call it to format.
Did you try CudaFormatter + XML formatter?
Alexey
Posts: 1633
Joined: 05.10.2012 22:10

Post by Alexey »

Ah! I see that CudaFormatter don't work for 'XML^' lite lexer! will fix that soon.
uvviewsoft
Posts: 392
Joined: 01.12.2020 13:46

Post by uvviewsoft »

The addon was fixed now- 'formatter: XML_Pretty_Print'. it supports XML^ lexer. But for your example 40M file I got such result - broken encoding, again. so I guess file is not good UTF8 text.
Attachments
xml--.png
ertank
Posts: 61
Joined: 06.06.2021 21:56

Post by ertank »

Should be no problem with file encoding. It is slow but I can work with it on Notepad++

Attached is a video that I could keep as small as possible.
Attachments
Media3.7z
(4.7 MiB) Downloaded 184 times
Post Reply