unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Xah <xahlee@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: emacs mode line suggestions
Date: Sat, 15 Nov 2008 17:54:02 -0800 (PST)	[thread overview]
Message-ID: <15962952-6180-41bd-abce-1b919aa55807@v13g2000pro.googlegroups.com> (raw)
In-Reply-To: mailman.423.1226741023.26697.help-gnu-emacs@gnu.org

On Nov 15, 1:23 am, Eli Zaretskii <e...@gnu.org> wrote:
> > From:Xah<xah...@gmail.com>
> > Date: Fri, 14 Nov 2008 15:18:31 -0800 (PST)
>
> > • that the buffer location percentage should by default not shown if
> > emacs is running in GUI with scroll bar.
>
> This is already the default on _all_ types of displays, and has been
> so since day one, even when Emacs didn't support scroll bars.

umm? on my carbon emacs (based on emacs 22.x), it still show cursor
location percentage.

In my x11 emacs running in gui (emacs 21.x) with scroll bar, it also
shows this percentage.

> > • clicking on the file name should not switch buffer.
>
> That's not the file name, that's the buffer name.

please get the over all picture, not bone picking.

> As for what it should do, I don't see why your preference is better
> than the current one.  Popping a menu requires another click to
> actually select a buffer, whereas the current behavior does it in one
> click.

typically, a user has several user buffers open, and as far as i guess
many programers who use emacs extensively has like hundreds of buffers
open. Cycling them one by one is not much useful.

Counting emacs's own buffers, those info, messages, scratch,
completions, grep output, shell output, C-h f and friends output,
dictionary lookup output, ispell output, man page output ... etc...
these are typically looked once and not useful afterwards. Switching
and cycling thru them are not much useful.

> Since there's a menu-bar menu item to do what you want, I
> don't see a problem.

it's more about what would be a useful behavior for clicking on the
buffer name section of mode line, not about whether suggested
functionality already exists somewhere. For example, the functionality
of cycling thru buffers also is already in the menu under Buffers.

i don't necessarily disagree with every point you make. But please
consider the over all suggestion, as opposed to seeming to have a nay-
say attitude and turn down the whole thing.

> > • Minor mode should not be displayed there. It's confusing.
>
> Emacs always displayed it.  Get used to it.

the question is not about what emacs is. It is about what is better
for emacs.

if we already stick with what emacs always has been, there'd be no
progress.

here's a refined suggestion on the minor mode in mode line point:

• Minor mode should not be displayed in mode line. It's confusing. For
one reason, it by default selectively display only some of the minor
modes currently on, and the selective process is not something people
who intuitively understands. For the other reason, Emacs's technical
concept of Minor mode is somewhat confusing. Most minor modes in
practice are Preferences settings (Mac-speak) or Options (Windows-
speak and Linux Desktops) from user point of view.

> > • Clicking on the major mode name should pop up a contextual menu to
> > let user switch to major major modes.
>
> Switching a major mode is a very rare command, so having this at your
> fingertips makes no sense, IMO.

switching between modes is not rarely used. I'd estimate it is used
every other hour at least.

> > • line number mode should be on by default. So that, the line number
> > shows in the mode line.
>
> This already is the default.

Opps, you are right. Thanks.

> > The coding system shown in mode line should be removed. The current
> > coding system should be shown in the menu somewhere
>
> It's an important piece of information, and takes only one position in
> the mode line.  I always hated the way IE and Outlook hide this
> somewhere under View, because I might wish to know the current
> encoding even if I don't need to switch it.
>
> > and allow users to change [coding system] thru menu.
>
> Emacs does have the change encoding part in the menu.

I have refined my previous writings about the mode line suggestions.
It has more neutral wording, with more explanations. This came in part
when i just filed a bug report to GNU as suggestions so that
developers have a chance to review this opinion.

Please give it another try. The url is here:

• Emacs's Mode Line Modernization Suggestions
http://xahlee.org/emacs/modernization_mode_line.html

