From: Juanma Barranquero Date: Thu, 29 Sep 2011 00:12:44 +0000 (+0200) Subject: lisp/descr-text.el (describe-char-categories): Accept multiline descriptions. X-Git-Tag: emacs-pretest-24.0.91~252 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=df9a7357d2494add9ea23ccd63780beefbc2edd2;p=emacs.git lisp/descr-text.el (describe-char-categories): Accept multiline descriptions. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 0927ff478c2..a5ca53e9f4a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-09-29 Juanma Barranquero + + * descr-text.el (describe-char-categories): Accept category + descriptions more than one line long. + 2011-09-28 Stefan Monnier * simple.el (delete-trailing-whitespace): Fix last change. diff --git a/lisp/descr-text.el b/lisp/descr-text.el index fca06adb2a9..7d267cec480 100644 --- a/lisp/descr-text.el +++ b/lisp/descr-text.el @@ -366,9 +366,10 @@ This function is semi-obsolete. Use `get-char-code-property'." (list (mapconcat (lambda (x) (let* ((c (category-docstring x)) - (doc (if (string-match "\\`\\(.*?\\)\n\\(.*\\)\\'" c) + (doc (if (string-match "\\`\\(.*?\\)\n" c) (propertize (match-string 1 c) - 'help-echo (match-string 2 c)) + 'help-echo + (substring c (1+ (match-end 1)))) c))) (format "%c:%s" x doc))) mnemonics ", ")))))