Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Maximum length of a line in Notepad++

Tags:

notepad++

I wonder whether it is possible to work out the maximum length per line in Notepad++ and highlight only those lines exceeding a certain threshold. I know there is a way to do it indirectly by customising the vertical edge, but it would not be feasible if you have a long document to scroll.

Thanks,

I.

like image 831
paranzana Avatar asked Aug 30 '13 16:08

paranzana


People also ask

Is there a limit on Notepad?

Text files used by Notepad should be no larger than 45K. Notepad cannot open a file that exceeds 54 kilobytes (K) in size and does not allow you to continue editing a file if the file size reaches between 45K and 54K.

Does Notepad ++ have a line limit?

“The length limit is 1024 characters; this includes the match line number information and other formatting.”

How long can a line be in a text file?

Nonetheless, lines are simply delimited and may be any length. mode): 32767, otherwise 2147483647 characters. Longer lines are split. Maximum number of lines 2147483647 lines.

What is the maximum length of a line?

Traditional line length research, limited to print-based text, gave a variety of results, but generally for printed text it is widely accepted that line lengths fall between 45 and 75 characters per line (cpl), though the ideal is 66 cpl (including letters and spaces).


1 Answers

You can look for lines longer than a given threshold as follows:

Edit -> Find -> Select "Regular expression" in "Search Mode", look for .{x,} where x is your desired threshold (e.g. .{15,} to look for lines that are 15 characters or longer).

. is a wild-card and {x,} means x or more of what appears before it, so .{x,} means x or more of any combination of characters.

Also make sure that the . matches newline option is not checked, otherwise it won't work.

I'm not sure if this helps, but that's about as much as you can do only using Notepad++.

like image 183
Bernhard Barker Avatar answered Sep 24 '22 19:09

Bernhard Barker