[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Nano-devel] Whitespace display mode: extend it to handle newlines?
From: |
Benno Schulenberg |
Subject: |
Re: [Nano-devel] Whitespace display mode: extend it to handle newlines? |
Date: |
Mon, 29 Oct 2018 12:54:30 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 |
Op 26-10-18 om 01:06 schreef David Ramsey:
> One thing I've noticed with whitespace display mode for awhile is that, while
> it displays characters for tabs and spaces, it doesn't display anything for
> newlines.
Probably because it's superfluous. The point of showing whitespace as
visible characters is: 1) to see the difference between tabs and spaces,
and 2) to see where there are trailing blanks. Showing another character
for a newline doesn't help to distinguish anything extra (in normal mode).
> I was wondering if there's any interest in that feature, especially since
> softwrap mode can make it harder to determine where actual newlines are.
In softwrap mode it can help. I made a patch for it long ago, but didn't
like the result: the visual cue is too small. And nowadays, the linenumbers
toggle gives a much clearer indication of where lines start.
(Your patch has a small problem, by the way. When in normal mode a line in
the middle of a paragraph is exactly as long as the screen is wide, press
<End> on that line and then <Home>. See how the ↵ is printed at the start
of the next line.)
> Note that it provides no documentation yet, and also refuses to work with a
> nanorc containing a two-character whitespace string. (I'm not sure how to fix
> the latter; maybe allow a variable-length string for whitespace, as long as
> it's between 1 and 3 characters long?)
I would be more of a mind to remove the configurability of the whitespace
replacements characters. In the beginning, M-P worked only when the
whitespace option was given with two visible characters in the nanorc
file. But since nano-2.3.3, M-P shows visible characters by default.
Do you think that anyone has added 'set whitespace "..."' to their
nanorcs since then? I doubt it. And if a few people have done so, would
they be seriously inconvenienced if we dropped back to showing always dot
and chevron for space and tab?
Benno
signature.asc
Description: OpenPGP digital signature