plain text version follows:
-----------------

Emacs's Mode Line Modernization Suggestions

Xah Lee, 2008-12

This article gives some suggestions on improving emacs's “mode line”,
so that it is more intuitive and useful.

I think the mode line is one of emacs's problem in usability.
emacs mode line

above: Emacs's mode line.

Here's what i think are better default:

• The start of the mode line, displaying the coding system used such
as “-u”, “-uuu”, and displaying the modification status like “:**”, “%
%”, “%*” are quite cryptic. Having used emacs for 10 years, these are
still not burned into my brain. And it's not easy to look them up what
they are unless you are emacs diehard. (e.g. you'll have to know it's
technically called “mode line”, then you'll have to know about emacs-
index-search, and in general familiar with info and emacs)

It'd better to instead say “Read Only” instead of “%*”, and show
“Modified” instead of the “**”. (don't show anything when it's “--”)

• The coding system shown in mode line should be removed. Because, for
vast majority of programers, he rarely deals with different file
coding systems or coding system change, perhaps just few times a year.
It is not something programers encounter on a daily basis. Also, 3
letter-code is cryptic for conveying file coding system, especially
today because there are lots of them. The current coding system should
be shown perhaps in the menu somewhere, and allow users to change thru
menu. For programers who deals with different file systems or coding
systems hourly and need it be displayed on the mode line, perhaps
emacs can introduce a customization feature so that the full coding
system is displayed in modeline.

• The cursor location percentage should by default not shown if emacs
is running in GUI with scroll bar. (this is sometimes shown as “Top”
or “Bot”) GUI scroll bar gives intuitive indication of where cursor is
in relation to the whole buffer, and also gives a indication of the
screen display size in relation to the buffer size, and conveys these
info faster.

• When emacs is running in a terminal, the special indicator “Top” and
“Bot” should be shown as percentage as usual, because for someone
uninitiated, consistent changing of percentage as he moves the cursor
is more intuitive. The code word “Top” and “Bot” could mean many
things to first time users.

• Minor mode should not be displayed in mode line. It's confusing. For
one reason, it by default selectively display only some of the minor
modes currently on, and the selective process is not something people
who intuitively understands. For the other reason, Emacs's technical
concept of Minor mode is somewhat confusing. Most minor modes in
practice are Preferences settings (Mac-speak) or Options (Windows-
speak and Linux Desktops) from user point of view.

• Line number mode should be on by default. So that, the line number
shows in the mode line. How to show line number is a frequently asked
question.

• Clicking on the file name should not switch buffer. It could do
contextual menu listing user buffers instead. (user buffer here are
those not starting with “*”)

• Clicking on the major mode name should pop up a contextual menu to
let user switch to major modes that are familiar to majority of
average programers. (e.g. C, C++, java, perl, php, bash, javascript,
html/xml, python, text, LaTeX, elisp.) The menu can have a “More...”
submenu to show all other available major modes.

Summary

I think the mode line should be like this:

‹buffer name› ‹major mode name› ‹line num› ‹status›-------------------

where the status is Modified or Read Only.

Here's a example of such actual display:

elisp_basics.html    html-mode    L19    Modified-------------------

Also, when editing as root, it'd be nice to indicate it in mode line.
Possibly making the mode line's background red, or add a word “(root)”
on the right. Some indication of being root is a frequently requested
feature.

If running in a GUI, clicking on the buffer name should show menu list
of user buffers, those not starting with a “*”.

Clicking on the major mode name should show a menu of commonly used
major modes, allowing user a easy way to switch. (currently, emacs has
no intuitive way for user to switch a mode or know what modes are
available. This is also a FAQ item.)

Clicking on linePos/charPos show a menu that allow user to turn on/off
line number mode or char number mode.

Clicking on the Read Only or “Modified”, should show a menu allowing
user to toggle Read Only.

