unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: Dmitry Gutov <dgutov@yandex.ru>, Juri Linkov <juri@linkov.net>
Cc: pinkanon pinkanon <pinkanon.pinkanon@yandex.ru>, 34939@debbugs.gnu.org
Subject: bug#34939: Some minibuffer behaviour is annoying
Date: Tue, 9 Apr 2019 11:26:31 -0700 (PDT)	[thread overview]
Message-ID: <54041382-cfd6-4842-aea8-741213f917e9@default> (raw)
In-Reply-To: <4eee2f08-5385-c845-07f6-355d242d3ae0@yandex.ru>

> > But you _can_ see it.  Before and after the `message',
> > which disappears as soon as you type your next input
> > char or perform some other action.  Seeing happens
> > in time, over time.
> 
> Yeah, it's annoying and creates a bad image for the
> editor. Just see the original report.

One user does not speak for all Emacs users.

Bad image of the editor is in the eye of the beholder,
and it should not be our primary concern.  Usefulness
for users (including Elisp programmers) should be our
main concern.

Different users make different uses of Emacs.  One
size - even the one size you think is great - does
not fit all.

> >> I'd think that much would be obvious.
> >
> > It's too general and abstract.  Too blanket, too
> > black-&-white.  Too simplistic, dogmatic.
> >
> > Sometimes in a dialog what's _wanted_ is to interrupt.
> > And there are different ways of interrupting, each of
> > which can be useful, helpful.
> 
> If we do get around to having message always delegate to
> minibuffer-message, there will be another function for "interrupting"
> messages. It would require you to do some compatibility shimming in your
> code, though.

I made my points.  I'm not going to argue with you.
As you do, you will just do what you want anyway.

I will say this though.

1. Whatever you do, please do it in Lisp, not C, so
   users can advise, redefine, remove, or improve
   on it according to their needs using Lisp.

2. Please make the behavior controllable by users
   and by code (Lisp).

3. Since 2009 I've used the following simple
   function in my code.  It lets code and users
   control the behavior.

   It is in _addition_ to `minibuffer-message'
   and `message', as another alternative.  IOW,
   sometimes I call `minibuffer-message',
   sometimes`message', and sometimes this function.

   An example of code controlling the behavior is
   binding `icicle-minibuffer-message-ok-p' to nil
   (conditionally) to avoid delays from using
   `minibuffer-message' or to inhibit possible
   message display.

   I have over a hundred calls to this function,
   so you can see that I am sensitive to the need
   to often use `minibuffer-message' when the
   minibuffer is active.  What I disagree with is
   your black-&-white view of things, which leads
   you to want to always impose the single behavior
   of `minibuffer-message'.

(defun icicle-msg-maybe-in-minibuffer (format-string &rest args)
  "Display FORMAT-STRING as a message.
If called with the minibuffer inactive, use `message'.
Otherwise:
 If `icicle-minibuffer-message-ok-p', then use `minibuffer-message'.
 Else do nothing (no message display)."
  (if (active-minibuffer-window)
      (when icicle-minibuffer-message-ok-p
        (save-selected-window
          (select-window (minibuffer-window))
          (minibuffer-message
            (apply #'format (concat "  [" format-string "]")
                            args))))
    (apply #'message format-string args)))





  reply	other threads:[~2019-04-09 18:26 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-21 19:13 bug#34939: Some minibuffer behaviour is annoying pinkanon pinkanon
2019-03-22 16:57 ` Dmitry Gutov
2019-03-23  2:32   ` Richard Stallman
2019-03-23  9:46     ` Dmitry Gutov
2019-03-23  9:50       ` Eli Zaretskii
2019-03-23 11:24         ` Dmitry Gutov
2019-03-23 12:18           ` pinkanon pinkanon
     [not found]       ` <<83o961q5rr.fsf@gnu.org>
2019-03-23 15:51         ` Drew Adams
2019-03-31 19:50           ` Juri Linkov
2019-03-31 19:49 ` Juri Linkov
2019-03-31 20:29   ` Juri Linkov
2019-04-01 13:08     ` Dmitry Gutov
2019-04-01 20:31       ` Juri Linkov
2019-04-01 21:53         ` Dmitry Gutov
2019-04-03 20:50           ` Juri Linkov
2019-05-19 20:16       ` Juri Linkov
2019-04-01 10:10   ` pinkanon pinkanon
2019-04-01 20:25     ` Juri Linkov
2019-04-02 18:25       ` pinkanon pinkanon
2019-04-01 13:03   ` Dmitry Gutov
2019-04-01 20:29     ` Juri Linkov
2019-04-07 20:43       ` Juri Linkov
2019-04-07 23:09         ` Dmitry Gutov
2019-04-08 19:47           ` Juri Linkov
2019-04-08 22:00             ` Drew Adams
2019-04-08 23:06               ` Dmitry Gutov
2019-04-08 23:32                 ` Drew Adams
2019-04-08 23:37                   ` Dmitry Gutov
2019-04-08 23:59                     ` Drew Adams
2019-04-09  0:11                       ` Dmitry Gutov
2019-04-09 18:26                         ` Drew Adams [this message]
2019-05-24 22:49   ` Dmitry Gutov
2019-05-27 20:15     ` Juri Linkov
2019-05-27 20:58       ` Dmitry Gutov
2019-05-29 21:53         ` Juri Linkov
2019-05-29 22:26           ` Drew Adams
2019-05-30 19:50             ` Juri Linkov
2019-05-30 21:00               ` Drew Adams
2019-05-30 21:35                 ` Juri Linkov
2019-06-03 20:27           ` Juri Linkov
2019-06-04 15:15             ` Dmitry Gutov

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=54041382-cfd6-4842-aea8-741213f917e9@default \
    --to=drew.adams@oracle.com \
    --cc=34939@debbugs.gnu.org \
    --cc=dgutov@yandex.ru \
    --cc=juri@linkov.net \
    --cc=pinkanon.pinkanon@yandex.ru \
    /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.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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).