all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#7710: lisp/emacs-lisp/easymenu.el - Correct easy-menu-define doctring
@ 2010-12-22 16:56 Jari Aalto
  2010-12-23 15:09 ` Stefan Monnier
  0 siblings, 1 reply; 2+ messages in thread
From: Jari Aalto @ 2010-12-22 16:56 UTC (permalink / raw)
  To: 7710

[-- Attachment #1: Type: text/plain, Size: 1194 bytes --]

Package: emacs
Version: 23.2+1-5.1
Severity: normal

doc-view.el uses:

    (easy-menu-define doc-view-menu doc-view-mode-map
      "Menu for Doc View mode."
      '("DocView"
        ["Toggle display"		doc-view-toggle-display]
        ("Continuous"
       ...

The argument ENABLE appears to be optional. The patch adjusts the
docstring. It was generated against:

    0804bcf 2010-12-22  Merge branch 'master' of git://git.sv.gnu.org/emacs

2010-12-22  Jari Aalto  <jari.aalto@cante.net>

        * emacs-lisp/easymenu.el (easy-menu-define): Correct docstring; change
        from [NAME CALLBACK ENABLE] to [NAME CALLBACK [ENABLE]]

-- System Information
Debian Release: squeeze/sid
  APT Prefers testing
  APT policy: (990, testing) (500, unstable) (1, experimental)
Architecture: amd64
Kernel: Linux picasso 2.6.32-5-amd64 #1 SMP Fri Sep 17 21:50:19 UTC 2010 x86_64 GNU/Linux
Locale: LANG=en_DK.UTF-8

-- Versions of packages `emacs depends on'.
Depends:
emacs23         23.2+1-5.1      GNU Emacs is the extensible self-documenting 
emacs23-lucid   23.2+1-5.1      GNU Emacs is the extensible self-documenting 
emacs23-nox     23.2+1-5.1      GNU Emacs is the extensible self-documenting 


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-easy-menu-define-Correct-description-to-NAME-CALLBAC.patch --]
[-- Type: text/x-diff, Size: 1348 bytes --]

From 901e3765fcad591da9a77017b9c8008cfe33ade7 Mon Sep 17 00:00:00 2001
From: Jari Aalto <jari.aalto@cante.net>
Date: Wed, 22 Dec 2010 18:51:17 +0200
Subject: [PATCH] (easy-menu-define): Correct description to [NAME CALLBACK [ENABLE]]
Organization: Private
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: 8bit


Signed-off-by: Jari Aalto <jari.aalto@cante.net>
---
 lisp/emacs-lisp/easymenu.el |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/lisp/emacs-lisp/easymenu.el b/lisp/emacs-lisp/easymenu.el
index 9992861..f8e9c07 100644
--- a/lisp/emacs-lisp/easymenu.el
+++ b/lisp/emacs-lisp/easymenu.el
@@ -71,7 +71,7 @@ whenever this expression's value is non-nil.
 
 The rest of the elements in MENU, are menu items.
 
-A menu item is usually a vector of three elements:  [NAME CALLBACK ENABLE]
+A menu item is usually a vector of three elements:  [NAME CALLBACK [ENABLE]]
 
 NAME is a string--the menu item name.
 
@@ -79,7 +79,8 @@ CALLBACK is a command to run when the item is chosen,
 or a list to evaluate when the item is chosen.
 
 ENABLE is an expression; the item is enabled for selection
-whenever this expression's value is non-nil.
+whenever this expression's value is non-nil. If not defined, the menu item
+is always shown.
 
 Alternatively, a menu item may have the form:
 
-- 
1.7.2.3


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

* bug#7710: lisp/emacs-lisp/easymenu.el - Correct easy-menu-define doctring
  2010-12-22 16:56 bug#7710: lisp/emacs-lisp/easymenu.el - Correct easy-menu-define doctring Jari Aalto
@ 2010-12-23 15:09 ` Stefan Monnier
  0 siblings, 0 replies; 2+ messages in thread
From: Stefan Monnier @ 2010-12-23 15:09 UTC (permalink / raw)
  To: Jari Aalto; +Cc: 7710

close 7710
thanks

> The argument ENABLE appears to be optional.

It's not just that it's optional but that there is an alternative
format, and in that alternative format [NAME CALLBACK] is valid.
The docstring says a bit further down from your change:

   [...]
   Alternatively, a menu item may have the form:
   
      [ NAME CALLBACK [ KEYWORD ARG ] ... ]
   
   Where KEYWORD is one of the symbols defined below.
   [...]
   

-- Stefan





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

end of thread, other threads:[~2010-12-23 15:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-22 16:56 bug#7710: lisp/emacs-lisp/easymenu.el - Correct easy-menu-define doctring Jari Aalto
2010-12-23 15:09 ` Stefan Monnier

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.