Clicking the rest of the mode line displaying “--------”, can show all
the useful info about the current buffer. For example: modified/read
status, mode settings, minor modes, encoding used. This can be done as
a new split window much like describe-function would. In the result
pane, it can show status of other buffer local vars that are related
to text editing (such as case sensitive search, how lines are wrapped,
length for truncation, margin ... ). With links or active text that
lets user toggle or set new vals easily (similar to the UI of the
customize function).

All these clicking should be Right Click, which is more standard
behavior of clicking on things for contextual menu. (e.g. in Windows,
Mac, Linux, system wide, and in Firefox and other browsers.)

• The term “mode line” could be changed to “status bar” in the
manuals. “Status bar” is more understandable to modern users.

  Xah
∑ http://xahlee.org/

  parent reply	other threads:[~2008-11-16  1:54 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <mailman.215.1226562978.26697.help-gnu-emacs@gnu.org>
2008-11-14 23:18 ` emacs mode line suggestions Xah
2008-11-15  1:02   ` xahlee
2008-11-15  9:23   ` Eli Zaretskii
     [not found]   ` <mailman.423.1226741023.26697.help-gnu-emacs@gnu.org>
2008-11-16  1:54     ` Xah [this message]
2008-11-16 18:12       ` Ian Eure
2008-11-18  9:39         ` Kevin Rodgers
2008-11-18 23:25           ` Xavier Maillard
2008-11-16 21:40       ` Eli Zaretskii
     [not found]       ` <mailman.518.1226859137.26697.help-gnu-emacs@gnu.org>
2008-11-16 18:20         ` Richard Riley
2008-11-16 23:12           ` Ian Eure
2008-11-17  8:37             ` Paul R
2008-11-17 15:45               ` Drew Adams
     [not found]               ` <mailman.604.1226937124.26697.help-gnu-emacs@gnu.org>
2008-11-17 16:11                 ` Richard Riley
2008-11-17 18:53                   ` Drew Adams
2008-11-17 19:10                     ` Richard Riley
2008-11-17 19:57                       ` Drew Adams
2008-11-17 20:53                       ` Eli Zaretskii
     [not found]                       ` <mailman.621.1226951870.26697.help-gnu-emacs@gnu.org>
2008-11-17 21:42                         ` Richard Riley
2008-11-18  0:55                           ` Drew Adams
     [not found]                           ` <mailman.641.1226969742.26697.help-gnu-emacs@gnu.org>
2008-11-18  1:08                             ` Richard Riley
2008-11-18  2:55                               ` Drew Adams
2008-11-17 23:37               ` Alan Mackenzie
2008-11-18  7:52                 ` Paul R
2008-11-18 13:48                   ` Alan Mackenzie
     [not found]           ` <mailman.543.1226877138.26697.help-gnu-emacs@gnu.org>
2008-11-16 23:35             ` Richard Riley
2008-11-16 22:45         ` Xah
     [not found]       ` <mailman.536.1226871605.26697.help-gnu-emacs@gnu.org>
2008-11-16 23:17         ` Xah
2008-11-17 20:39           ` Eli Zaretskii
2008-11-17 23:46             ` Alan Mackenzie
2008-11-18  0:31               ` Lennart Borgman
2008-11-18  9:32               ` Kevin Rodgers
2008-11-18  9:58                 ` Alan Mackenzie
     [not found]             ` <mailman.633.1226964831.26697.help-gnu-emacs@gnu.org>
2008-11-18  9:46               ` Fabrice Niessen
     [not found]           ` <mailman.623.1226954396.26697.help-gnu-emacs@gnu.org>
2008-11-17 22:09             ` Xah
2008-11-18  2:33               ` B. T. Raven
2008-11-18  3:24                 ` Xah
2008-11-18  4:58                   ` B. T. Raven
2008-11-18  6:54                     ` Richard Riley
2008-11-18  4:11               ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=15962952-6180-41bd-abce-1b919aa55807@v13g2000pro.googlegroups.com \
    --to=xahlee@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).