nano-devel
[Top][All Lists]
Advanced

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

Re: thoughts on status messages


From: Benno Schulenberg
Subject: Re: thoughts on status messages
Date: Fri, 12 Mar 2021 12:33:35 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0

Op 10-03-2021 om 17:10 schreef Mike Frysinger:
> On 07 Mar 2021 12:20, Benno Schulenberg wrote:
>> From this I guess that a keystroke that reshows the last shown message
>> would already be a great help?
> 
> that would mitigate it a bit.  if you have more than one error message,
> things would get clobbered.  but i guess if the message is maintained on
> a per-buffer basis rather than per-session, it wouldn't be so bad.  e.g.
> if i open 10 files and 3 have errors, i would want to see the error for
> the respective file when i flipped to the buffer for it.

The most likely 'error' to occur during startup is "File is unwritable".
Other possible errors are that the path is inaccessible, or the filename
is a directory or a device file, or there is a bad locking file, things
like that.  Only one of these errors can occur (per buffer), so storing
the first error message per buffer and showing it (just once) when the
buffer is switched to should do the trick.

There could also be errors in the nanorc files, but that message would
come after any of the above errors, so it would be ignored, because it's
not the first error message.  The actual descriptions of the rc errors
will still be written to the terminal when exiting from nano.

>> With --stateflags, a modified buffer is indicated by a star after the
>> file name (in the title bar or in the mini bar).  When a file is not
>> writable, maybe a minus or equals sign could be shown?  And when this
>> unwritable buffer was modified, an exclamation mark?
> 
> i know the editor is tight on space, but i always flinch when i see a string
> of LxJ&(*a{} and i'm supposed to know what they mean.

I understand.  But in this case the - and ! would appear instead of the *,
so without knowing what they mean, one can guess that have something to do
with the (non-)modification of the buffer.  There would have been a "File
is unwritable" message at the beginning, and the - and ! would just be a
reminder for those that switch between multiple buffers.

>> I don't really see the need to indicate the line ending somewhere, as I
>> think DOS-formatted files are getting exceedingly rare on Unix systems.
> 
> if you spend your entire life in UNIX, then this is prob accurate.  but as
> soon as you have to work or collaborate cross-platform, it comes up quite
> often.  i'll point out that there's an active Windows port of nano, and at
> least a few users of it (including myself every few months).

I see.  But elsewhere you've said you use 'set noconvert', so for you the
format of the current buffer will be much more obvious than with a little
letter somewhere in a corner of the screen.

But basically I don't know where to put an indication of "DOS format".  I
don't want to put it among the state flags, as those are flags about the
state of the editor.  All I can think of is to replace the [x/n] indicator
in the top-left corner with (DOS) for buffers that are in DOS format.  That
would hide the information of how many buffers there are, but... one can't
have everything.

Benno

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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