Mercurial > emacs
changeset 5248:27d6275810a7
(Fsubstitute_command_keys): Ignore menu bar bindings.
(Fdocumentation_property): 3 args is maximum.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Thu, 23 Dec 1993 01:56:43 +0000 |
parents | 0cf95629f6c4 |
children | 67767e113d1d |
files | src/doc.c |
diffstat | 1 files changed, 10 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/doc.c Thu Dec 23 01:55:14 1993 +0000 +++ b/src/doc.c Thu Dec 23 01:56:43 1993 +0000 @@ -183,7 +183,7 @@ return doc; } -DEFUN ("documentation-property", Fdocumentation_property, Sdocumentation_property, 2, 2, 0, +DEFUN ("documentation-property", Fdocumentation_property, Sdocumentation_property, 2, 3, 0, "Return the documentation string that is SYMBOL's PROP property.\n\ This is like `get', but it can refer to strings stored in the\n\ `etc/DOC' file; and if the value is a string, it is passed through\n\ @@ -409,6 +409,8 @@ } else if (strp[0] == '\\' && strp[1] == '[') { + Lisp_Object firstkey; + changed = 1; strp += 2; /* skip \[ */ start = strp; @@ -425,6 +427,13 @@ tem = Fintern (make_string (start, length), Qnil); tem = Fwhere_is_internal (tem, keymap, Qnil, Qt, Qnil); + /* Disregard menu bar bindings; it is positively annoying to + mention them when there's no menu bar, and it isn't terribly + useful even when there is a menu bar. */ + firstkey = Faref (tem, make_number (0)); + if (EQ (firstkey, Qmenu_bar)) + tem = Qnil; + if (NILP (tem)) /* but not on any keys */ { new = (unsigned char *) xrealloc (buf, bsize += 4);