unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors
@ 2017-06-25 20:33 Drew Adams
  2019-07-21 15:33 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 8+ messages in thread
From: Drew Adams @ 2017-06-25 20:33 UTC (permalink / raw)
  To: 27490

Nothing is said about `function-key-map' and its inheritance relations,
beyond the fact that local such maps inherit from `f-k-m', and that
`f-k-m' "should not be used directly" (no reason given).

Please consider explaining `function-key-map'.

In http://lists.gnu.org/archive/html/emacs-devel/2017-06/msg00595.html,
for example, Stefan counsels to "just use function-key-map to translate
[touch-event] to []".  It's not clear how a reader of the manual would
come to such an understanding.

In GNU Emacs 24.5.1 (i686-pc-mingw32)
 of 2015-04-11 on LEG570
Windowing system distributor `Microsoft Corp.', version 6.1.7601
Configured using:
 `configure --prefix=/c/usr --host=i686-pc-mingw32'





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors
  2017-06-25 20:33 bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors Drew Adams
@ 2019-07-21 15:33 ` Lars Ingebrigtsen
  2019-07-21 16:39   ` Eli Zaretskii
  0 siblings, 1 reply; 8+ messages in thread
From: Lars Ingebrigtsen @ 2019-07-21 15:33 UTC (permalink / raw)
  To: Drew Adams; +Cc: 27490

Drew Adams <drew.adams@oracle.com> writes:

> Nothing is said about `function-key-map' and its inheritance relations,
> beyond the fact that local such maps inherit from `f-k-m', and that
> `f-k-m' "should not be used directly" (no reason given).
>
> Please consider explaining `function-key-map'.

This text:

------

@code{local-function-key-map} inherits from @code{function-key-map},
but the latter should not be used directly.

------

was added by this commit:

------

commit 6b9e769476955b928b0248fef5aaa0e40754e257
Author: Eli Zaretskii <eliz@gnu.org>
Date:   Sat Jan 17 19:14:52 2009 +0000

    (Translation Keymaps): Rename function-key-map to local-function-key-map.

------


So I'm assuming that there was a plan to phase out using
function-key-map or something?  Perhaps Eli can clarify.

But there's a bunch of examples in the manual that does use the map, so
either these should be adjusted, or the documentation clarified:

------

The only way to affect the behavior of keys within Emacs is through
@code{xmodmap} (outside Emacs) or @code{define-key} (inside Emacs).  The
@code{define-key} command should be used in conjunction with the
@code{function-key-map} map.  For instance,

@lisp
(define-key function-key-map [M-@key{TAB}] [?\M-\t])
@end lisp

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors
  2019-07-21 15:33 ` Lars Ingebrigtsen
@ 2019-07-21 16:39   ` Eli Zaretskii
  2019-07-21 17:31     ` Lars Ingebrigtsen
  0 siblings, 1 reply; 8+ messages in thread
From: Eli Zaretskii @ 2019-07-21 16:39 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 27490

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Date: Sun, 21 Jul 2019 17:33:45 +0200
> Cc: 27490@debbugs.gnu.org
> 
> This text:
> 
> ------
> 
> @code{local-function-key-map} inherits from @code{function-key-map},
> but the latter should not be used directly.
> 
> ------
> 
> was added by this commit:
> 
> ------
> 
> commit 6b9e769476955b928b0248fef5aaa0e40754e257
> Author: Eli Zaretskii <eliz@gnu.org>
> Date:   Sat Jan 17 19:14:52 2009 +0000
> 
>     (Translation Keymaps): Rename function-key-map to local-function-key-map.
> 
> ------
> 
> 
> So I'm assuming that there was a plan to phase out using
> function-key-map or something?  Perhaps Eli can clarify.

I don't remember any details, and I found no discussions of this
around that date.  However, you will find a bunch of commits around
that one which all renamed function-key-map to
local-function-key-map.  So yes, it appears like we wanted people to
use the latter.

> But there's a bunch of examples in the manual that does use the map, so
> either these should be adjusted, or the documentation clarified:

I think the examples which use function-key-map should be modified,
yes.

> The only way to affect the behavior of keys within Emacs is through
> @code{xmodmap} (outside Emacs) or @code{define-key} (inside Emacs).  The
> @code{define-key} command should be used in conjunction with the
> @code{function-key-map} map.  For instance,
> 
> @lisp
> (define-key function-key-map [M-@key{TAB}] [?\M-\t])
> @end lisp

Where did you find this?  I must be blind, because I don't see this
passage in the manual.





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors
  2019-07-21 16:39   ` Eli Zaretskii
@ 2019-07-21 17:31     ` Lars Ingebrigtsen
  2019-07-21 17:54       ` Eli Zaretskii
  0 siblings, 1 reply; 8+ messages in thread
