From 0507406b6ca75c4366dd16855123e8fc9b012c6b Mon Sep 17 00:00:00 2001 From: Nicolas Richard Date: Fri, 25 Apr 2014 14:01:18 -0400 Subject: [PATCH 01/19] * lisp/battery.el (battery-update): Handle the case where battery status is "N/A". Fixes: debbugs:17319 --- lisp/ChangeLog | 9 +++++++-- lisp/battery.el | 17 ++++++++--------- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 60543c67f8c..9943884c372 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,7 +1,12 @@ +2014-04-25 Nicolas Richard + + * battery.el (battery-update): Handle the case where battery + status is "N/A" (bug#17319). + 2014-04-24 Eli Zaretskii - * tooltip.el (tooltip-show-help-non-mode, tooltip-show-help): Use - equal-including-properties to compare help-echo strings. (Bug#17331) + * tooltip.el (tooltip-show-help-non-mode, tooltip-show-help): + Use equal-including-properties to compare help-echo strings (bug#17331). 2014-04-24 Leo Liu diff --git a/lisp/battery.el b/lisp/battery.el index 1eef80ab339..b49363489a8 100644 --- a/lisp/battery.el +++ b/lisp/battery.el @@ -201,19 +201,18 @@ seconds." (defun battery-update () "Update battery status information in the mode line." - (let ((data (and battery-status-function (funcall battery-status-function)))) + (let* ((data (and battery-status-function (funcall battery-status-function))) + (percentage (car (read-from-string (cdr (assq ?p data)))))) (setq battery-mode-line-string (propertize (if (and battery-mode-line-format - (<= (car (read-from-string (cdr (assq ?p data)))) - battery-mode-line-limit)) - (battery-format - battery-mode-line-format - data) + (numberp percentage) + (<= percentage battery-mode-line-limit)) + (battery-format battery-mode-line-format data) "") 'face - (and (<= (car (read-from-string (cdr (assq ?p data)))) - battery-load-critical) - 'error) + (and (numberp percentage) + (<= percentage battery-load-critical) + 'error) 'help-echo "Battery status information"))) (force-mode-line-update)) From 7ece6d40142cad22fe342ae522e24c9b8b5e75a3 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Apr 2014 10:06:33 +0300 Subject: [PATCH 02/19] Fix bug #17334 with overrunning string bounds when PATH is broken. nt/cmdproxy.c (make_absolute): Don't copy more characters from PATH than a single directory name can hold. --- nt/ChangeLog | 5 +++++ nt/cmdproxy.c | 8 ++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/nt/ChangeLog b/nt/ChangeLog index 97d42701c3c..299879ccba8 100644 --- a/nt/ChangeLog +++ b/nt/ChangeLog @@ -1,3 +1,8 @@ +2014-04-26 Eli Zaretskii + + * cmdproxy.c (make_absolute): Don't copy more characters from PATH + than a single directory name can hold. (Bug#17334) + 2014-04-21 Eli Zaretskii * inc/ms-w32.h (lseek): Define only if not already a macro. diff --git a/nt/cmdproxy.c b/nt/cmdproxy.c index f3433f63684..e48ca63a257 100644 --- a/nt/cmdproxy.c +++ b/nt/cmdproxy.c @@ -292,11 +292,15 @@ make_absolute (const char *prog) while (*path) { + size_t len; + /* Get next directory from path. */ p = path; while (*p && *p != ';') p++; - strncpy (dir, path, p - path); - dir[p - path] = '\0'; + /* A broken PATH could have too long directory names in it. */ + len = min (p - path, sizeof (dir) - 1); + strncpy (dir, path, len); + dir[len] = '\0'; /* Search the directory for the program. */ if (search_dir (dir, prog, MAX_PATH, absname) > 0) From 5d46972532b89f90bfde68953cc95889851ee005 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Apr 2014 10:46:18 +0300 Subject: [PATCH 03/19] Fix bug #17308 with inaccurate description of mail signature handling. doc/emacs/sending.texi (Mail Signature): Document signature variables used by Message mode. --- doc/emacs/ChangeLog | 5 +++++ doc/emacs/sending.texi | 28 +++++++++++++++++----------- 2 files changed, 22 insertions(+), 11 deletions(-) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index 12037aae275..1e002127be6 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -1,3 +1,8 @@ +2014-04-26 Eli Zaretskii + + * sending.texi (Mail Signature): Document signature variables used + by Message mode. (Bug#17308) + 2014-04-21 Eli Zaretskii * buffers.texi (Uniquify): Clarify the default uniquification. diff --git a/doc/emacs/sending.texi b/doc/emacs/sending.texi index 95f3c6b661b..02b38cc6748 100644 --- a/doc/emacs/sending.texi +++ b/doc/emacs/sending.texi @@ -592,31 +592,37 @@ are inserted. @section Mail Signature @cindex mail signature -@vindex mail-signature-file -@vindex mail-signature +@vindex message-signature-file +@vindex message-signature You can add a standard piece of text---your @dfn{mail signature}---to the end of every message. This signature may contain information such as your telephone number or your physical location. -The variable @code{mail-signature} determines how Emacs handles the +The variable @code{message-signature} determines how Emacs handles the mail signature. - The default value of @code{mail-signature} is @code{t}; this means -to look for your mail signature in the file @file{~/.signature}. If -this file exists, its contents are automatically inserted into the end -of the mail buffer. You can change the signature file via the -variable @code{mail-signature-file}. + The default value of @code{message-signature} is @code{t}; this +means to look for your mail signature in the file @file{~/.signature}. +If this file exists, its contents are automatically inserted into the +end of the mail buffer. You can change the signature file via the +variable @code{message-signature-file}. - If you change @code{mail-signature} to a string, that specifies the -text of the signature directly. + If you change @code{message-signature} to a string, that specifies +the text of the signature directly. @kindex C-c C-w @r{(Message mode)} @findex message-insert-signature - If you change @code{mail-signature} to @code{nil}, Emacs will not + If you change @code{message-signature} to @code{nil}, Emacs will not insert your mail signature automatically. You can insert your mail signature by typing @kbd{C-c C-w} (@code{message-insert-signature}) in the mail buffer. Emacs will look for your signature in the signature file. +@vindex mail-signature-file +@vindex mail-signature + If you use Mail mode rather than Message mode for composing your +mail, the corresponding variables that determine how your signature is +sent are @code{mail-signature} and @code{mail-signature-file} instead. + By convention, a mail signature should be marked by a line whose contents are @samp{-- }. If your signature lacks this prefix, it is added for you. The remainder of your signature should be no more than From 8e554df009bc64b4e5e75028f36c397ba78596b4 Mon Sep 17 00:00:00 2001 From: Juri Linkov Date: Sun, 27 Apr 2014 11:22:11 +0300 Subject: [PATCH 04/19] * lisp/desktop.el (desktop-value-to-string): Let-bind `print-length' and `print-level' to nil. Fixes: debbugs:17351 --- lisp/ChangeLog | 5 +++++ lisp/desktop.el | 7 ++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9943884c372..94a80120ed8 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2014-04-27 Juri Linkov + + * desktop.el (desktop-value-to-string): Let-bind `print-length' + and `print-level' to nil. (Bug#17351) + 2014-04-25 Nicolas Richard * battery.el (battery-update): Handle the case where battery diff --git a/lisp/desktop.el b/lisp/desktop.el index 5e43c03ade7..ded73c065f0 100644 --- a/lisp/desktop.el +++ b/lisp/desktop.el @@ -844,12 +844,13 @@ QUOTE may be `may' (value may be quoted), "Convert VALUE to a string that when read evaluates to the same value. Not all types of values are supported." (let* ((print-escape-newlines t) + (print-length nil) + (print-level nil) (float-output-format nil) (quote.sexp (desktop--v2s value)) (quote (car quote.sexp)) - (txt - (let ((print-quoted t)) - (prin1-to-string (cdr quote.sexp))))) + (print-quoted t) + (txt (prin1-to-string (cdr quote.sexp)))) (if (eq quote 'must) (concat "'" txt) txt))) From 4f5fa75591973935b59beb0b66ffbfcbc9ee63cc Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 28 Apr 2014 11:04:49 -0400 Subject: [PATCH 05/19] * lisp/textmodes/rst.el (electric-pair-pairs): Declare. (rst-mode): Set it. Fixes: debbugs:17131 --- doc/lispref/ChangeLog | 5 +++++ lisp/ChangeLog | 5 +++++ lisp/textmodes/rst.el | 7 +++++-- 3 files changed, 15 insertions(+), 2 deletions(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index c2907cccf6e..f538b960b50 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -10,6 +10,11 @@ * internals.texi (Building Emacs): Improve indexing. +2014-04-15 Stefan Monnier + + * display.texi (Overlay Properties): Reword the doc of `priority'. + (Finding Overlays): Document new arg of `overlays-at'. + 2014-04-05 Glenn Morris * os.texi (Recording Input): Dribble files may contain passwords. diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 94a80120ed8..e27d7b1c6a0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2014-04-28 Stefan Monnier + + * textmodes/rst.el (electric-pair-pairs): Declare. + (rst-mode): Set it (bug#17131). + 2014-04-27 Juri Linkov * desktop.el (desktop-value-to-string): Let-bind `print-length' diff --git a/lisp/textmodes/rst.el b/lisp/textmodes/rst.el index d4a3438ce97..b05a5e5a7e3 100644 --- a/lisp/textmodes/rst.el +++ b/lisp/textmodes/rst.el @@ -784,11 +784,9 @@ This inherits from Text mode.") (modify-syntax-entry ?\u2019 "." st) (modify-syntax-entry ?\u201c "." st) (modify-syntax-entry ?\u201d "." st) - st) "Syntax table used while in `rst-mode'.") - (defcustom rst-mode-hook nil "Hook run when `rst-mode' is turned on. The hook for `text-mode' is run before this one." @@ -799,6 +797,8 @@ The hook for `text-mode' is run before this one." ;; Pull in variable definitions silencing byte-compiler. (require 'newcomment) +(defvar electric-pair-pairs) + ;; Use rst-mode for *.rst and *.rest files. Many ReStructured-Text files ;; use *.txt, but this is too generic to be set as a default. ;;;###autoload (add-to-list 'auto-mode-alist (purecopy '("\\.re?st\\'" . rst-mode))) @@ -860,6 +860,9 @@ highlighting. (set (make-local-variable 'uncomment-region-function) 'rst-uncomment-region) + (set (make-local-variable 'electric-pair-pairs) + '((?\" . ?\") (?\* . ?\*) (?\` . ?\`))) + ;; Imenu and which function. ;; FIXME: Check documentation of `which-function' for alternative ways to ;; determine the current function name. From bc6953b32f993be10ff3429af5bacb7e18b08ae7 Mon Sep 17 00:00:00 2001 From: Matthias Dahl Date: Mon, 28 Apr 2014 22:14:17 +0300 Subject: [PATCH 06/19] Fix bug 16694 with applying X resources to faces too early. lisp/faces.el (face-spec-recalc): Apply X resources only after the defface spec has been applied. Thus, X resources are no longer overriden by the defface spec which also fixes issues on win32 where the toolbar coloring was wrong because it is set through X resources and was (wrongfully) overriden. --- lisp/ChangeLog | 8 ++++++++ lisp/faces.el | 18 ++++++++++++------ 2 files changed, 20 insertions(+), 6 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e27d7b1c6a0..26516fd2cd3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2014-04-27 Matthias Dahl + + * faces.el (face-spec-recalc): Apply X resources only after the + the defface spec has been applied. Thus, X resources are no longer + overriden by the defface spec which also fixes issues on win32 where + the toolbar coloring was wrong because it is set through X resources + and was (wrongfully) overriden. (Bug#16694) + 2014-04-28 Stefan Monnier * textmodes/rst.el (electric-pair-pairs): Declare. diff --git a/lisp/faces.el b/lisp/faces.el index 88b87486f7c..df31e0dfbd8 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -1641,18 +1641,22 @@ function for its other effects." (defun face-spec-recalc (face frame) "Reset the face attributes of FACE on FRAME according to its specs. -After the reset, the specs are applied from the following sources in this order: - X resources (if applicable) +The following sources are applied in this order: + + face reset to default values if it's the default face, otherwise set + to unspecifed (through `face-spec-reset-face`) | (theme and user customization) - or, if nonexistent or does not match the current frame, + or: if none of the above exist, do not match the current frame or + did inherit from the defface spec instead of overwriting it + entirely, the following is applied instead: (defface default spec) + (X resources (if applicable)) | defface override spec" (while (get face 'face-alias) (setq face (get face 'face-alias))) (face-spec-reset-face face frame) - (make-face-x-resource-internal face frame) ;; If FACE is customized or themed, set the custom spec from ;; `theme-face' records. (let ((theme-faces (get face 'theme-face)) @@ -1666,10 +1670,12 @@ After the reset, the specs are applied from the following sources in this order: (setq theme-face-applied t)))) ;; If there was a spec applicable to FRAME, that overrides the ;; defface spec entirely (rather than inheriting from it). If - ;; there was no spec applicable to FRAME, apply the defface spec. + ;; there was no spec applicable to FRAME, apply the defface spec + ;; as well as any applicable X resources. (unless theme-face-applied (setq spec (face-spec-choose (face-default-spec face) frame)) - (face-spec-set-2 face frame spec)) + (face-spec-set-2 face frame spec) + (make-face-x-resource-internal face frame)) (setq spec (face-spec-choose (get face 'face-override-spec) frame)) (face-spec-set-2 face frame spec))) From 2cfb51ef2a727a9479bb2af2f2d8773f86bae133 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Mon, 28 Apr 2014 22:15:58 +0300 Subject: [PATCH 07/19] Fix a typo in ChangeLog entry of last commit. --- lisp/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 26516fd2cd3..bb23d634ac1 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,7 +1,7 @@ 2014-04-27 Matthias Dahl * faces.el (face-spec-recalc): Apply X resources only after the - the defface spec has been applied. Thus, X resources are no longer + defface spec has been applied. Thus, X resources are no longer overriden by the defface spec which also fixes issues on win32 where the toolbar coloring was wrong because it is set through X resources and was (wrongfully) overriden. (Bug#16694) From 2785da249bd881dae503507d22e3ce6f158e519a Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Tue, 29 Apr 2014 00:14:27 -0400 Subject: [PATCH 08/19] * doc/lispref/processes.texi (Filter Functions, Sentinels): Advertise add-function. --- doc/lispref/ChangeLog | 9 ++++++--- doc/lispref/processes.texi | 8 ++++++++ 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index f538b960b50..57eb1bf074d 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,8 +1,11 @@ +2014-04-29 Stefan Monnier + + * processes.texi (Filter Functions, Sentinels): Advertise add-function. + 2014-04-24 Eli Zaretskii - * strings.texi (Text Comparison): Mention - equal-including-properties for when text properties of the strings - matter for comparison. + * strings.texi (Text Comparison): Mention equal-including-properties + for when text properties of the strings matter for comparison. 2014-04-21 Eli Zaretskii diff --git a/doc/lispref/processes.texi b/doc/lispref/processes.texi index ad62b4fff63..c91afdffdeb 100644 --- a/doc/lispref/processes.texi +++ b/doc/lispref/processes.texi @@ -1364,6 +1364,10 @@ which inserts the process output into the process buffer. This function returns the filter function of @var{process}. @end defun +In case the process's output needs to be passed to several filters, you can +use @code{add-function} to combine an existing filter with a new one. +@xref{Advising Functions}. + Here is an example of the use of a filter function: @smallexample @@ -1617,6 +1621,10 @@ sentinel, the eventual call to the sentinel will use the new one. This function returns the sentinel of @var{process}. @end defun +In case a process status changes need to be passed to several sentinels, you +can use @code{add-function} to combine an existing sentinel with a new one. +@xref{Advising Functions}. + @defun waiting-for-user-input-p While a sentinel or filter function is running, this function returns non-@code{nil} if Emacs was waiting for keyboard input from the user at From d7e9a7f87a616abc20ce460e34854807b0cd681d Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Tue, 29 Apr 2014 17:45:24 +0300 Subject: [PATCH 09/19] Fix bug #17362 with inconsistent usage of @key and @kbd, and key names. doc/emacs/trouble.texi (Quitting, DEL Does Not Delete, Emergency Escape) (Bug Criteria): Fix usage of @kbd and @key. (Bug#17362) doc/emacs/text.texi (Words, Pages, Foldout, HTML Mode): Fix usage of @kbd and @key. doc/emacs/search.texi (Special Isearch, Regexp Search): Fix usage of @kbd and @key. doc/emacs/screen.texi (Echo Area, Menu Bar): Fix usage of @kbd and @key. doc/emacs/rmail.texi (Rmail Scrolling): Fix usage of @kbd and @key. doc/emacs/programs.texi (Hungry Delete, Other C Commands): Fix usage of @kbd and @key. doc/emacs/picture-xtra.texi (Insert in Picture): Fix usage of @kbd and @key. doc/emacs/mule.texi (Unibyte Mode, Bidirectional Editing): Fix usage of @kbd and @key. doc/emacs/msdog.texi (Windows Keyboard, Windows Processes): Fix usage of @kbd and @key. doc/emacs/msdog-xtra.texi (MS-DOS Keyboard, MS-DOS Printing) (MS-DOS Processes): Fix usage of @kbd and @key. doc/emacs/misc.texi (Shell Ring, Printing Package): Fix usage of @kbd and @key. doc/emacs/mini.texi (Completion Commands, Minibuffer History): Fix usage of @kbd and @key. doc/emacs/kmacro.texi (Keyboard Macro Step-Edit): Fix usage of @kbd and @key. doc/emacs/killing.texi (Deletion, Rectangles, CUA Bindings): Fix usage of @kbd and @key. doc/emacs/indent.texi (Indentation Commands): Fix usage of @kbd and @key. doc/emacs/help.texi (Help Mode, Misc Help): Fix usage of @kbd and @key. doc/emacs/glossary.texi (Glossary): Fix usage of @kbd and @key. doc/emacs/frames.texi (Speedbar): Fix usage of @kbd and @key. doc/emacs/files.texi (Misc File Ops, File Name Cache, File Conveniences) (Filesets): Fix usage of @kbd and @key. doc/emacs/display.texi (View Mode): Fix usage of @kbd and @key. doc/emacs/dired.texi (Image-Dired): Fix usage of @kbd and @key. doc/emacs/custom.texi (Modifier Keys, Function Keys, Named ASCII Chars) (Init Syntax): Fix usage of @kbd and @key. doc/emacs/commands.texi (User Input): Fix usage of @kbd and @key. doc/emacs/calendar.texi (Counting Days, General Calendar): Fix usage of @kbd and @key. doc/emacs/building.texi (Threads Buffer): Fix usage of @kbd and @key. doc/emacs/buffers.texi (Select Buffer, Icomplete): Fix usage of @kbd and @key. doc/emacs/basic.texi (Inserting Text, Erasing, Arguments): Fix usage of @kbd and @key. --- doc/emacs/ChangeLog | 73 +++++++++++++++++++++++++++++++++++++ doc/emacs/basic.texi | 12 +++--- doc/emacs/buffers.texi | 23 ++++++------ doc/emacs/building.texi | 2 +- doc/emacs/calendar.texi | 12 +++--- doc/emacs/commands.texi | 14 +++---- doc/emacs/custom.texi | 14 +++---- doc/emacs/dired.texi | 8 ++-- doc/emacs/display.texi | 2 +- doc/emacs/files.texi | 19 +++++----- doc/emacs/frames.texi | 4 +- doc/emacs/glossary.texi | 30 +++++++-------- doc/emacs/help.texi | 10 ++--- doc/emacs/indent.texi | 4 +- doc/emacs/killing.texi | 10 ++--- doc/emacs/kmacro.texi | 20 +++++----- doc/emacs/mini.texi | 12 +++--- doc/emacs/misc.texi | 14 +++---- doc/emacs/msdog-xtra.texi | 30 +++++++-------- doc/emacs/msdog.texi | 20 +++++----- doc/emacs/mule.texi | 14 +++---- doc/emacs/picture-xtra.texi | 12 +++--- doc/emacs/programs.texi | 12 +++--- doc/emacs/rmail.texi | 2 +- doc/emacs/screen.texi | 4 +- doc/emacs/search.texi | 6 +-- doc/emacs/text.texi | 8 ++-- doc/emacs/trouble.texi | 22 +++++------ 28 files changed, 244 insertions(+), 169 deletions(-) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index 1e002127be6..65847ebac8e 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -1,3 +1,76 @@ +2014-04-29 Eli Zaretskii + + * trouble.texi (Quitting, DEL Does Not Delete, Emergency Escape) + (Bug Criteria): Fix usage of @kbd and @key. (Bug#17362) + + * text.texi (Words, Pages, Foldout, HTML Mode): Fix usage of @kbd + and @key. + + * search.texi (Special Isearch, Regexp Search): Fix usage of @kbd + and @key. + + * screen.texi (Echo Area, Menu Bar): Fix usage of @kbd and @key. + + * rmail.texi (Rmail Scrolling): Fix usage of @kbd and @key. + + * programs.texi (Hungry Delete, Other C Commands): Fix usage of + @kbd and @key. + + * picture-xtra.texi (Insert in Picture): Fix usage of @kbd and + @key. + + * mule.texi (Unibyte Mode, Bidirectional Editing): Fix usage of + @kbd and @key. + + * msdog.texi (Windows Keyboard, Windows Processes): Fix usage of + @kbd and @key. + + * msdog-xtra.texi (MS-DOS Keyboard, MS-DOS Printing) + (MS-DOS Processes): Fix usage of @kbd and @key. + + * misc.texi (Shell Ring, Printing Package): Fix usage of @kbd and + @key. + + * mini.texi (Completion Commands, Minibuffer History): Fix usage + of @kbd and @key. + + * kmacro.texi (Keyboard Macro Step-Edit): Fix usage of @kbd and + @key. + + * killing.texi (Deletion, Rectangles, CUA Bindings): Fix usage of + @kbd and @key. + + * indent.texi (Indentation Commands): Fix usage of @kbd and @key. + + * help.texi (Help Mode, Misc Help): Fix usage of @kbd and @key. + + * glossary.texi (Glossary): Fix usage of @kbd and @key. + + * frames.texi (Speedbar): Fix usage of @kbd and @key. + + * files.texi (Misc File Ops, File Name Cache, File Conveniences) + (Filesets): Fix usage of @kbd and @key. + + * display.texi (View Mode): Fix usage of @kbd and @key. + + * dired.texi (Image-Dired): Fix usage of @kbd and @key. + + * custom.texi (Modifier Keys, Function Keys, Named ASCII Chars) + (Init Syntax): Fix usage of @kbd and @key. + + * commands.texi (User Input): Fix usage of @kbd and @key. + + * calendar.texi (Counting Days, General Calendar): Fix usage of + @kbd and @key. + + * building.texi (Threads Buffer): Fix usage of @kbd and @key. + + * buffers.texi (Select Buffer, Icomplete): Fix usage of @kbd and + @key. + + * basic.texi (Inserting Text, Erasing, Arguments): Fix usage of + @kbd and @key. + 2014-04-26 Eli Zaretskii * sending.texi (Mail Signature): Document signature variables used diff --git a/doc/emacs/basic.texi b/doc/emacs/basic.texi index c5ded11c62e..3e8129c9d50 100644 --- a/doc/emacs/basic.texi +++ b/doc/emacs/basic.texi @@ -67,7 +67,7 @@ instead of shoving it to the right. @xref{Minor Modes}. @findex quoted-insert Only graphic characters can be inserted by typing the associated key; other keys act as editing commands and do not insert themselves. -For instance, @kbd{DEL} runs the command @code{delete-backward-char} +For instance, @key{DEL} runs the command @code{delete-backward-char} by default (some modes bind it to a different command); it does not insert a literal @samp{DEL} character (@acronym{ASCII} character code 127). @@ -366,7 +366,7 @@ moves down into it. @table @kbd @item @key{DEL} -@itemx @key{Backspace} +@itemx @key{BACKSPACE} Delete the character before point, or the region if it is active (@code{delete-backward-char}). @@ -394,20 +394,20 @@ the preceding newline, joining this line to the previous one. If, however, the region is active, @kbd{@key{DEL}} instead deletes the text in the region. @xref{Mark}, for a description of the region. - On most keyboards, @key{DEL} is labeled @key{Backspace}, but we + On most keyboards, @key{DEL} is labeled @key{BACKSPACE}, but we refer to it as @key{DEL} in this manual. (Do not confuse @key{DEL} with the @key{Delete} key; we will discuss @key{Delete} momentarily.) On some text terminals, Emacs may not recognize the @key{DEL} key properly. @xref{DEL Does Not Delete}, if you encounter this problem. - The @key{delete} (@code{delete-forward-char}) command deletes in the + The @key{Delete} (@code{delete-forward-char}) command deletes in the ``opposite direction'': it deletes the character after point, i.e., the character under the cursor. If point was at the end of a line, this joins the following line onto this one. Like @kbd{@key{DEL}}, it deletes the text in the region if the region is active (@pxref{Mark}). @kbd{C-d} (@code{delete-char}) deletes the character after point, -similar to @key{delete}, but regardless of whether the region is +similar to @key{Delete}, but regardless of whether the region is active. @xref{Deletion}, for more detailed information about the above @@ -723,7 +723,7 @@ M-5 C-n moves down five lines. The keys @kbd{M-1}, @kbd{M-2}, and so on, as well as @kbd{M--}, are bound to commands (@code{digit-argument} and @code{negative-argument}) that set up an argument for the next -command. @kbd{Meta--} without digits normally means @minus{}1. +command. @kbd{M--} without digits normally means @minus{}1. If you enter more than one digit, you need not hold down the @key{META} key for the second and subsequent digits. Thus, to move diff --git a/doc/emacs/buffers.texi b/doc/emacs/buffers.texi index 3f55cf7076e..3c2beae28ef 100644 --- a/doc/emacs/buffers.texi +++ b/doc/emacs/buffers.texi @@ -74,9 +74,9 @@ Similar, but select @var{buffer} in another window @item C-x 5 b @var{buffer} @key{RET} Similar, but select @var{buffer} in a separate frame (@code{switch-to-buffer-other-frame}). -@item C-x @key{LEFT} +@item C-x @key{left} Select the previous buffer in the buffer list (@code{previous-buffer}). -@item C-x @key{RIGHT} +@item C-x @key{right} Select the next buffer in the buffer list (@code{next-buffer}). @item C-u M-g M-g @itemx C-u M-g g @@ -110,15 +110,15 @@ it, Emacs asks for the file name to use, and the buffer's major mode is re-established taking that file name into account (@pxref{Choosing Modes}). -@kindex C-x @key{LEFT} -@kindex C-x @key{RIGHT} +@kindex C-x @key{left} +@kindex C-x @key{right} @findex next-buffer @findex previous-buffer For conveniently switching between a few buffers, use the commands -@kbd{C-x @key{LEFT}} and @kbd{C-x @key{RIGHT}}. @kbd{C-x @key{LEFT}} +@kbd{C-x @key{left}} and @kbd{C-x @key{right}}. @kbd{C-x @key{left}} (@code{previous-buffer}) selects the previous buffer (following the order of most recent selection in the current frame), while @kbd{C-x -@key{RIGHT}} (@code{next-buffer}) moves through buffers in the reverse +@key{right}} (@code{next-buffer}) moves through buffers in the reverse direction. @kindex C-x 4 b @@ -661,17 +661,18 @@ element among the possible completions in a minibuffer. When enabled, typing in the minibuffer continuously displays a list of possible completions that match the string you have typed. - At any time, you can type @key{C-j} to select the first completion in + At any time, you can type @kbd{C-j} to select the first completion in the list. So the way to select a particular completion is to make it the first in the list. There are two ways to do this. You can type more of the completion name and thus narrow down the list, excluding unwanted completions above the desired one. Alternatively, you can use @kbd{C-.} and @kbd{C-,} to rotate the list until the desired buffer is first. - @key{M-TAB} will select the first completion in the list, like @key{C-j} but -without exiting the minibuffer, so you can edit it further. This is typically -used when entering a file name, where @key{M-TAB} can be used a few times to -descend in the hierarchy of directories. + @kbd{M-@key{TAB}} will select the first completion in the list, like +@kbd{C-j} but without exiting the minibuffer, so you can edit it +further. This is typically used when entering a file name, where +@kbd{M-@key{TAB}} can be used a few times to descend in the hierarchy +of directories. To enable Icomplete mode, type @kbd{M-x icomplete-mode}, or customize the variable @code{icomplete-mode} to @code{t} (@pxref{Easy diff --git a/doc/emacs/building.texi b/doc/emacs/building.texi index a0ef9e80c8d..e0ed11ff862 100644 --- a/doc/emacs/building.texi +++ b/doc/emacs/building.texi @@ -1005,7 +1005,7 @@ non-@code{nil}, the GDB Threads buffer is the one shown by default. The GDB Threads buffer displays a summary of the threads in the debugged program. @xref{Threads, Threads, Debugging programs with multiple threads, gdb, The GNU debugger}. To select a thread, move -point there and type @key{RET} (@code{gdb-select-thread}), or click on +point there and press @key{RET} (@code{gdb-select-thread}), or click on it with @kbd{Mouse-2}. This also displays the associated source buffer, and updates the contents of the other GDB buffers. diff --git a/doc/emacs/calendar.texi b/doc/emacs/calendar.texi index ef6d44a968f..07226883c99 100644 --- a/doc/emacs/calendar.texi +++ b/doc/emacs/calendar.texi @@ -288,7 +288,7 @@ Display the number of days in the current region @kindex M-= @r{(Calendar mode)} @findex calendar-count-days-region To determine the number of days in a range, set the mark on one -date using @kbd{C-SPC}, move point to another date, and type @kbd{M-=} +date using @kbd{C-@key{SPC}}, move point to another date, and type @kbd{M-=} (@code{calendar-count-days-region}). The numbers of days shown is @emph{inclusive}; that is, it includes the days specified by mark and point. @@ -301,10 +301,10 @@ point. Display day-in-year (@code{calendar-print-day-of-year}). @item C-c C-l Regenerate the calendar window (@code{calendar-redraw}). -@item SPC +@item @key{SPC} Scroll the next window up (@code{scroll-other-window}). -@item DEL -@itemx S-SPC +@item @key{DEL} +@itemx S-@key{SPC} Scroll the next window down (@code{scroll-other-window-down}). @item q Exit from calendar (@code{calendar-exit}). @@ -327,8 +327,8 @@ date. non-Calendar-mode editing commands.) @kindex SPC @r{(Calendar mode)} - In Calendar mode, you can use @kbd{SPC} (@code{scroll-other-window}) -and @kbd{DEL} (@code{scroll-other-window-down}) to scroll the other + In Calendar mode, you can use @key{SPC} (@code{scroll-other-window}) +and @key{DEL} (@code{scroll-other-window-down}) to scroll the other window (if there is one) up or down, respectively. This is handy when you display a list of holidays or diary entries in another window. diff --git a/doc/emacs/commands.texi b/doc/emacs/commands.texi index 1c9b7fc220d..10612de82bb 100644 --- a/doc/emacs/commands.texi +++ b/doc/emacs/commands.texi @@ -42,28 +42,28 @@ are certain characters found on non-English keyboards @cindex modifier keys @cindex Control @cindex C- -@cindex Meta +@cindex META @cindex M- Emacs also recognizes control characters that are entered using @dfn{modifier keys}. Two commonly-used modifier keys are -@key{Control} (usually labeled @key{Ctrl}), and @key{Meta} (usually -labeled @key{Alt})@footnote{We refer to @key{Alt} as @key{Meta} for +@key{Control} (usually labeled @key{Ctrl}), and @key{META} (usually +labeled @key{Alt})@footnote{We refer to @key{Alt} as @key{META} for historical reasons.}. For example, @kbd{Control-a} is entered by holding down the @key{Ctrl} key while pressing @kbd{a}; we will refer -to this as @kbd{C-a} for short. Similarly @kbd{Meta-a}, or @kbd{M-a} +to this as @kbd{C-a} for short. Similarly @kbd{@key{META}-a}, or @kbd{M-a} for short, is entered by holding down the @key{Alt} key and pressing @kbd{a}. Modifier keys can also be applied to non-alphanumerical characters, e.g., @kbd{C-@key{F1}} or @kbd{M-@key{left}}. -@cindex @key{ESC} replacing @key{Meta} key +@cindex @key{ESC} replacing @key{META} key You can also type Meta characters using two-character sequences starting with @key{ESC}. Thus, you can enter @kbd{M-a} by typing @kbd{@key{ESC} a}. You can enter @kbd{C-M-a} by typing @kbd{@key{ESC} -C-a}. Unlike @key{Meta}, @key{ESC} is entered as a separate +C-a}. Unlike @key{META}, @key{ESC} is entered as a separate character. You don't hold down @key{ESC} while typing the next character; instead, press @key{ESC} and release it, then enter the next character. This feature is useful on certain text terminals -where the @key{Meta} key does not function reliably. +where the @key{META} key does not function reliably. @cindex keys stolen by window manager @cindex window manager, keys stolen by diff --git a/doc/emacs/custom.texi b/doc/emacs/custom.texi index bb02f1e7c9f..96f2ef2107c 100644 --- a/doc/emacs/custom.texi +++ b/doc/emacs/custom.texi @@ -1766,11 +1766,11 @@ historical. characters case-sensitive when you customize Emacs. For instance, you could make @kbd{M-a} and @kbd{M-A} run different commands. - Although only the @key{Control} and @key{Meta} modifier keys are + Although only the @key{Control} and @key{META} modifier keys are commonly used, Emacs supports three other modifier keys. These are called @key{Super}, @key{Hyper} and @key{Alt}. Few terminals provide ways to use these modifiers; the key labeled @key{Alt} on most -keyboards usually issues the @key{Meta} modifier, not @key{Alt}. The +keyboards usually issues the @key{META} modifier, not @key{Alt}. The standard key bindings in Emacs do not include any characters with these modifiers. However, you can customize Emacs to assign meanings to them. The modifier bits are labeled as @samp{s-}, @samp{H-} and @@ -1836,8 +1836,8 @@ translates these keys to the corresponding keys in the main keyboard. For example, when @samp{Num Lock} is on, the key labeled @samp{8} on the numeric keypad produces @code{kp-8}, which is translated to @kbd{8}; when @samp{Num Lock} is off, the same key produces -@code{kp-up}, which is translated to @key{UP}. If you rebind a key -such as @kbd{8} or @key{UP}, it affects the equivalent keypad key too. +@code{kp-up}, which is translated to @key{up}. If you rebind a key +such as @kbd{8} or @key{up}, it affects the equivalent keypad key too. However, if you rebind a @samp{kp-} key directly, that won't affect its non-keypad equivalent. Note that the modified keys are not translated: for instance, if you hold down the @key{META} key while @@ -1860,7 +1860,7 @@ started out as names for certain @acronym{ASCII} control characters, used so often that they have special keys of their own. For instance, @key{TAB} was another name for @kbd{C-i}. Later, users found it convenient to distinguish in Emacs between these keys and the ``same'' -control characters typed with the @key{CTRL} key. Therefore, on most +control characters typed with the @key{Ctrl} key. Therefore, on most modern terminals, they are no longer the same: @key{TAB} is different from @kbd{C-i}. @@ -2187,8 +2187,8 @@ sequences are mandatory. @samp{\C-} can be used as a prefix for a control character, as in @samp{\C-s} for @acronym{ASCII} control-S, and @samp{\M-} can be used as a prefix for -a Meta character, as in @samp{\M-a} for @kbd{Meta-A} or @samp{\M-\C-a} for -@kbd{Control-Meta-A}. +a Meta character, as in @samp{\M-a} for @kbd{@key{META}-A} or +@samp{\M-\C-a} for @kbd{@key{Ctrl}-@key{META}-A}. @xref{Init Non-ASCII}, for information about including non-@acronym{ASCII} in your init file. diff --git a/doc/emacs/dired.texi b/doc/emacs/dired.texi index f0db7b69205..4e9dfd5d12a 100644 --- a/doc/emacs/dired.texi +++ b/doc/emacs/dired.texi @@ -1312,19 +1312,19 @@ takes a long time if the directory contains many image files, and it asks for confirmation if the number of image files exceeds @code{image-dired-show-all-from-dir-max-files}. - With point in the thumbnail buffer, you can type @kbd{RET} + With point in the thumbnail buffer, you can type @key{RET} (@code{image-dired-display-thumbnail-original-image}) to display a sized version of it in another window. This sizes the image to fit the window. Use the arrow keys to move around in the buffer. For -easy browsing, use @kbd{SPC} +easy browsing, use @key{SPC} (@code{image-dired-display-next-thumbnail-original}) to advance and -display the next image. Typing @kbd{DEL} +display the next image. Typing @key{DEL} (@code{image-dired-display-previous-thumbnail-original}) backs up to the previous thumbnail and displays that instead. @vindex image-dired-external-viewer To view and the image in its original size, either provide a prefix -argument (@kbd{C-u}) before pressing @kbd{RET}, or type +argument (@kbd{C-u}) before pressing @key{RET}, or type @kbd{C-@key{RET}} (@code{image-dired-thumbnail-display-external}) to display the image in an external viewer. You must first configure @code{image-dired-external-viewer}. diff --git a/doc/emacs/display.texi b/doc/emacs/display.texi index 03de755aff3..bdcb185a5f3 100644 --- a/doc/emacs/display.texi +++ b/doc/emacs/display.texi @@ -428,7 +428,7 @@ it. @xref{Disabling}. screenfuls. It provides commands for scrolling through the buffer conveniently but not for changing it. Apart from the usual Emacs cursor motion commands, you can type @key{SPC} to scroll forward one -windowful, @key{S-SPC} or @key{DEL} to scroll backward, and @kbd{s} to +windowful, @key{S-@key{SPC}} or @key{DEL} to scroll backward, and @kbd{s} to start an incremental search. @kindex q @r{(View mode)} diff --git a/doc/emacs/files.texi b/doc/emacs/files.texi index 9310c44f1e6..894e61d0f04 100644 --- a/doc/emacs/files.texi +++ b/doc/emacs/files.texi @@ -1569,10 +1569,11 @@ old meaning of the name @var{new} to be lost. If @var{old} and @var{new} are on different file systems, the file @var{old} is copied and deleted. If the argument @var{new} is just a directory name, the real new name is in that directory, with the same non-directory -component as @var{old}. For example, @kbd{M-x rename-file RET ~/foo -RET /tmp RET} renames @file{~/foo} to @file{/tmp/foo}. The same rule -applies to all the remaining commands in this section. All of them -ask for confirmation when the new file name already exists, too. +component as @var{old}. For example, @kbd{M-x rename-file @key{RET} +~/foo @key{RET} /tmp @key{RET}} renames @file{~/foo} to +@file{/tmp/foo}. The same rule applies to all the remaining commands +in this section. All of them ask for confirmation when the new file +name already exists, too. @ifnottex If a file is under version control (@pxref{Version Control}), you @@ -1887,11 +1888,11 @@ then specifying @file{/tmp/foo*bar} will visit only @findex file-cache-minibuffer-complete You can use the @dfn{file name cache} to make it easy to locate a file by name, without having to remember exactly where it is located. -When typing a file name in the minibuffer, @kbd{C-@key{tab}} +When typing a file name in the minibuffer, @kbd{C-@key{TAB}} (@code{file-cache-minibuffer-complete}) completes it using the file -name cache. If you repeat @kbd{C-@key{tab}}, that cycles through the +name cache. If you repeat @kbd{C-@key{TAB}}, that cycles through the possible completions of what you had originally typed. (However, note -that the @kbd{C-@key{tab}} character cannot be typed on most text +that the @kbd{C-@key{TAB}} character cannot be typed on most text terminals.) The file name cache does not fill up automatically. Instead, you @@ -1971,7 +1972,7 @@ previous image file in the same directory, respectively. @vindex image-animate-loop @cindex image animation @cindex animated images - If the image can be animated, the command @kbd{RET} + If the image can be animated, the command @key{RET} (@code{image-toggle-animation}) starts or stops the animation. Animation plays once, unless the option @code{image-animate-loop} is non-@code{nil}. With @kbd{f} (@code{image-next-frame}) and @kbd{b} @@ -2024,7 +2025,7 @@ adds a @samp{Filesets} menu to the menu bar. @findex filesets-remove-buffer The simplest way to define a fileset is by adding files to it one at a time. To add a file to fileset @var{name}, visit the file and type -@kbd{M-x filesets-add-buffer @kbd{RET} @var{name} @kbd{RET}}. If +@kbd{M-x filesets-add-buffer @key{RET} @var{name} @key{RET}}. If there is no fileset @var{name}, this creates a new one, which initially contains only the current file. The command @kbd{M-x filesets-remove-buffer} removes the current file from a fileset. diff --git a/doc/emacs/frames.texi b/doc/emacs/frames.texi index b9925e57f4a..8dd387b5fa0 100644 --- a/doc/emacs/frames.texi +++ b/doc/emacs/frames.texi @@ -802,8 +802,8 @@ When a file or directory is expanded, the @samp{[+]} changes to hiding its contents. You navigate through the speedbar using the keyboard, too. Typing -@kbd{RET} while point is on a line in the speedbar is equivalent to -clicking the item on the current line, and @kbd{SPC} expands or +@key{RET} while point is on a line in the speedbar is equivalent to +clicking the item on the current line, and @key{SPC} expands or contracts the item. @kbd{U} displays the parent directory of the current directory. To copy, delete, or rename the file on the current line, type @kbd{C}, @kbd{D}, and @kbd{R} respectively. To create a diff --git a/doc/emacs/glossary.texi b/doc/emacs/glossary.texi index 4384a02cd6f..7d2194918fa 100644 --- a/doc/emacs/glossary.texi +++ b/doc/emacs/glossary.texi @@ -26,10 +26,10 @@ When the mark is active, we call the region an active region. @item Alt Alt is the name of a modifier bit that a keyboard input character may -have. To make a character Alt, type it while holding down the @key{ALT} -key. Such characters are given names that start with @kbd{Alt-} +have. To make a character Alt, type it while holding down the @key{Alt} +key. Such characters are given names that start with @kbd{@key{Alt}-} (usually written @kbd{A-} for short). (Note that many terminals have a -key labeled @key{ALT} that is really a @key{META} key.) @xref{User +key labeled @key{Alt} that is really a @key{META} key.) @xref{User Input, Alt}. @item Argument @@ -269,8 +269,8 @@ lines. @xref{Continuation Lines}. A related Emacs feature is @item Control Character A control character is a character that you type by holding down the -@key{CTRL} key. Some control characters also have their own keys, so -that you can type them without using @key{CTRL}. For example, +@key{Ctrl} key. Some control characters also have their own keys, so +that you can type them without using @key{Ctrl}. For example, @key{RET}, @key{TAB}, @key{ESC} and @key{DEL} are all control characters. @xref{User Input}. @@ -284,8 +284,8 @@ around to empower users and encourage them to cooperate. The particular form of copyleft used by the GNU project is called the GNU General Public License. @xref{Copying}. -@item @key{CTRL} -The @key{CTRL} or ``control'' key is what you hold down +@item @key{Ctrl} +The @key{Ctrl} or ``control'' key is what you hold down in order to enter a control character (q.v.). @xref{Glossary---C-}. @item Current Buffer @@ -356,8 +356,8 @@ A defun is a major definition at the top level in a program. The name @item @key{DEL} @key{DEL} is a character that runs the command to delete one character -of text before the cursor. It is typically either the @key{DELETE} -key or the @key{BACKSPACE} key, whichever one is easy to type. +of text before the cursor. It is typically either the @key{Delete} +key or the @key{Backspace} key, whichever one is easy to type. @xref{Erasing,DEL}. @item Deletion @@ -687,7 +687,7 @@ changing any of its code. @xref{Hooks}. @item Hyper Hyper is the name of a modifier bit that a keyboard input character may have. To make a character Hyper, type it while holding down the -@key{HYPER} key. Such characters are given names that start with +@key{Hyper} key. Such characters are given names that start with @kbd{Hyper-} (usually written @kbd{H-} for short). @xref{User Input}. @item Iff @@ -842,7 +842,7 @@ A local value of a variable (q.v.@:) applies to only one buffer. @xref{Locals}. @item @kbd{M-} -@kbd{M-} in the name of a character is an abbreviation for @key{META}, +@kbd{M-} in the name of a character is an abbreviation for @key{Meta}, one of the modifier keys that can accompany any character. @xref{User Input,M-}. @@ -900,16 +900,16 @@ a keyboard interface to navigate it. @xref{Menu Bars}. @item Meta Meta is the name of a modifier bit which you can use in a command -character. To enter a meta character, you hold down the @key{META} +character. To enter a meta character, you hold down the @key{Meta} key while typing the character. We refer to such characters with names that start with @kbd{Meta-} (usually written @kbd{M-} for -short). For example, @kbd{M-<} is typed by holding down @key{META} +short). For example, @kbd{M-<} is typed by holding down @key{Meta} and at the same time typing @kbd{<} (which itself is done, on most terminals, by holding down @key{SHIFT} and typing @kbd{,}). @xref{User Input,Meta}. -On some terminals, the @key{META} key is actually labeled @key{ALT} -or @key{EDIT}. +On some terminals, the @key{Meta} key is actually labeled @key{Alt} +or @key{Edit}. @item Meta Character A Meta character is one whose character code includes the Meta bit. diff --git a/doc/emacs/help.texi b/doc/emacs/help.texi index 11694191f9c..19f0c41ec60 100644 --- a/doc/emacs/help.texi +++ b/doc/emacs/help.texi @@ -378,7 +378,7 @@ alphabetical order, change the variable Help buffers provide the same commands as View mode (@pxref{View Mode}); for instance, @key{SPC} scrolls forward, and @key{DEL} or -@kbd{S-SPC} scrolls backward. A few special commands are also +@kbd{S-@key{SPC}} scrolls backward. A few special commands are also provided: @table @kbd @@ -553,13 +553,13 @@ Emacs Lisp Reference Manual}). @findex describe-prefix-bindings You can get a list of subcommands for a particular prefix key by -typing @kbd{C-h}, @kbd{?}, or @kbd{F1} +typing @kbd{C-h}, @kbd{?}, or @key{F1} (@code{describe-prefix-bindings}) after the prefix key. (There are a few prefix keys for which not all of these keys work---those that provide their own bindings for one of them. One of these prefix keys -is @key{ESC} in combination with @kbd{C-h}, because @kbd{ESC C-h} is -actually @kbd{C-M-h}, which marks a defun. However, @kbd{ESC F1} and -@kbd{ESC ?} work fine.) +is @key{ESC} in combination with @kbd{C-h}, because @kbd{@key{ESC} C-h} is +actually @kbd{C-M-h}, which marks a defun. However, @kbd{@key{ESC} @key{F1}} +and @kbd{@key{ESC} ?} work fine.) @node Help Files @section Help Files diff --git a/doc/emacs/indent.texi b/doc/emacs/indent.texi index b254cfca43e..8340d1031ba 100644 --- a/doc/emacs/indent.texi +++ b/doc/emacs/indent.texi @@ -127,9 +127,9 @@ in the region, moving the affected lines as a ``rigid'' unit. If called with no argument, the command activates a transient mode for adjusting the indentation of the affected lines interactively. While -this transient mode is active, typing @key{LEFT} or @key{RIGHT} +this transient mode is active, typing @key{left} or @key{right} indents leftward and rightward, respectively, by one space. You can -also type @kbd{S-@key{LEFT}} or @kbd{S-@key{RIGHT}} to indent leftward +also type @kbd{S-@key{left}} or @kbd{S-@key{right}} to indent leftward or rightward to the next tab stop (@pxref{Tab Stops}). Typing any other key disables the transient mode, and resumes normal editing. diff --git a/doc/emacs/killing.texi b/doc/emacs/killing.texi index 48d7f93396b..45dbd5727ac 100644 --- a/doc/emacs/killing.texi +++ b/doc/emacs/killing.texi @@ -78,7 +78,7 @@ erase just one character or only whitespace. @table @kbd @item @key{DEL} -@itemx @key{Backspace} +@itemx @key{BACKSPACE} Delete the previous character, or the text in the region if it is active (@code{delete-backward-char}). @@ -841,7 +841,7 @@ shifting the original text to the right. @findex rectangle-mark-mode @cindex rectangular region - The command @kbd{C-x SPC} (@code{rectangle-mark-mode}) makes a + The command @kbd{C-x @key{SPC}} (@code{rectangle-mark-mode}) makes a @dfn{rectangular region}. It is a new feature introduced in GNU Emacs 24.4, and most commands now are still unaware of it, but kill and yank (@pxref{Killing}) do work on the rectangle. @@ -879,9 +879,9 @@ behavior, set the variable @code{cua-delete-selection} to @code{nil}. @cindex rectangle highlighting CUA mode provides enhanced rectangle support with visible -rectangle highlighting. Use @kbd{C-RET} to start a rectangle, +rectangle highlighting. Use @kbd{C-@key{RET}} to start a rectangle, extend it using the movement commands, and cut or copy it using -@kbd{C-x} or @kbd{C-c}. @kbd{RET} moves the cursor to the next +@kbd{C-x} or @kbd{C-c}. @key{RET} moves the cursor to the next (clockwise) corner of the rectangle, so you can easily expand it in any direction. Normal text you type is inserted to the left or right of each line in the rectangle (on the same side as the cursor). @@ -896,7 +896,7 @@ and yank commands, e.g., @kbd{C-1 C-c} copies the region into register @cindex global mark CUA mode also has a global mark feature which allows easy moving and -copying of text between buffers. Use @kbd{C-S-SPC} to toggle the +copying of text between buffers. Use @kbd{C-S-@key{SPC}} to toggle the global mark on and off. When the global mark is on, all text that you kill or copy is automatically inserted at the global mark, and text you type is inserted at the global mark rather than at the current diff --git a/doc/emacs/kmacro.texi b/doc/emacs/kmacro.texi index bc62faf7694..881c7ead933 100644 --- a/doc/emacs/kmacro.texi +++ b/doc/emacs/kmacro.texi @@ -506,7 +506,7 @@ keyboard input that you would use to invoke the macro---@kbd{C-x e} or @findex kmacro-step-edit-macro @kindex C-x C-k SPC You can interactively replay and edit the last keyboard -macro, one command at a time, by typing @kbd{C-x C-k SPC} +macro, one command at a time, by typing @kbd{C-x C-k @key{SPC}} (@code{kmacro-step-edit-macro}). Unless you quit the macro using @kbd{q} or @kbd{C-g}, the edited macro replaces the last macro on the macro ring. @@ -518,15 +518,15 @@ options. These actions are available: @itemize @bullet{} @item -@kbd{SPC} and @kbd{y} execute the current command, and advance to the +@key{SPC} and @kbd{y} execute the current command, and advance to the next command in the keyboard macro. @item -@kbd{n}, @kbd{d}, and @kbd{DEL} skip and delete the current command. +@kbd{n}, @kbd{d}, and @key{DEL} skip and delete the current command. @item @kbd{f} skips the current command in this execution of the keyboard macro, but doesn't delete it from the macro. @item -@kbd{@key{TAB}} executes the current command, as well as all similar +@key{TAB} executes the current command, as well as all similar commands immediately following the current command; for example, @key{TAB} may be used to insert a sequence of characters (corresponding to a sequence of @code{self-insert-command} commands). @@ -542,31 +542,31 @@ with the edited macro. @kbd{q} and @kbd{C-g} cancels the step-editing of the keyboard macro; discarding any changes made to the keyboard macro. @item -@kbd{i KEY... C-j} reads and executes a series of key sequences (not +@kbd{i @var{key}@dots{} C-j} reads and executes a series of key sequences (not including the final @kbd{C-j}), and inserts them before the current command in the keyboard macro, without advancing over the current command. @item -@kbd{I KEY...} reads one key sequence, executes it, and inserts it +@kbd{I @var{key}@dots{}} reads one key sequence, executes it, and inserts it before the current command in the keyboard macro, without advancing over the current command. @item -@kbd{r KEY... C-j} reads and executes a series of key sequences (not +@kbd{r @var{key}@dots{} C-j} reads and executes a series of key sequences (not including the final @kbd{C-j}), and replaces the current command in the keyboard macro with them, advancing over the inserted key sequences. @item -@kbd{R KEY...} reads one key sequence, executes it, and replaces the +@kbd{R @var{key}@dots{}} reads one key sequence, executes it, and replaces the current command in the keyboard macro with that key sequence, advancing over the inserted key sequence. @item -@kbd{a KEY... C-j} executes the current command, then reads and +@kbd{a @var{key}@dots{} C-j} executes the current command, then reads and executes a series of key sequences (not including the final @kbd{C-j}), and inserts them after the current command in the keyboard macro; it then advances over the current command and the inserted key sequences. @item -@kbd{A KEY... C-j} executes the rest of the commands in the keyboard +@kbd{A @var{key}@dots{} C-j} executes the rest of the commands in the keyboard macro, then reads and executes a series of key sequences (not including the final @kbd{C-j}), and appends them at the end of the keyboard macro; it then terminates the step-editing and replaces the diff --git a/doc/emacs/mini.texi b/doc/emacs/mini.texi index b575e4adbd3..8951c7dd5ee 100644 --- a/doc/emacs/mini.texi +++ b/doc/emacs/mini.texi @@ -357,12 +357,12 @@ While in the completion list buffer, this chooses the completion at point (@code{choose-completion}). @findex next-completion -@item @key{Right} +@item @key{right} While in the completion list buffer, this moves point to the following completion alternative (@code{next-completion}). @findex previous-completion -@item @key{Left} +@item @key{left} While in the completion list buffer, this moves point to the previous completion alternative (@code{previous-completion}). @end table @@ -587,11 +587,11 @@ argument into the minibuffer: @table @kbd @item M-p -@itemx @key{Up} +@itemx @key{up} Move to the previous item in the minibuffer history, an earlier argument (@code{previous-history-element}). @item M-n -@itemx @key{Down} +@itemx @key{down} Move to the next item in the minibuffer history (@code{next-history-element}). @item M-r @var{regexp} @key{RET} @@ -608,11 +608,11 @@ Move to a later item in the minibuffer history that matches @kindex DOWN @r{(minibuffer history)} @findex next-history-element @findex previous-history-element - While in the minibuffer, @kbd{M-p} or @key{Up} + While in the minibuffer, @kbd{M-p} or @key{up} (@code{previous-history-element}) moves through the minibuffer history list, one item at a time. Each @kbd{M-p} fetches an earlier item from the history list into the minibuffer, replacing its existing contents. -Typing @kbd{M-n} or @key{Down} (@code{next-history-element}) moves +Typing @kbd{M-n} or @key{down} (@code{next-history-element}) moves through the minibuffer history list in the opposite direction, fetching later entries into the minibuffer. diff --git a/doc/emacs/misc.texi b/doc/emacs/misc.texi index d444b6f8195..ce6f80618bd 100644 --- a/doc/emacs/misc.texi +++ b/doc/emacs/misc.texi @@ -932,13 +932,13 @@ resubmit them or copy them to the end. Or you can use a @findex comint-previous-input @kindex M-p @r{(Shell mode)} @item M-p -@itemx C-@key{UP} +@itemx C-@key{up} Fetch the next earlier old shell command. @kindex M-n @r{(Shell mode)} @findex comint-next-input @item M-n -@itemx C-@key{DOWN} +@itemx C-@key{down} Fetch the next later old shell command. @kindex M-r @r{(Shell mode)} @@ -975,7 +975,7 @@ buffer. Successive use of @kbd{M-p} fetches successively earlier shell commands, each replacing any text that was already present as potential shell input. @kbd{M-n} does likewise except that it finds successively more recent shell commands from the buffer. -@kbd{C-@key{UP}} works like @kbd{M-p}, and @kbd{C-@key{DOWN}} like +@kbd{C-@key{up}} works like @kbd{M-p}, and @kbd{C-@key{down}} like @kbd{M-n}. The history search command @kbd{M-r} begins an incremental regular @@ -999,8 +999,8 @@ can reexecute several successive commands by typing @kbd{C-c C-x @key{RET}} over and over. The command @kbd{C-c .}@: (@code{comint-input-previous-argument}) -copies an individual argument from a previous command, like @kbd{ESC -.} in Bash. The simplest use copies the last argument from the +copies an individual argument from a previous command, like +@kbd{@key{ESC} .} in Bash. The simplest use copies the last argument from the previous shell command. With a prefix argument @var{n}, it copies the @var{n}th argument instead. Repeating @kbd{C-c .} copies from an earlier shell command instead, always using the same value of @var{n} @@ -1918,11 +1918,11 @@ used. init file (@pxref{Init File}), followed by @code{(pr-update-menus)}. This function replaces the usual printing commands in the menu bar with a @samp{Printing} submenu that contains various printing options. -You can also type @kbd{M-x pr-interface RET}; this creates a +You can also type @kbd{M-x pr-interface @key{RET}}; this creates a @file{*Printing Interface*} buffer, similar to a customization buffer, where you can set the printing options. After selecting what and how to print, you start the print job using the @samp{Print} button (click -@kbd{mouse-2} on it, or move point over it and type @kbd{RET}). For +@kbd{Mouse-2} on it, or move point over it and type @key{RET}). For further information on the various options, use the @samp{Interface Help} button. diff --git a/doc/emacs/msdog-xtra.texi b/doc/emacs/msdog-xtra.texi index 5543926fafd..876be52282a 100644 --- a/doc/emacs/msdog-xtra.texi +++ b/doc/emacs/msdog-xtra.texi @@ -53,13 +53,13 @@ about Emacs's special handling of text files under MS-DOS (and Windows). The key that is called @key{DEL} in Emacs (because that's how it is designated on most workstations) is known as @key{BS} (backspace) on a PC@. That is why the PC-specific terminal initialization remaps the -@key{BS} key to act as @key{DEL}; the @key{DELETE} key is remapped to act +@key{BS} key to act as @key{DEL}; the @key{Delete} key is remapped to act as @kbd{C-d} for the same reasons. @kindex C-g @r{(MS-DOS)} -@kindex C-BREAK @r{(MS-DOS)} +@kindex C-Break @r{(MS-DOS)} @cindex quitting on MS-DOS - Emacs built for MS-DOS recognizes @kbd{C-@key{BREAK}} as a quit + Emacs built for MS-DOS recognizes @kbd{C-@key{Break}} as a quit character, just like @kbd{C-g}. This is because Emacs cannot detect that you have typed @kbd{C-g} until it is ready for more input. As a consequence, you cannot use @kbd{C-g} to stop a running command @@ -69,7 +69,7 @@ consequence, you cannot use @kbd{C-g} to stop a running command @ifnottex (@pxref{Quitting}). @end ifnottex -By contrast, @kbd{C-@key{BREAK}} @emph{is} detected as soon as you +By contrast, @kbd{C-@key{Break}} @emph{is} detected as soon as you type it (as @kbd{C-g} is on other systems), so it can be used to stop a running command and for emergency escape @iftex @@ -84,17 +84,17 @@ a running command and for emergency escape @cindex Super (under MS-DOS) @vindex dos-super-key @vindex dos-hyper-key - The PC keyboard maps use the left @key{ALT} key as the @key{META} key. + The PC keyboard maps use the left @key{Alt} key as the @key{META} key. You have two choices for emulating the @key{SUPER} and @key{HYPER} keys: -choose either the right @key{CTRL} key or the right @key{ALT} key by +choose either the right @key{Ctrl} key or the right @key{Alt} key by setting the variables @code{dos-hyper-key} and @code{dos-super-key} to 1 or 2 respectively. If neither @code{dos-super-key} nor -@code{dos-hyper-key} is 1, then by default the right @key{ALT} key is +@code{dos-hyper-key} is 1, then by default the right @key{Alt} key is also mapped to the @key{META} key. However, if the MS-DOS international keyboard support program @file{KEYB.COM} is installed, Emacs will -@emph{not} map the right @key{ALT} to @key{META}, since it is used for +@emph{not} map the right @key{Alt} to @key{META}, since it is used for accessing characters like @kbd{~} and @kbd{@@} on non-US keyboard -layouts; in this case, you may only use the left @key{ALT} as @key{META} +layouts; in this case, you may only use the left @key{Alt} as @key{META} key. @kindex C-j @r{(MS-DOS)} @@ -398,11 +398,11 @@ though they are connected to a Windows machine that uses a different encoding for the same locale. For example, in the Latin-1 locale, DOS uses codepage 850 whereas Windows uses codepage 1252. @xref{MS-DOS and MULE}. When you print to such printers from Windows, you can use the -@kbd{C-x RET c} (@code{universal-coding-system-argument}) command before -@kbd{M-x lpr-buffer}; Emacs will then convert the text to the DOS -codepage that you specify. For example, @kbd{C-x RET c cp850-dos RET -M-x lpr-region RET} will print the region while converting it to the -codepage 850 encoding. +@kbd{C-x @key{RET} c} (@code{universal-coding-system-argument}) command +before @kbd{M-x lpr-buffer}; Emacs will then convert the text to the DOS +codepage that you specify. For example, +@kbd{C-x @key{RET} c cp850-dos @key{RET} M-x lpr-region @key{RET}} +will print the region while converting it to the codepage 850 encoding. @vindex dos-printer @vindex dos-ps-printer @@ -597,7 +597,7 @@ work in MS-DOS by sending the output to one of the printer ports. program terminates and does not try to read keyboard input. If the program does not terminate on its own, you will be unable to terminate it, because MS-DOS provides no general way to terminate a process. -Pressing @kbd{C-c} or @kbd{C-@key{BREAK}} might sometimes help in these +Pressing @kbd{C-c} or @kbd{C-@key{Break}} might sometimes help in these cases. Accessing files on other machines is not supported on MS-DOS@. Other diff --git a/doc/emacs/msdog.texi b/doc/emacs/msdog.texi index 7708b8fe860..4787f98c7ed 100644 --- a/doc/emacs/msdog.texi +++ b/doc/emacs/msdog.texi @@ -479,7 +479,7 @@ the variable @code{w32-alt-is-meta} to a @code{nil} value. @findex w32-register-hot-key @findex w32-unregister-hot-key MS-Windows reserves certain key combinations, such as -@kbd{Alt-@key{TAB}}, for its own use. These key combinations are +@kbd{@key{Alt}-@key{TAB}}, for its own use. These key combinations are intercepted by the system before Emacs can see them. You can use the @code{w32-register-hot-key} function to allow a key sequence to be seen by Emacs instead of being grabbed by Windows. This function @@ -491,7 +491,7 @@ other Windows applications.) The argument to @code{w32-register-hot-key} must be a single key, with or without modifiers, in vector form that would be acceptable to -@code{define-key}. The meta modifier is interpreted as the @key{ALT} +@code{define-key}. The meta modifier is interpreted as the @key{Alt} key if @code{w32-alt-is-meta} is @code{t} (the default), and the hyper modifier is always interpreted as the Windows key (usually labeled with @key{start} and the Windows logo). If the function succeeds in @@ -499,10 +499,10 @@ registering the key sequence, it returns the hotkey ID, a number; otherwise it returns @code{nil}. @kindex M-TAB@r{, (MS-Windows)} -@cindex @kbd{M-@key{TAB}} vs @kbd{Alt-@key{TAB}} (MS-Windows) -@cindex @kbd{Alt-@key{TAB}} vs @kbd{M-@key{TAB}} (MS-Windows) +@cindex @kbd{M-@key{TAB}} vs @kbd{@key{Alt}-@key{TAB}} (MS-Windows) +@cindex @kbd{@key{Alt}-@key{TAB}} vs @kbd{M-@key{TAB}} (MS-Windows) For example, @code{(w32-register-hot-key [M-tab])} lets you use -@kbd{M-TAB} normally in Emacs; for instance, to complete the word or +@kbd{M-@key{TAB}} normally in Emacs; for instance, to complete the word or symbol at point at top level, or to complete the current search string against previously sought strings during incremental search. @@ -558,14 +558,14 @@ produces the symbol @code{scroll}. @cindex Windows system menu @cindex @code{Alt} key invokes menu (Windows) Emacs compiled as a native Windows application normally turns off -the Windows feature that tapping the @key{ALT} key invokes the Windows -menu. The reason is that the @key{ALT} serves as @key{META} in Emacs. +the Windows feature that tapping the @key{Alt} key invokes the Windows +menu. The reason is that the @key{Alt} serves as @key{META} in Emacs. When using Emacs, users often press the @key{META} key temporarily and then change their minds; if this has the effect of bringing up the Windows menu, it alters the meaning of subsequent commands. Many users find this frustrating. - You can re-enable Windows's default handling of tapping the @key{ALT} + You can re-enable Windows's default handling of tapping the @key{Alt} key by setting @code{w32-pass-alt-to-system} to a non-@code{nil} value. @@ -595,7 +595,7 @@ the combination of the right @key{Alt} and left @key{Ctrl} keys pressed together, is recognized as the @key{AltGr} key. The default is @code{t}, which means these keys produce @code{AltGr}; setting it to @code{nil} causes @key{AltGr} or the equivalent key combination to -be interpreted as the combination of @key{CTRL} and @key{META} +be interpreted as the combination of @key{Ctrl} and @key{META} modifiers. @end ifnottex @@ -674,7 +674,7 @@ subprocesses). If you have to reboot Windows 9X in this situation, do not use the @code{Shutdown} command on the @code{Start} menu; that usually hangs the -system. Instead, type @kbd{CTL-ALT-@key{DEL}} and then choose +system. Instead, type @kbd{@key{Ctrl}-@key{Alt}-@key{DEL}} and then choose @code{Shutdown}. That usually works, although it may take a few minutes to do its job. diff --git a/doc/emacs/mule.texi b/doc/emacs/mule.texi index 217d0af8fc4..839bd95ae5e 100644 --- a/doc/emacs/mule.texi +++ b/doc/emacs/mule.texi @@ -1671,11 +1671,11 @@ use these keys; they should simply work. On a text terminal, you should use the command @code{M-x set-keyboard-coding-system} or customize the variable @code{keyboard-coding-system} to specify which coding system your keyboard uses (@pxref{Terminal Coding}). Enabling this feature -will probably require you to use @kbd{ESC} to type Meta characters; +will probably require you to use @key{ESC} to type Meta characters; however, on a console terminal or in @code{xterm}, you can arrange for -Meta to be converted to @kbd{ESC} and still be able type 8-bit -characters present directly on the keyboard or using @kbd{Compose} or -@kbd{AltGr} keys. @xref{User Input}. +Meta to be converted to @key{ESC} and still be able type 8-bit +characters present directly on the keyboard or using @key{Compose} or +@key{AltGr} keys. @xref{User Input}. @kindex C-x 8 @cindex @code{iso-transl} library @@ -1689,8 +1689,8 @@ well as other buffers), for searching, and in any other context where a key sequence is allowed. @kbd{C-x 8} works by loading the @code{iso-transl} library. Once that -library is loaded, the @key{ALT} modifier key, if the keyboard has -one, serves the same purpose as @kbd{C-x 8}: use @key{ALT} together +library is loaded, the @key{Alt} modifier key, if the keyboard has +one, serves the same purpose as @kbd{C-x 8}: use @key{Alt} together with an accent character to modify the following letter. In addition, if the keyboard has keys for the Latin-1 ``dead accent characters'', they too are defined to compose with the following character, once @@ -1815,7 +1815,7 @@ inserting special formatting characters in front of the paragraph. The special character @code{RIGHT-TO-LEFT MARK}, or @sc{rlm}, forces the right-to-left direction on the following paragraph, while @code{LEFT-TO-RIGHT MARK}, or @sc{lrm} forces the left-to-right -direction. (You can use @kbd{C-x 8 RET} to insert these characters.) +direction. (You can use @kbd{C-x 8 @key{RET}} to insert these characters.) In a GUI session, the @sc{lrm} and @sc{rlm} characters display as very thin blank characters; on text terminals they display as blanks. diff --git a/doc/emacs/picture-xtra.texi b/doc/emacs/picture-xtra.texi index ba36faad709..724f1bc3a0c 100644 --- a/doc/emacs/picture-xtra.texi +++ b/doc/emacs/picture-xtra.texi @@ -151,26 +151,26 @@ character. This is useful for drawing lines in the buffer. @table @kbd @item C-c < -@itemx C-c @key{LEFT} +@itemx C-c @key{left} Move left after insertion (@code{picture-movement-left}). @item C-c > -@itemx C-c @key{RIGHT} +@itemx C-c @key{right} Move right after insertion (@code{picture-movement-right}). @item C-c ^ -@itemx C-c @key{UP} +@itemx C-c @key{up} Move up after insertion (@code{picture-movement-up}). @item C-c . -@itemx C-c @key{DOWN} +@itemx C-c @key{down} Move down after insertion (@code{picture-movement-down}). @item C-c ` -@itemx C-c @key{HOME} +@itemx C-c @key{Home} Move up and left (``northwest'') after insertion (@code{picture-movement-nw}). @item C-c ' @itemx C-c @key{prior} Move up and right (``northeast'') after insertion (@code{picture-movement-ne}). @item C-c / -@itemx C-c @key{END} +@itemx C-c @key{End} Move down and left (``southwest'') after insertion @*(@code{picture-movement-sw}). @item C-c \ diff --git a/doc/emacs/programs.texi b/doc/emacs/programs.texi index 55031e673dc..82bde754909 100644 --- a/doc/emacs/programs.texi +++ b/doc/emacs/programs.texi @@ -1675,12 +1675,12 @@ preprocessor commands. Delete the entire block of whitespace preceding point (@code{c-hungry-delete-backwards}). @item C-c C-d -@itemx C-c C-@key{DELETE} -@itemx C-c @key{DELETE} +@itemx C-c C-@key{Delete} +@itemx C-c @key{Delete} @findex c-hungry-delete-forward @kindex C-c C-d (C Mode) -@kindex C-c C-@key{DELETE} (C Mode) -@kindex C-c @key{DELETE} (C Mode) +@kindex C-c C-@key{Delete} (C Mode) +@kindex C-c @key{Delete} (C Mode) Delete the entire block of whitespace after point (@code{c-hungry-delete-forward}). @end table @@ -1688,7 +1688,7 @@ Delete the entire block of whitespace after point (@code{c-hungry-delete-forward delete mode}. When this feature is enabled (indicated by @samp{/h} in the mode line after the mode name), a single @key{DEL} deletes all preceding whitespace, not just one space, and a single @kbd{C-c C-d} -(but @emph{not} plain @key{DELETE}) deletes all following whitespace. +(but @emph{not} plain @key{Delete}) deletes all following whitespace. @table @kbd @item M-x c-toggle-hungry-state @@ -1717,7 +1717,7 @@ inserts a @samp{\} at the line break, and within comments it's like @code{c-context-line-break} isn't bound to a key by default, but it needs a binding to be useful. The following code will bind it to -@kbd{RET}. We use @code{c-initialization-hook} here to make sure +@key{RET}. We use @code{c-initialization-hook} here to make sure the keymap is loaded before we try to change it. @example diff --git a/doc/emacs/rmail.texi b/doc/emacs/rmail.texi index 2f823a757fe..6ba252393f6 100644 --- a/doc/emacs/rmail.texi +++ b/doc/emacs/rmail.texi @@ -101,7 +101,7 @@ frequent that it deserves to be easier. @item @key{SPC} Scroll forward (@code{scroll-up-command}). @item @key{DEL} -@itemx @key{S-SPC} +@itemx S-@key{SPC} Scroll backward (@code{scroll-down-command}). @item . Scroll to start of message (@code{rmail-beginning-of-message}). diff --git a/doc/emacs/screen.texi b/doc/emacs/screen.texi index 13a4c922c4d..d26b3bb49ff 100644 --- a/doc/emacs/screen.texi +++ b/doc/emacs/screen.texi @@ -123,7 +123,7 @@ beeping or by flashing the screen. you what the command has done, or to provide you with some specific information. These @dfn{informative} messages, unlike error messages, are not accompanied with a beep or flash. For example, @kbd{C-x =} -(hold down @key{CTRL} and type @kbd{x}, then let go of @key{CTRL} and +(hold down @key{Ctrl} and type @kbd{x}, then let go of @key{Ctrl} and type @kbd{=}) displays a message describing the character at point, its position in the buffer, and its current column in the window. Commands that take a long time often display messages ending in @@ -304,7 +304,7 @@ the usual way (@pxref{Key Help}). item by pressing @key{F10} (to run the command @code{menu-bar-open}). You can then navigate the menus with the arrow keys. To activate a selected menu item, press @key{RET}; to cancel menu navigation, press -@kbd{C-g} or @kbd{ESC ESC ESC}. +@kbd{C-g} or @kbd{@key{ESC} @key{ESC} @key{ESC}}. @findex tmm-menubar @vindex tty-menu-open-use-tmm diff --git a/doc/emacs/search.texi b/doc/emacs/search.texi index 99a05313890..5331f7da1b9 100644 --- a/doc/emacs/search.texi +++ b/doc/emacs/search.texi @@ -233,7 +233,7 @@ search string to a regular expression specified by the variable sequences of newlines as well as spaces, set it to @samp{"[[:space:]\n]+"}. - To toggle lax space matching, type @kbd{M-s SPC} + To toggle lax space matching, type @kbd{M-s @key{SPC}} (@code{isearch-toggle-lax-whitespace}). To disable this feature entirely, change @code{search-whitespace-regexp} to @code{nil}; then each space in the search string matches exactly one space. @@ -261,7 +261,7 @@ Type @kbd{C-q}, followed by a non-graphic character or a sequence of octal digits. This adds a character to the search string, similar to inserting into a buffer using @kbd{C-q} (@pxref{Inserting Text}). For example, @kbd{C-q C-s} during incremental search adds the -@key{control-S} character to the search string. +@samp{control-S} character to the search string. @item Type @kbd{C-x 8 @key{RET}}, followed by a Unicode name or code-point. @@ -605,7 +605,7 @@ They also have separate search rings, which you can access with Just as in ordinary incremental search, any @key{SPC} typed in incremental regexp search matches any sequence of one or more whitespace characters. The variable @code{search-whitespace-regexp} -specifies the regexp for the lax space matching, and @kbd{M-s SPC} +specifies the regexp for the lax space matching, and @kbd{M-s @key{SPC}} (@code{isearch-toggle-lax-whitespace}) toggles the feature. @xref{Special Isearch}. diff --git a/doc/emacs/text.texi b/doc/emacs/text.texi index 9eb8f467883..cebbdf9d95b 100644 --- a/doc/emacs/text.texi +++ b/doc/emacs/text.texi @@ -116,7 +116,7 @@ cognate to @kbd{C-@@}, which is an alias for @kbd{C-@key{SPC}}. @findex backward-word The commands @kbd{M-f} (@code{forward-word}) and @kbd{M-b} (@code{backward-word}) move forward and backward over words. These -@key{Meta}-based key sequences are analogous to the key sequences +@key{META}-based key sequences are analogous to the key sequences @kbd{C-f} and @kbd{C-b}, which move over single characters. The analogy extends to numeric arguments, which serve as repeat counts. @kbd{M-f} with a negative argument moves backward, and @kbd{M-b} with @@ -330,7 +330,7 @@ in Fundamental mode, @code{paragraph-start} is @w{@code{"\f\\|[ @cindex formfeed character Within some text files, text is divided into @dfn{pages} delimited by the @dfn{formfeed character} (@acronym{ASCII} code 12, also denoted -as @key{control-L}), which is displayed in Emacs as the escape +as @samp{control-L}), which is displayed in Emacs as the escape sequence @samp{^L} (@pxref{Text Display}). Traditionally, when such text files are printed to hardcopy, each formfeed character forces a page break. Most Emacs commands treat it just like any other @@ -1250,7 +1250,7 @@ quad click: exit all folds and hide text. @c FIXME not marked as a user variable @vindex foldout-mouse-modifiers You can specify different modifier keys (instead of -@kbd{Control-Meta-}) by setting @code{foldout-mouse-modifiers}; but if +@kbd{@key{Ctrl}-@key{META}-}) by setting @code{foldout-mouse-modifiers}; but if you have already loaded the @file{foldout.el} library, you must reload it in order for this to take effect. @@ -1910,7 +1910,7 @@ characters themselves (@code{sgml-name-8bit-mode}). Run a shell command (which you must specify) to validate the current buffer as SGML (@code{sgml-validate}). -@item C-c TAB +@item C-c @key{TAB} @kindex C-c TAB @r{(SGML mode)} @findex sgml-tags-invisible Toggle the visibility of existing tags in the buffer. This can be diff --git a/doc/emacs/trouble.texi b/doc/emacs/trouble.texi index 52e5b9c4045..bf7c6175dcb 100644 --- a/doc/emacs/trouble.texi +++ b/doc/emacs/trouble.texi @@ -21,7 +21,7 @@ also considered. @table @kbd @item C-g -@itemx C-@key{BREAK} @r{(MS-DOS only)} +@itemx C-@key{Break} @r{(MS-DOS only)} Quit: cancel running or partially typed command. @item C-] Abort innermost recursive editing level and cancel the command which @@ -58,11 +58,11 @@ incremental search, @kbd{C-g} behaves specially; it may take two successive @kbd{C-g} characters to get out of a search. @xref{Incremental Search}, for details. - On MS-DOS, the character @kbd{C-@key{BREAK}} serves as a quit character + On MS-DOS, the character @kbd{C-@key{Break}} serves as a quit character like @kbd{C-g}. The reason is that it is not feasible, on MS-DOS, to recognize @kbd{C-g} while a command is running, between interactions with the user. By contrast, it @emph{is} feasible to recognize -@kbd{C-@key{BREAK}} at all times. +@kbd{C-@key{Break}} at all times. @iftex @xref{MS-DOS Keyboard,,,emacs-xtra, Specialized Emacs Features}. @end iftex @@ -159,13 +159,13 @@ Emacs. @cindex @key{DEL} vs @key{BACKSPACE} @cindex @key{BACKSPACE} vs @key{DEL} - Every keyboard has a large key, usually labeled @key{Backspace}, + Every keyboard has a large key, usually labeled @key{BACKSPACE}, which is ordinarily used to erase the last character that you typed. In Emacs, this key is supposed to be equivalent to @key{DEL}. When Emacs starts up on a graphical display, it determines automatically which key should be @key{DEL}. In some unusual cases, -Emacs gets the wrong information from the system, and @key{Backspace} +Emacs gets the wrong information from the system, and @key{BACKSPACE} ends up deleting forwards instead of backwards. Some keyboards also have a @key{Delete} key, which is ordinarily @@ -173,9 +173,9 @@ used to delete forwards. If this key deletes backward in Emacs, that too suggests Emacs got the wrong information---but in the opposite sense. - On a text terminal, if you find that @key{Backspace} prompts for a + On a text terminal, if you find that @key{BACKSPACE} prompts for a Help command, like @kbd{Control-h}, instead of deleting a character, -it means that key is actually sending the @key{BS} character. Emacs +it means that key is actually sending the @samp{BS} character. Emacs ought to be treating @key{BS} as @key{DEL}, but it isn't. @findex normal-erase-is-backspace-mode @@ -189,8 +189,8 @@ sends character code 127. To fix the problem in every Emacs session, put one of the following lines into your initialization file (@pxref{Init File}). For the -first case above, where @key{Backspace} deletes forwards instead of -backwards, use this line to make @key{Backspace} act as @key{DEL}: +first case above, where @key{BACKSPACE} deletes forwards instead of +backwards, use this line to make @key{BACKSPACE} act as @key{DEL}: @lisp (normal-erase-is-backspace-mode 0) @@ -438,7 +438,7 @@ state. The quit you requested will happen by and by. displays, you can use the mouse to kill Emacs or switch to another program. - On MS-DOS, you must type @kbd{C-@key{BREAK}} (twice) to cause + On MS-DOS, you must type @kbd{C-@key{Break}} (twice) to cause emergency escape---but there are cases where it won't work, when system call hangs or when Emacs is stuck in a tight loop in C code. @@ -541,7 +541,7 @@ buffer or change how it is displayed, are not responsible. Taking forever to complete a command can be a bug, but you must make sure that it is really Emacs's fault. Some commands simply take a -long time. Type @kbd{C-g} (@kbd{C-@key{BREAK}} on MS-DOS) and then +long time. Type @kbd{C-g} (@kbd{C-@key{Break}} on MS-DOS) and then @kbd{C-h l} to see whether the input Emacs received was what you intended to type; if the input was such that you @emph{know} it should have been processed quickly, report a bug. If you don't know whether From ca489750c2c47e641fd78f2e3ea6276e3b54f5d4 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 29 Apr 2014 07:49:11 -0700 Subject: [PATCH 10/19] * configure.ac: Treat MirBSD as OpenBSD. Fixes: debbugs:17339 --- ChangeLog | 4 ++++ configure.ac | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index e23703edd07..1b0d403b0f4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2014-04-29 Glenn Morris + + * configure.ac: Treat MirBSD as OpenBSD. (Bug#17339) + 2014-04-16 Eli Zaretskii * config.bat: Update for Emacs 24.4. diff --git a/configure.ac b/configure.ac index 9d69e2670ec..c51d7b03e18 100644 --- a/configure.ac +++ b/configure.ac @@ -505,7 +505,7 @@ case "${canonical}" in ;; ## OpenBSD ports - *-*-openbsd* ) + *-*-openbsd* | *-*-mirbsd* ) opsys=openbsd ;; From 7ac903abc8cebd281b2ab263770e293c096bbfca Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 29 Apr 2014 07:54:58 -0700 Subject: [PATCH 11/19] * lib-src/Makefile.in ($(DESTDIR)${archlibdir}): Avoid non-portable "`\" nesting Fixes: debbugs:17339 --- lib-src/ChangeLog | 5 +++++ lib-src/Makefile.in | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index 5a783d32660..22722046436 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,8 @@ +2014-04-29 Glenn Morris + + * Makefile.in ($(DESTDIR)${archlibdir}): + Avoid non-portable "`\" nesting. (Bug#17339) + 2014-04-16 Eli Zaretskii * update-game-score.c (write_scores): Condition fchmod call on diff --git a/lib-src/Makefile.in b/lib-src/Makefile.in index 56cdc09e0fe..4d9fdba7726 100644 --- a/lib-src/Makefile.in +++ b/lib-src/Makefile.in @@ -247,8 +247,8 @@ $(DESTDIR)${archlibdir}: all chown ${gameuser} "$(DESTDIR)${gamedir}"; \ chmod u=rwx,g=rwx,o=rx "$(DESTDIR)${gamedir}"; \ fi - if [ "`cd \"$(DESTDIR)${archlibdir}\" && /bin/pwd`" \ - != "`cd ${srcdir} && /bin/pwd`" ]; then \ + exp_archlibdir=`cd "$(DESTDIR)${archlibdir}" && /bin/pwd`; \ + if [ "$$exp_archlibdir" != "`cd ${srcdir} && /bin/pwd`" ]; then \ for file in ${SCRIPTS}; do \ $(INSTALL_SCRIPT) ${srcdir}/$$file "$(DESTDIR)${archlibdir}/$$file"; \ done ; \ From 4a25c1cb1e1be8fa3ceea455b7f442cfb507eb39 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 29 Apr 2014 08:12:36 -0700 Subject: [PATCH 12/19] * src/process.c (handle_child_signal): Handle systems without WCONTINUED Fixes: debbugs:15110 --- src/ChangeLog | 8 ++++++-- src/process.c | 6 +++++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 0c8fa7b31d7..af9270fb7a4 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,8 +1,12 @@ +2014-04-29 Glenn Morris + + * process.c (handle_child_signal): + Handle systems without WCONTINUED. (Bug#15110, 17339) + 2014-04-23 Eli Zaretskii * search.c (Fnewline_cache_check): Don't try to count newlines - outside the buffer's restriction, as find_newline doesn't support - that. + outside the buffer's restriction, as find_newline doesn't support that. 2014-04-22 Paul Eggert diff --git a/src/process.c b/src/process.c index 2c66b9e976e..07b690e6ebd 100644 --- a/src/process.c +++ b/src/process.c @@ -6225,7 +6225,11 @@ handle_child_signal (int sig) int status; if (p->alive - && child_status_changed (p->pid, &status, WUNTRACED | WCONTINUED)) +#ifndef WCONTINUED + && child_status_changed (p->pid, &status, WUNTRACED)) +#else + && child_status_changed (p->pid, &status, WUNTRACED | WCONTINUED)) +#endif { /* Change the status of the process that was found. */ p->tick = ++process_tick; From 119bf2f4b11567f918c0ae3a052f63328b9dd36a Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Tue, 29 Apr 2014 18:17:02 +0300 Subject: [PATCH 13/19] Few more doc fixes for bug #17362. --- doc/emacs/ChangeLog | 2 ++ doc/emacs/anti.texi | 6 +++--- doc/emacs/basic.texi | 20 ++++++++++---------- doc/emacs/buffers.texi | 12 ++++++------ doc/emacs/commands.texi | 4 ++-- doc/emacs/custom.texi | 8 ++++---- doc/emacs/indent.texi | 4 ++-- doc/emacs/mark.texi | 2 +- doc/emacs/mini.texi | 12 ++++++------ doc/emacs/misc.texi | 6 +++--- doc/emacs/picture-xtra.texi | 8 ++++---- 11 files changed, 43 insertions(+), 41 deletions(-) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index 65847ebac8e..4aeac464208 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -71,6 +71,8 @@ * basic.texi (Inserting Text, Erasing, Arguments): Fix usage of @kbd and @key. + * anti.texi (Antinews): Fix usage of @kbd and @key. + 2014-04-26 Eli Zaretskii * sending.texi (Mail Signature): Document signature variables used diff --git a/doc/emacs/anti.texi b/doc/emacs/anti.texi index dcab8b57aef..d0de90690a7 100644 --- a/doc/emacs/anti.texi +++ b/doc/emacs/anti.texi @@ -17,8 +17,8 @@ Support for displaying and editing ``bidirectional'' text has been removed. Text is now always displayed on the screen in a single consistent direction---left to right---regardless of the underlying script. Similarly, @kbd{C-f} and @kbd{C-b} always move the text -cursor to the right and left respectively. Also, @key{right} and -@key{left} are now equivalent to @kbd{C-f} and @kbd{C-b}, as you might +cursor to the right and left respectively. Also, @key{RIGHT} and +@key{LEFT} are now equivalent to @kbd{C-f} and @kbd{C-b}, as you might expect, rather than moving forward or backward based on the underlying ``paragraph direction''. @@ -36,7 +36,7 @@ and/or README file for details. @item The option @code{delete-active-region} has been deleted. When the -region is active, typing @key{DEL} or @key{delete} no longer deletes +region is active, typing @key{DEL} or @key{Delete} no longer deletes the text in the region; it deletes a single character instead. @item diff --git a/doc/emacs/basic.texi b/doc/emacs/basic.texi index 3e8129c9d50..bec7774f2a9 100644 --- a/doc/emacs/basic.texi +++ b/doc/emacs/basic.texi @@ -139,8 +139,8 @@ how many copies of the character to insert (@pxref{Arguments}). point (@pxref{Point}). The keyboard commands @kbd{C-f}, @kbd{C-b}, @kbd{C-n}, and @kbd{C-p} move point to the right, left, down, and up, respectively. You can also move point using the @dfn{arrow keys} -present on most keyboards: @kbd{@key{right}}, @kbd{@key{left}}, -@kbd{@key{down}}, and @kbd{@key{up}}; however, many Emacs users find +present on most keyboards: @key{RIGHT}, @key{LEFT}, +@key{DOWN}, and @key{UP}; however, many Emacs users find that it is slower to use the arrow keys than the control keys, because you need to move your hand to the area of the keyboard where those keys are located. @@ -156,7 +156,7 @@ keyboard commands that move point in more sophisticated ways. @findex forward-char Move forward one character (@code{forward-char}). -@item @key{right} +@item @key{RIGHT} @kindex RIGHT @findex right-char @vindex visual-order-cursor-movement @@ -176,7 +176,7 @@ away, depending on the surrounding bidirectional context. @findex backward-char Move backward one character (@code{backward-char}). -@item @key{left} +@item @key{LEFT} @kindex LEFT @findex left-char This command (@code{left-char}) behaves like @kbd{C-b}, except it @@ -187,7 +187,7 @@ left of the current screen position, moving to the previous or next screen line as appropriate. @item C-n -@itemx @key{down} +@itemx @key{DOWN} @kindex C-n @kindex DOWN @findex next-line @@ -196,7 +196,7 @@ to keep the horizontal position unchanged, so if you start in the middle of one line, you move to the middle of the next. @item C-p -@itemx @key{up} +@itemx @key{UP} @kindex C-p @kindex UP @findex previous-line @@ -222,8 +222,8 @@ Move to the end of the line (@code{move-end-of-line}). @findex forward-word Move forward one word (@code{forward-word}). -@item C-@key{right} -@itemx M-@key{right} +@item C-@key{RIGHT} +@itemx M-@key{RIGHT} @kindex C-RIGHT @kindex M-RIGHT @findex right-word @@ -236,8 +236,8 @@ right-to-left. @xref{Bidirectional Editing}. @findex backward-word Move backward one word (@code{backward-word}). -@item C-@key{left} -@itemx M-@key{left} +@item C-@key{LEFT} +@itemx M-@key{LEFT} @kindex C-LEFT @kindex M-LEFT @findex left-word diff --git a/doc/emacs/buffers.texi b/doc/emacs/buffers.texi index 3c2beae28ef..89b56da7723 100644 --- a/doc/emacs/buffers.texi +++ b/doc/emacs/buffers.texi @@ -74,9 +74,9 @@ Similar, but select @var{buffer} in another window @item C-x 5 b @var{buffer} @key{RET} Similar, but select @var{buffer} in a separate frame (@code{switch-to-buffer-other-frame}). -@item C-x @key{left} +@item C-x @key{LEFT} Select the previous buffer in the buffer list (@code{previous-buffer}). -@item C-x @key{right} +@item C-x @key{RIGHT} Select the next buffer in the buffer list (@code{next-buffer}). @item C-u M-g M-g @itemx C-u M-g g @@ -110,15 +110,15 @@ it, Emacs asks for the file name to use, and the buffer's major mode is re-established taking that file name into account (@pxref{Choosing Modes}). -@kindex C-x @key{left} -@kindex C-x @key{right} +@kindex C-x @key{LEFT} +@kindex C-x @key{RIGHT} @findex next-buffer @findex previous-buffer For conveniently switching between a few buffers, use the commands -@kbd{C-x @key{left}} and @kbd{C-x @key{right}}. @kbd{C-x @key{left}} +@kbd{C-x @key{LEFT}} and @kbd{C-x @key{RIGHT}}. @kbd{C-x @key{LEFT}} (@code{previous-buffer}) selects the previous buffer (following the order of most recent selection in the current frame), while @kbd{C-x -@key{right}} (@code{next-buffer}) moves through buffers in the reverse +@key{RIGHT}} (@code{next-buffer}) moves through buffers in the reverse direction. @kindex C-x 4 b diff --git a/doc/emacs/commands.texi b/doc/emacs/commands.texi index 10612de82bb..d9eba2d5a00 100644 --- a/doc/emacs/commands.texi +++ b/doc/emacs/commands.texi @@ -35,7 +35,7 @@ Therefore, this manual mainly documents how to edit with the keyboard. @samp{3}, @samp{=}, and the space character (denoted as @key{SPC}), are entered by typing the corresponding key. @dfn{Control characters}, such as @key{RET}, @key{TAB}, @key{DEL}, @key{ESC}, -@key{F1}, @key{Home}, and @key{left}, are also entered this way, as +@key{F1}, @key{Home}, and @key{LEFT}, are also entered this way, as are certain characters found on non-English keyboards (@pxref{International}). @@ -53,7 +53,7 @@ holding down the @key{Ctrl} key while pressing @kbd{a}; we will refer to this as @kbd{C-a} for short. Similarly @kbd{@key{META}-a}, or @kbd{M-a} for short, is entered by holding down the @key{Alt} key and pressing @kbd{a}. Modifier keys can also be applied to non-alphanumerical -characters, e.g., @kbd{C-@key{F1}} or @kbd{M-@key{left}}. +characters, e.g., @kbd{C-@key{F1}} or @kbd{M-@key{LEFT}}. @cindex @key{ESC} replacing @key{META} key You can also type Meta characters using two-character sequences diff --git a/doc/emacs/custom.texi b/doc/emacs/custom.texi index 96f2ef2107c..9b78128d323 100644 --- a/doc/emacs/custom.texi +++ b/doc/emacs/custom.texi @@ -1795,10 +1795,10 @@ the corresponding Lisp symbol. Here are the conventional Lisp names for common function keys: @table @asis -@item @code{left}, @code{up}, @code{right}, @code{down} +@item @code{LEFT}, @code{UP}, @code{RIGHT}, @code{DOWN} Cursor arrow keys. -@item @code{begin}, @code{end}, @code{home}, @code{next}, @code{prior} +@item @code{Begin}, @code{End}, @code{Home}, @code{next}, @code{prior} Other cursor repositioning keys. @item @code{select}, @code{print}, @code{execute}, @code{backtab} @@ -1836,8 +1836,8 @@ translates these keys to the corresponding keys in the main keyboard. For example, when @samp{Num Lock} is on, the key labeled @samp{8} on the numeric keypad produces @code{kp-8}, which is translated to @kbd{8}; when @samp{Num Lock} is off, the same key produces -@code{kp-up}, which is translated to @key{up}. If you rebind a key -such as @kbd{8} or @key{up}, it affects the equivalent keypad key too. +@code{kp-up}, which is translated to @key{UP}. If you rebind a key +such as @kbd{8} or @key{UP}, it affects the equivalent keypad key too. However, if you rebind a @samp{kp-} key directly, that won't affect its non-keypad equivalent. Note that the modified keys are not translated: for instance, if you hold down the @key{META} key while diff --git a/doc/emacs/indent.texi b/doc/emacs/indent.texi index 8340d1031ba..b254cfca43e 100644 --- a/doc/emacs/indent.texi +++ b/doc/emacs/indent.texi @@ -127,9 +127,9 @@ in the region, moving the affected lines as a ``rigid'' unit. If called with no argument, the command activates a transient mode for adjusting the indentation of the affected lines interactively. While -this transient mode is active, typing @key{left} or @key{right} +this transient mode is active, typing @key{LEFT} or @key{RIGHT} indents leftward and rightward, respectively, by one space. You can -also type @kbd{S-@key{left}} or @kbd{S-@key{right}} to indent leftward +also type @kbd{S-@key{LEFT}} or @kbd{S-@key{RIGHT}} to indent leftward or rightward to the next tab stop (@pxref{Tab Stops}). Typing any other key disables the transient mode, and resumes normal editing. diff --git a/doc/emacs/mark.texi b/doc/emacs/mark.texi index 2f7ea3b4e9b..e3cda04ce51 100644 --- a/doc/emacs/mark.texi +++ b/doc/emacs/mark.texi @@ -133,7 +133,7 @@ detailed description of these mouse commands. @cindex shift-selection Finally, you can set the mark by holding down the shift key while -typing certain cursor motion commands (such as @kbd{S-@key{right}}, +typing certain cursor motion commands (such as @kbd{S-@key{RIGHT}}, @kbd{S-C-f}, @kbd{S-C-n}, etc.). This is called @dfn{shift-selection}. It sets the mark at point before moving point, but only if there is no active mark set via shift-selection. The mark set by mouse commands diff --git a/doc/emacs/mini.texi b/doc/emacs/mini.texi index 8951c7dd5ee..a87aff0e135 100644 --- a/doc/emacs/mini.texi +++ b/doc/emacs/mini.texi @@ -357,12 +357,12 @@ While in the completion list buffer, this chooses the completion at point (@code{choose-completion}). @findex next-completion -@item @key{right} +@item @key{RIGHT} While in the completion list buffer, this moves point to the following completion alternative (@code{next-completion}). @findex previous-completion -@item @key{left} +@item @key{LEFT} While in the completion list buffer, this moves point to the previous completion alternative (@code{previous-completion}). @end table @@ -587,11 +587,11 @@ argument into the minibuffer: @table @kbd @item M-p -@itemx @key{up} +@itemx @key{UP} Move to the previous item in the minibuffer history, an earlier argument (@code{previous-history-element}). @item M-n -@itemx @key{down} +@itemx @key{DOWN} Move to the next item in the minibuffer history (@code{next-history-element}). @item M-r @var{regexp} @key{RET} @@ -608,11 +608,11 @@ Move to a later item in the minibuffer history that matches @kindex DOWN @r{(minibuffer history)} @findex next-history-element @findex previous-history-element - While in the minibuffer, @kbd{M-p} or @key{up} + While in the minibuffer, @kbd{M-p} or @key{UP} (@code{previous-history-element}) moves through the minibuffer history list, one item at a time. Each @kbd{M-p} fetches an earlier item from the history list into the minibuffer, replacing its existing contents. -Typing @kbd{M-n} or @key{down} (@code{next-history-element}) moves +Typing @kbd{M-n} or @key{DOWN} (@code{next-history-element}) moves through the minibuffer history list in the opposite direction, fetching later entries into the minibuffer. diff --git a/doc/emacs/misc.texi b/doc/emacs/misc.texi index ce6f80618bd..a2813f8b197 100644 --- a/doc/emacs/misc.texi +++ b/doc/emacs/misc.texi @@ -932,13 +932,13 @@ resubmit them or copy them to the end. Or you can use a @findex comint-previous-input @kindex M-p @r{(Shell mode)} @item M-p -@itemx C-@key{up} +@itemx C-@key{UP} Fetch the next earlier old shell command. @kindex M-n @r{(Shell mode)} @findex comint-next-input @item M-n -@itemx C-@key{down} +@itemx C-@key{DOWN} Fetch the next later old shell command. @kindex M-r @r{(Shell mode)} @@ -975,7 +975,7 @@ buffer. Successive use of @kbd{M-p} fetches successively earlier shell commands, each replacing any text that was already present as potential shell input. @kbd{M-n} does likewise except that it finds successively more recent shell commands from the buffer. -@kbd{C-@key{up}} works like @kbd{M-p}, and @kbd{C-@key{down}} like +@kbd{C-@key{UP}} works like @kbd{M-p}, and @kbd{C-@key{DOWN}} like @kbd{M-n}. The history search command @kbd{M-r} begins an incremental regular diff --git a/doc/emacs/picture-xtra.texi b/doc/emacs/picture-xtra.texi index 724f1bc3a0c..6f29e92732c 100644 --- a/doc/emacs/picture-xtra.texi +++ b/doc/emacs/picture-xtra.texi @@ -151,16 +151,16 @@ character. This is useful for drawing lines in the buffer. @table @kbd @item C-c < -@itemx C-c @key{left} +@itemx C-c @key{LEFT} Move left after insertion (@code{picture-movement-left}). @item C-c > -@itemx C-c @key{right} +@itemx C-c @key{RIGHT} Move right after insertion (@code{picture-movement-right}). @item C-c ^ -@itemx C-c @key{up} +@itemx C-c @key{UP} Move up after insertion (@code{picture-movement-up}). @item C-c . -@itemx C-c @key{down} +@itemx C-c @key{DOWN} Move down after insertion (@code{picture-movement-down}). @item C-c ` @itemx C-c @key{Home} From a55ea27f60f94ff3fc3e02e253056137fc56c35b Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Tue, 29 Apr 2014 18:33:37 +0300 Subject: [PATCH 14/19] Place hardware TTY cursor at the active menu item when displaying a menu. src/term.c (tty_menu_display): Move the cursor to the active menu item. (tty_menu_activate): Return the cursor to the active menu item after displaying the menu and after displaying help-echo. See http://lists.gnu.org/archive/html/emacs-devel/2014-04/msg00402.html for the details of why this is needed by screen readers and Braille displays. --- src/ChangeLog | 10 ++++++++++ src/term.c | 17 +++++++++++++++++ 2 files changed, 27 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index af9270fb7a4..c98b8546788 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,13 @@ +2014-04-29 Eli Zaretskii + + * term.c (tty_menu_display): Move the cursor to the active menu + item. + (tty_menu_activate): Return the cursor to the active menu item + after displaying the menu and after displaying help-echo. See + http://lists.gnu.org/archive/html/emacs-devel/2014-04/msg00402.html + for the details of why this is needed by screen readers and + Braille displays. + 2014-04-29 Glenn Morris * process.c (handle_child_signal): diff --git a/src/term.c b/src/term.c index 9e6cfe2f41d..354354fa745 100644 --- a/src/term.c +++ b/src/term.c @@ -2897,6 +2897,13 @@ tty_menu_display (tty_menu *menu, int x, int y, int pn, int *faces, menu_help_paneno = pn - 1; menu_help_itemno = j; } + /* Take note of the coordinates of the active menu item, to + display the cursor there. */ + if (mousehere) + { + row = y + i; + col = x; + } display_tty_menu_item (menu->text[j], max_width, face, x, y + i, menu->submenu[j] != NULL); } @@ -3177,6 +3184,7 @@ tty_menu_activate (tty_menu *menu, int *pane, int *selidx, bool first_time; Lisp_Object selectface; int first_item = 0; + int col, row; /* Don't allow non-positive x0 and y0, lest the menu will wrap around the display. */ @@ -3364,6 +3372,11 @@ tty_menu_activate (tty_menu *menu, int *pane, int *selidx, faces, x, y, first_item, 1); tty_hide_cursor (tty); fflush (tty->output); + /* The call to display help-echo below will move the cursor, + so remember its current position as computed by + tty_menu_display. */ + col = cursorX (tty); + row = cursorY (tty); } /* Display the help-echo message for the currently-selected menu @@ -3373,6 +3386,10 @@ tty_menu_activate (tty_menu *menu, int *pane, int *selidx, { help_callback (menu_help_message, menu_help_paneno, menu_help_itemno); + /* Move the cursor to the beginning of the current menu + item, so that screen readers and other accessibility aids + know where the active region is. */ + cursor_to (sf, row, col); tty_hide_cursor (tty); fflush (tty->output); prev_menu_help_message = menu_help_message; From 9a3f71f795f0a39f28c0d0e9693537acb7cf8604 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 29 Apr 2014 11:51:49 -0400 Subject: [PATCH 15/19] * lisp/mail/rmail.el (rmail-quit): Handle killed summaries. Fixes: debbugs:17283 --- lisp/ChangeLog | 4 ++++ lisp/mail/rmail.el | 5 ++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index bb23d634ac1..f7e1fd4cea8 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2014-04-29 Glenn Morris + + * mail/rmail.el (rmail-quit): Handle killed summaries. (Bug#17283) + 2014-04-27 Matthias Dahl * faces.el (face-spec-recalc): Apply X resources only after the diff --git a/lisp/mail/rmail.el b/lisp/mail/rmail.el index 1a016199757..486c06053b3 100644 --- a/lisp/mail/rmail.el +++ b/lisp/mail/rmail.el @@ -1,7 +1,6 @@ ;;; rmail.el --- main code of "RMAIL" mail reader for Emacs -;; Copyright (C) 1985-1988, 1993-1998, 2000-2014 Free Software -;; Foundation, Inc. +;; Copyright (C) 1985-1988, 1993-1998, 2000-2014 Free Software Foundation, Inc. ;; Maintainer: emacs-devel@gnu.org ;; Keywords: mail @@ -1573,7 +1572,7 @@ Hook `rmail-quit-hook' is run after expunging." (when (boundp 'rmail-quit-hook) (run-hooks 'rmail-quit-hook)) ;; Don't switch to the summary buffer even if it was recently visible. - (when rmail-summary-buffer + (when (rmail-summary-exists) (with-current-buffer rmail-summary-buffer (set-buffer-modified-p nil)) (replace-buffer-in-windows rmail-summary-buffer) From f828c69dba3665e88493d103c92184d52bb6fa50 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Tue, 29 Apr 2014 22:23:05 +0300 Subject: [PATCH 16/19] One more doc fix for bug #17362. --- doc/emacs/glossary.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/emacs/glossary.texi b/doc/emacs/glossary.texi index 7d2194918fa..9da83bb1f74 100644 --- a/doc/emacs/glossary.texi +++ b/doc/emacs/glossary.texi @@ -357,7 +357,7 @@ A defun is a major definition at the top level in a program. The name @item @key{DEL} @key{DEL} is a character that runs the command to delete one character of text before the cursor. It is typically either the @key{Delete} -key or the @key{Backspace} key, whichever one is easy to type. +key or the @key{BACKSPACE} key, whichever one is easy to type. @xref{Erasing,DEL}. @item Deletion From 72962dd88224fe01ea392482017bbf179a621a8e Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Wed, 30 Apr 2014 19:59:03 +0300 Subject: [PATCH 17/19] Minor fixes for dired.el doc strings. lisp/dired.el (dired-initial-position-hook, dired-initial-position): Doc string fixes. --- lisp/ChangeLog | 5 +++++ lisp/dired.el | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index f7e1fd4cea8..769d06028b4 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2014-04-30 Eli Zaretskii + + * dired.el (dired-initial-position-hook, dired-initial-position): + Doc string fixes. + 2014-04-29 Glenn Morris * mail/rmail.el (rmail-quit): Handle killed summaries. (Bug#17283) diff --git a/lisp/dired.el b/lisp/dired.el index 1cce5bc6665..3b986e99f60 100644 --- a/lisp/dired.el +++ b/lisp/dired.el @@ -222,7 +222,7 @@ with the buffer narrowed to the listing." (defcustom dired-initial-position-hook nil "This hook is used to position the point. -It is run the function `dired-initial-position'." +It is run by the function `dired-initial-position'." :group 'dired :type 'hook :version "24.4") @@ -2768,7 +2768,7 @@ as returned by `dired-get-filename'. LIMIT is the search limit." ;; FIXME document whatever dired-x is doing. (defun dired-initial-position (dirname) "Where point should go in a new listing of DIRNAME. -Point assumed at beginning of new subdir line. +Point is assumed to be at the beginning of new subdir line. It runs the hook `dired-initial-position-hook'." (end-of-line) (and (featurep 'dired-x) dired-find-subdir From bc6cb3efd06266e5f51862449700e2e559277095 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Wed, 30 Apr 2014 10:54:27 -0700 Subject: [PATCH 18/19] * term.c (tty_menu_activate): Don't assume row and col are initialized. GCC 4.9.0 warned about this, and I couldn't easily prove to my own satisfaction that they would always be initialized. --- src/ChangeLog | 6 ++++++ src/term.c | 5 ++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index c98b8546788..ab87645b48b 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,9 @@ +2014-04-30 Paul Eggert + + * term.c (tty_menu_activate): Don't assume row and col are initialized. + GCC 4.9.0 warned about this, and I couldn't easily prove to my own + satisfaction that they would always be initialized. + 2014-04-29 Eli Zaretskii * term.c (tty_menu_display): Move the cursor to the active menu diff --git a/src/term.c b/src/term.c index 354354fa745..3bbb21f1589 100644 --- a/src/term.c +++ b/src/term.c @@ -3378,6 +3378,8 @@ tty_menu_activate (tty_menu *menu, int *pane, int *selidx, col = cursorX (tty); row = cursorY (tty); } + else + row = -1; /* Display the help-echo message for the currently-selected menu item. */ @@ -3389,7 +3391,8 @@ tty_menu_activate (tty_menu *menu, int *pane, int *selidx, /* Move the cursor to the beginning of the current menu item, so that screen readers and other accessibility aids know where the active region is. */ - cursor_to (sf, row, col); + if (0 <= row) + cursor_to (sf, row, col); tty_hide_cursor (tty); fflush (tty->output); prev_menu_help_message = menu_help_message; From 426b5dafdd837328d624a8ec5bfd567f2865c9f5 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Wed, 30 Apr 2014 11:01:36 -0700 Subject: [PATCH 19/19] Spelling fix, plus try to fix grammar in doc string. --- lisp/faces.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/faces.el b/lisp/faces.el index df31e0dfbd8..7caba9a96c2 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -1644,11 +1644,11 @@ function for its other effects." The following sources are applied in this order: face reset to default values if it's the default face, otherwise set - to unspecifed (through `face-spec-reset-face`) + to unspecified (through `face-spec-reset-face') | (theme and user customization) - or: if none of the above exist, do not match the current frame or - did inherit from the defface spec instead of overwriting it + or: if none of the above exist, and none match the current frame or + inherited from the defface spec instead of overwriting it entirely, the following is applied instead: (defface default spec) (X resources (if applicable))