all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: Eli Zaretskii <eliz@gnu.org>, Drew Adams <drew.adams@oracle.com>
Cc: 23236@debbugs.gnu.org
Subject: bug#23236: 25.0.90; Document command remapping in Emacs manual, not just Elisp manual
Date: Thu, 7 Apr 2016 08:58:24 -0700 (PDT)	[thread overview]
Message-ID: <f669e7c5-f955-448a-b4ed-4339fa4917c2@default> (raw)
In-Reply-To: <<83h9fdl9m9.fsf@gnu.org>>

> > Search the Emacs manual for "remap".  You will find nothing about
> > command remapping.
> 
> Because it's not a user-level feature.

I disagree.  Why do you say it is not?  Are users not supposed to
remap commands?  If they are, then what could you possibly mean
by saying that doing so is not "user-level"?

Until Emacs provides an easy Customize interface for customizing
key bindings, users will use `define-key' and `global-set-key'
to customize key bindings.  They always have, and they still must.

> > (global-set-key [remap foo] 'bar) is something that _users_ do.
> > Likewise (define-key some-map [remap foo] 'bar).
> 
> It doesn't matter who does it.  What matters is that these are Lisp
> expressions, and those are usually documented in the ELisp manuals.

I have no problem with them being documented in the Elisp manual.
This bug does not request that they be removed from the Elisp manual.

I think they - at least their existence - should also be documented
in the Emacs manual.  It may be enough to point users (from the
Emacs manual) to the Elisp manual.

But certainly users reading the Emacs manual should be able to find
the answers to questions about _how to customize_ key bindings.
And that includes command remapping.

Binding keys is an extremely common end-user task.  (Yes, it is.
It is 100% "user-level", in addition to being something that is
done in non-user files.)

Not pointing end users, in the Emacs manual, to the information
about _how they do this_ is a cop-out, I think.  They will find
that pointer only by googling etc.  The Emacs manual should be
their friend in this regard, by pointing them to the info they
need to get the job done, whether or not the details of that
info might be in the Elisp manual.

If users need to use Lisp to customize key bindings, then so be
it.  And if they therefore need to read some of the Elisp manual,
to learn how to do that, so be it.

But the _fact_ that they _can_ do it, and the _fact_ that info
about _how_ to do it is in the Elisp manual, should be in the
Emacs manual.  At a minimum.

* You can bind keys to commands of your choosing.
  See (elisp) XXXX.

* You can remap a command A to another command B's key bindings,
  so that using any of those keys invokes command A instead of
  command B.  See (elisp) YYYY.

> global-set-key is only documented in the user manual as a command, not
> as a function.  We only show a few examples of using it as a function.
> 
> > This is not something that is only for Elisp code.
> 
> I think it is.

It is not something that is only for Lisp libraries.  Is that
clearer for you?  It is something that is in thousands of end-user
init files, including users who otherwise know little or nothing
about Lisp.

If you really think that using `define-key' and `global-set-key'
in an end-user init file is inappropriate then please provide a
Customize replacement for `define-key' and `global-set-key'
immediately, and then update the Emacs manual to tell users how
to customize key bindings using Customize.

Until then, users have only `define-key' and `global-set-key' for
key customization.  The Emacs manual should help them in this
regard.  It should not be silent on command remapping.





       reply	other threads:[~2016-04-07 15:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <<24ddcbf0-337e-401f-a539-4d957030236b@default>
     [not found] ` <<83h9fdl9m9.fsf@gnu.org>
2016-04-07 15:58   ` Drew Adams [this message]
2016-04-07 16:49     ` bug#23236: 25.0.90; Document command remapping in Emacs manual, not just Elisp manual Eli Zaretskii
2016-04-07 15:04 Drew Adams
2016-04-07 15:30 ` Eli Zaretskii
2016-04-30 23:10   ` Lars Ingebrigtsen

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

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

  git send-email \
    --in-reply-to=f669e7c5-f955-448a-b4ed-4339fa4917c2@default \
    --to=drew.adams@oracle.com \
    --cc=23236@debbugs.gnu.org \
    --cc=eliz@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.
Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.