From: Lars Ingebrigtsen @ 2019-07-21 17:31 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 27490

Eli Zaretskii <eliz@gnu.org> writes:

>> The only way to affect the behavior of keys within Emacs is through
>> @code{xmodmap} (outside Emacs) or @code{define-key} (inside Emacs).  The
>> @code{define-key} command should be used in conjunction with the
>> @code{function-key-map} map.  For instance,
>> 
>> @lisp
>> (define-key function-key-map [M-@key{TAB}] [?\M-\t])
>> @end lisp
>
> Where did you find this?  I must be blind, because I don't see this
> passage in the manual.

It's in the "X key translations for Emacs" node in misc/efaq.texi, which
I guess isn't part of the manual.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors
  2019-07-21 17:31     ` Lars Ingebrigtsen
@ 2019-07-21 17:54       ` Eli Zaretskii
  2019-07-21 18:16         ` Lars Ingebrigtsen
  0 siblings, 1 reply; 8+ messages in thread
From: Eli Zaretskii @ 2019-07-21 17:54 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 27490

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: drew.adams@oracle.com,  27490@debbugs.gnu.org
> Date: Sun, 21 Jul 2019 19:31:45 +0200
> 
> >> The only way to affect the behavior of keys within Emacs is through
> >> @code{xmodmap} (outside Emacs) or @code{define-key} (inside Emacs).  The
> >> @code{define-key} command should be used in conjunction with the
> >> @code{function-key-map} map.  For instance,
> >> 
> >> @lisp
> >> (define-key function-key-map [M-@key{TAB}] [?\M-\t])
> >> @end lisp
> >
> > Where did you find this?  I must be blind, because I don't see this
> > passage in the manual.
> 
> It's in the "X key translations for Emacs" node in misc/efaq.texi, which
> I guess isn't part of the manual.

Ah, okay.  Yes, that part of the FAQ is obsolete and should be fixed.





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors
  2019-07-21 17:54       ` Eli Zaretskii
@ 2019-07-21 18:16         ` Lars Ingebrigtsen
  2019-07-23 14:58           ` Eli Zaretskii
  0 siblings, 1 reply; 8+ messages in thread
From: Lars Ingebrigtsen @ 2019-07-21 18:16 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 27490

Eli Zaretskii <eliz@gnu.org> writes:

>> It's in the "X key translations for Emacs" node in misc/efaq.texi, which
>> I guess isn't part of the manual.
>
> Ah, okay.  Yes, that part of the FAQ is obsolete and should be fixed.

Would `local-function-key-map' be the right things to replace it with in
these examples?  (There's one in the viper manual, too.)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors
  2019-07-21 18:16         ` Lars Ingebrigtsen
@ 2019-07-23 14:58           ` Eli Zaretskii
  2019-07-23 17:16             ` Lars Ingebrigtsen
  0 siblings, 1 reply; 8+ messages in thread
From: Eli Zaretskii @ 2019-07-23 14:58 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: 27490

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: drew.adams@oracle.com,  27490@debbugs.gnu.org
> Date: Sun, 21 Jul 2019 20:16:31 +0200
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> >> It's in the "X key translations for Emacs" node in misc/efaq.texi, which
> >> I guess isn't part of the manual.
> >
> > Ah, okay.  Yes, that part of the FAQ is obsolete and should be fixed.
> 
> Would `local-function-key-map' be the right things to replace it with in
> these examples?  (There's one in the viper manual, too.)

Yes, I think so.





^ permalink raw reply	[flat|nested] 8+ messages in thread

* bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors
  2019-07-23 14:58           ` Eli Zaretskii
@ 2019-07-23 17:16             ` Lars Ingebrigtsen
  0 siblings, 0 replies; 8+ messages in thread
From: Lars Ingebrigtsen @ 2019-07-23 17:16 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 27490

Eli Zaretskii <eliz@gnu.org> writes:

>> Would `local-function-key-map' be the right things to replace it with in
>> these examples?  (There's one in the viper manual, too.)
>
> Yes, I think so.

OK; I've now adjusted these instances (and two in the Emacs user manual,
too).

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2019-07-23 17:16 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-25 20:33 bug#27490: 24.5; Elisp manual explanation of `function-key-map' and its inheritors Drew Adams
2019-07-21 15:33 ` Lars Ingebrigtsen
2019-07-21 16:39   ` Eli Zaretskii
2019-07-21 17:31     ` Lars Ingebrigtsen
2019-07-21 17:54       ` Eli Zaretskii
2019-07-21 18:16         ` Lars Ingebrigtsen
2019-07-23 14:58           ` Eli Zaretskii
2019-07-23 17:16             ` Lars Ingebrigtsen

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