unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#6670: 23.1; faulty example in Lisp Reference Manual, 22.17.4 Menu Example
@ 2010-07-19 18:21 Robbie Morrison
  2010-07-20 22:23 ` Glenn Morris
  0 siblings, 1 reply; 3+ messages in thread
From: Robbie Morrison @ 2010-07-19 18:21 UTC (permalink / raw)
  To: 6670


In section 22.17.4 of the Lisp Reference Manual, I believe that:

     (define-key menu-bar-edit-menu [replace]
       (list 'menu-item "Replace" menu-bar-replace-menu))

should read:

     (define-key global-map [replace]
       (list 'menu-item "Replace" menu-bar-replace-menu))

The explanatory paragraph which follows needs checking too.

I tested both options and only my modification worked as expected.
The original example ran without issue, but failed to produce an entry
in the menu-bar.

my appreciation to all the Emacs maintainers
Robbie
---
Robbie Morrison
PhD student -- policy-oriented energy system simulation
Technical University of Berlin (TU-Berlin), Germany
University email (redirected) : morrison@iet.tu-berlin.de
Webmail (preferred)           : robbie@actrix.co.nz
[from Webmail client]

In GNU Emacs 23.1.1 (x86_64-pc-linux-gnu, GTK+ Version 2.20.0)
 of 2010-03-29 on yellow, modified by Debian
Windowing system distributor `The X.Org Foundation', version 11.0.10706000
configured using `configure  '--build=x86_64-linux-gnu'
'--host=x86_64-linux-gnu' '--prefix=/usr' '--sharedstatedir=/var/lib'
'--libexecdir=/usr/lib' '--localstatedir=/var/lib'
'--infodir=/usr/share/info' '--mandir=/usr/share/man' '--with-pop=yes'
'--enable-locallisppath=/etc/emacs23:/etc/emacs:/usr/local/share/emacs/23.1/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/23.1/site-lisp:/usr/share/emacs/site-lisp:/usr/share/emacs/23.1/leim'
'--with-x=yes' '--with-x-toolkit=gtk' '--with-toolkit-scroll-bars'
'build_alias=x86_64-linux-gnu' 'host_alias=x86_64-linux-gnu'
'CFLAGS=-DDEBIAN -g -O2' 'LDFLAGS=-g' 'CPPFLAGS=''







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

* bug#6670: 23.1; faulty example in Lisp Reference Manual, 22.17.4 Menu Example
  2010-07-19 18:21 bug#6670: 23.1; faulty example in Lisp Reference Manual, 22.17.4 Menu Example Robbie Morrison
@ 2010-07-20 22:23 ` Glenn Morris
       [not found]   ` <124ed7d5446b49e959e9b07dcf67270f.squirrel@my.actrix.co.nz>
  0 siblings, 1 reply; 3+ messages in thread
From: Glenn Morris @ 2010-07-20 22:23 UTC (permalink / raw)
  To: Robbie Morrison; +Cc: 6670

"Robbie Morrison" wrote:

> In section 22.17.4 of the Lisp Reference Manual, I believe that:
>
>      (define-key menu-bar-edit-menu [replace]
>        (list 'menu-item "Replace" menu-bar-replace-menu))
>
> should read:
>
>      (define-key global-map [replace]
>        (list 'menu-item "Replace" menu-bar-replace-menu))
>
> The explanatory paragraph which follows needs checking too.

Thanks for the report, but the original text seems fine to me.
As it explains at the start of the section:

"It is the definition of the `Replace' submenu in the `Edit' menu in
the menu bar[...]"

The difference between the two forms is that yours is intended to put
the Replace menu at the top-level, as opposed to inside the Edit menu.
I don't see that your form works though. Surely it should be:

      (define-key global-map [menu-bar replace]
        (list 'menu-item "Replace" menu-bar-replace-menu))





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

* bug#6670: 23.1; faulty example in Lisp Reference Manual, 22.17.4 Menu Example
       [not found]   ` <124ed7d5446b49e959e9b07dcf67270f.squirrel@my.actrix.co.nz>
@ 2010-08-09 22:46     ` Glenn Morris
  0 siblings, 0 replies; 3+ messages in thread
From: Glenn Morris @ 2010-08-09 22:46 UTC (permalink / raw)
  To: 6670-done


[replying to off-list message]

Robbie Morrison wrote (on Tue, 27 Jul 2010 at 23:49 +1200):

> Many thanks for your explanation.  You are completely
> correct.  This bug should be marked as resolved.





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

end of thread, other threads:[~2010-08-09 22:46 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-19 18:21 bug#6670: 23.1; faulty example in Lisp Reference Manual, 22.17.4 Menu Example Robbie Morrison
2010-07-20 22:23 ` Glenn Morris
     [not found]   ` <124ed7d5446b49e959e9b07dcf67270f.squirrel@my.actrix.co.nz>
2010-08-09 22:46     ` Glenn Morris

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