nano-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: line folding


From: Benno Schulenberg
Subject: Re: line folding
Date: Thu, 17 Oct 2024 11:17:53 +0200
User-agent: Mozilla Thunderbird


But what should M-[ do by default, when nothing is selected and the cursor is on a normal line?

Perhaps the same thing as Alt+PageUp/Down does for anchors?

If nothing is selected...

* ...and no group of lines has been folded, display the message...
     [ There are no folded lines; to fold lines, first select them ]

Hmm.  I don't like the idea of having to select something first,
but... maybe that is the best way because the most versatile: the
user can choose exactly what they want to fold.

* ...and if lines have been folded, go to the next group of folded lines?

Oh!  That's interesting.  That way one could quickly unfold any
folded areas by repeatedly hitting M-[.  Nice.

I would expect M-[ to do some default folding action, for example: from the current line until the next blank line, or: when the cursor is somewhere in a block (delimited by blank lines), to fold that block...

I'm afraid that might be terrifying for some users, watching their lines "disappear" because they've pressed the wrong key.

Hmm...  Yes, maybe.  But... the folded lines will be replaced by a line
that says "folded xx lines", and they can be immediately unfolded again
with another M-[.  If the user does not know what key they hit, maybe
M-U should also undo a folding action?


Benno

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]