From 0be0ce47418235badfb0ae9866da8523058310db Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Wed, 13 Jul 2011 00:09:28 -0400 Subject: [PATCH 01/38] src/buffer.c (mmap_find): Fix a typo. --- src/ChangeLog | 4 ++++ src/buffer.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 5bdc940a6f3..2721704223c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2011-07-13 Eli Zaretskii + + * buffer.c (mmap_find): Fix a typo. + 2011-07-13 Johan Bockgård Fix execution of x selection hooks. diff --git a/src/buffer.c b/src/buffer.c index 776888e30ac..81c537b9c6a 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -4500,7 +4500,7 @@ mmap_init (void) is at END - 1. */ static struct mmap_region * -mmap_find (POINTER_TYPE *start, POINTER_TYPE *end); +mmap_find (POINTER_TYPE *start, POINTER_TYPE *end) { struct mmap_region *r; char *s = (char *) start, *e = (char *) end; From a1c9f41b785b5978ffa9c9b65c92b3bbc3350a2b Mon Sep 17 00:00:00 2001 From: Sergei Organov Date: Wed, 13 Jul 2011 00:58:34 -0700 Subject: [PATCH 02/38] * lisp/vc/vc.el (vc-revert-file): Don't set file time-stamp in the past. Fixes: debbugs:5181 --- lisp/ChangeLog | 5 +++++ lisp/vc/vc.el | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 19c80a65888..e2371c6f7c8 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Sergei Organov (tiny change) + + * vc/vc.el (vc-revert-file): + Don't set file time-stamp in the past. (Bug#5181) + 2011-07-12 Lars Magne Ingebrigtsen * files.el (after-find-file): Give a better error message when diff --git a/lisp/vc/vc.el b/lisp/vc/vc.el index 796311f8f66..6704a43e59b 100644 --- a/lisp/vc/vc.el +++ b/lisp/vc/vc.el @@ -2428,7 +2428,7 @@ its name; otherwise return nil." (list file) (let ((backup-file (vc-version-backup-file file))) (when backup-file - (copy-file backup-file file 'ok-if-already-exists 'keep-date) + (copy-file backup-file file 'ok-if-already-exists) (vc-delete-automatic-version-backups file)) (vc-call revert file backup-file)) `((vc-state . up-to-date) From 2ad77c9dd4d29f1df663b27eb41f9257bfb59bfb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Dj=C3=A4rv?= Date: Wed, 13 Jul 2011 12:36:12 +0200 Subject: [PATCH 03/38] * configure.in (GSETTINGS): Check for gio-2.0 >= 2.26. --- ChangeLog | 4 ++++ configure.in | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index bf4e63d985a..f9cadda71aa 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2011-07-13 Jan Djärv + + * configure.in (GSETTINGS): Check for gio-2.0 >= 2.26. + 2011-07-11 YAMAMOTO Mitsuharu * configure.in (LD_SWITCH_SYSTEM_TEMACS): Add -fno-pie on Darwin diff --git a/configure.in b/configure.in index 40a34286f00..f88506fbb2e 100644 --- a/configure.in +++ b/configure.in @@ -1987,7 +1987,7 @@ AC_SUBST(DBUS_OBJ) dnl GSettings has been tested under GNU/Linux only. HAVE_GSETTINGS=no if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then - PKG_CHECK_MODULES(GSETTINGS, glib-2.0 >= 2.26, HAVE_GSETTINGS=yes, HAVE_GSETTINGS=no) + PKG_CHECK_MODULES(GSETTINGS, gio-2.0 >= 2.26, HAVE_GSETTINGS=yes, HAVE_GSETTINGS=no) if test "$HAVE_GSETTINGS" = "yes"; then AC_DEFINE(HAVE_GSETTINGS, 1, [Define to 1 if using GSettings.]) SETTINGS_CFLAGS="$GSETTINGS_CFLAGS" From 1c4dd947d6d684b2d3c3dc298f2ee09e8fc0308b Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 15:10:54 +0200 Subject: [PATCH 04/38] (Info-find-file): Fall back on the installation directory if we can't find the info node anywhere else. --- lisp/ChangeLog | 5 +++++ lisp/info.el | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e2371c6f7c8..d2bfdb90a40 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * info.el (Info-find-file): Fall back on the installation + directory if we can't find the info node anywhere else. + 2011-07-13 Sergei Organov (tiny change) * vc/vc.el (vc-revert-file): diff --git a/lisp/info.el b/lisp/info.el index 29daac566d1..9e67542cda5 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -728,6 +728,11 @@ just return nil (no error)." (append Info-directory-list Info-additional-directory-list) Info-directory-list))))) + ;; Fall back on the installation directory if we can't find + ;; the info node anywhere else. + (when installation-directory + (setq dirs (append dirs (list (expand-file-name + "info" installation-directory))))) ;; Search the directory list for file FILENAME. (while (and dirs (not found)) (setq temp (expand-file-name filename (car dirs))) From 9c9c2d8874e433ba37a9b81934a44acc95f7cc0f Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 15:25:29 +0200 Subject: [PATCH 05/38] * jka-compr.el (jka-compr-verbose): New variable, and use throughout. Fixes: debbugs:8971 --- lisp/ChangeLog | 3 +++ lisp/jka-compr.el | 11 +++++++++++ 2 files changed, 14 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d2bfdb90a40..9518dad5ad6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * jka-compr.el (jka-compr-verbose): New variable, and use + throughout (bug#8971). + * info.el (Info-find-file): Fall back on the installation directory if we can't find the info node anywhere else. diff --git a/lisp/jka-compr.el b/lisp/jka-compr.el index 37c9d40ec65..1893e982bbb 100644 --- a/lisp/jka-compr.el +++ b/lisp/jka-compr.el @@ -97,6 +97,11 @@ NOTE: Not used in MS-DOS and Windows systems." :type 'string :group 'jka-compr) +(defcustom jka-compr-verbose t + "If non-nil, output messages whenever compressing or uncompressing files." + :type 'boolean + :group 'jka-compr) + (defvar jka-compr-use-shell (not (memq system-type '(ms-dos windows-nt)))) @@ -309,6 +314,7 @@ There should be no more than seven characters after the final `/'." (and compress-message + jka-compr-verbose (message "%s %s..." compress-message base-name)) (jka-compr-run-real-handler 'write-region @@ -341,6 +347,7 @@ There should be no more than seven characters after the final `/'." (and compress-message + jka-compr-verbose (message "%s %s...done" compress-message base-name)) (cond @@ -404,6 +411,7 @@ There should be no more than seven characters after the final `/'." (and uncompress-message + jka-compr-verbose (message "%s %s..." uncompress-message base-name)) (condition-case error-code @@ -479,6 +487,7 @@ There should be no more than seven characters after the final `/'." (and uncompress-message + jka-compr-verbose (message "%s %s...done" uncompress-message base-name)) (and @@ -534,6 +543,7 @@ There should be no more than seven characters after the final `/'." (and uncompress-message + jka-compr-verbose (message "%s %s..." uncompress-message base-name)) ;; Here we must read the output of uncompress program @@ -554,6 +564,7 @@ There should be no more than seven characters after the final `/'." (and uncompress-message + jka-compr-verbose (message "%s %s...done" uncompress-message base-name)) (write-region From a2014063066a4b6feb66eba883fae94e26e01087 Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 15:35:02 +0200 Subject: [PATCH 06/38] (info-insert-file-contents): Inhibit jka-compr messages, which can be pretty annoying Fixes: debbugs:8971 --- lisp/ChangeLog | 3 +++ lisp/info.el | 1 + 2 files changed, 4 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9518dad5ad6..96c382c78fc 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * info.el (info-insert-file-contents): Inhibit jka-compr messages, + which can be pretty annoying (bug#8971). + * jka-compr.el (jka-compr-verbose): New variable, and use throughout (bug#8971). diff --git a/lisp/info.el b/lisp/info.el index 9e67542cda5..cbdc8cc7ab3 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -464,6 +464,7 @@ be last in the list.") "Insert the contents of an Info file in the current buffer. Do the right thing if the file has been compressed or zipped." (let* ((tail Info-suffix-list) + (jka-compr-verbose nil) (lfn (if (fboundp 'msdos-long-file-names) (msdos-long-file-names) t)) From b6c78ef21f1ecaaa34439ee5c731cfb3dbda1e40 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 13 Jul 2011 15:39:23 +0200 Subject: [PATCH 07/38] (completion-ignored-extensions): Add OpenMCL/Clozure binary endings. Fixes: debbugs:4440 --- lisp/ChangeLog | 5 +++++ lisp/bindings.el | 9 ++++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 96c382c78fc..fdc84cf51ac 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Juanma Barranquero + + * bindings.el (completion-ignored-extensions): Add OpenMCL/Clozure + binary endings (bug#4440). + 2011-07-13 Lars Magne Ingebrigtsen * info.el (info-insert-file-contents): Inhibit jka-compr messages, diff --git a/lisp/bindings.el b/lisp/bindings.el index 99d9aa36e35..57601637ed6 100644 --- a/lisp/bindings.el +++ b/lisp/bindings.el @@ -594,9 +594,12 @@ is okay. See `mode-line-format'.") ".fas" ".lib" ".mem" ;; CMUCL ".x86f" ".sparcf" - ;; Other CL implementations (Allegro, LispWorks, OpenMCL) - ".fasl" ".ufsl" ".fsl" ".dxl" ".pfsl" ".dfsl" - ".p64fsl" ".d64fsl" ".dx64fsl" + ;; OpenMCL / Clozure CL + ".dfsl" ".pfsl" ".d64fsl" ".p64fsl" ".lx64fsl" ".lx32fsl" + ".dx64fsl" ".dx32fsl" ".fx64fsl" ".fx32fsl" ".sx64fsl" + ".sx32fsl" ".wx64fsl" ".wx32fsl" + ;; Other CL implementations (Allegro, LispWorks) + ".fasl" ".ufsl" ".fsl" ".dxl" ;; Libtool ".lo" ".la" ;; Gettext From 2a517d45db7725ad690cb2cbc8ad134057935c22 Mon Sep 17 00:00:00 2001 From: Lawrence Mitchell Date: Wed, 13 Jul 2011 15:49:55 +0200 Subject: [PATCH 08/38] Make the default browser choice a bit more logical * net/browse-url.el (browse-url-default-browser) (browse-url-browser-function): Make the default browser choice a bit more logical. Also clean up the doc string. Fixes: debbugs:4300 --- lisp/ChangeLog | 6 ++++++ lisp/net/browse-url.el | 17 ++++++----------- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fdc84cf51ac..3baec994c6e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2011-07-13 Lawrence Mitchell + + * net/browse-url.el (browse-url-default-browser) + (browse-url-browser-function): Make the default browser choice a + bit more logical (bug#4300). Also clean up the doc string. + 2011-07-13 Juanma Barranquero * bindings.el (completion-ignored-extensions): Add OpenMCL/Clozure diff --git a/lisp/net/browse-url.el b/lisp/net/browse-url.el index ac12030471e..e18b42a275f 100644 --- a/lisp/net/browse-url.el +++ b/lisp/net/browse-url.el @@ -214,13 +214,7 @@ ;;;###autoload (defcustom browse-url-browser-function - (cond - ((memq system-type '(windows-nt ms-dos cygwin)) - 'browse-url-default-windows-browser) - ((memq system-type '(darwin)) - 'browse-url-default-macosx-browser) - (t - 'browse-url-default-browser)) + 'browse-url-default-browser "Function to display the current buffer in a WWW browser. This is used by the `browse-url-at-point', `browse-url-at-mouse', and `browse-url-of-file' commands. @@ -908,12 +902,13 @@ a random existing one. A non-nil interactive prefix argument reverses the effect of `browse-url-new-window-flag'. When called non-interactively, optional second argument NEW-WINDOW is -used instead of `browse-url-new-window-flag'. - -The order attempted is gnome-moz-remote, Mozilla, Firefox, -Galeon, Konqueror, Netscape, Mosaic, Lynx in an xterm, and then W3." +used instead of `browse-url-new-window-flag'." (apply (cond + ((memq system-type '(windows-nt ms-dos cygwin)) + 'browse-url-default-windows-browser) + ((memq system-type '(darwin)) + 'browse-url-default-macosx-browser) ((browse-url-can-use-xdg-open) 'browse-url-xdg-open) ((executable-find browse-url-gnome-moz-program) 'browse-url-gnome-moz) ((executable-find browse-url-mozilla-program) 'browse-url-mozilla) From b0c9af93ab50209acfeaa447495bf0d40a4fddc5 Mon Sep 17 00:00:00 2001 From: Chris Newton Date: Wed, 13 Jul 2011 16:12:06 +0200 Subject: [PATCH 09/38] Copy over `url-show-status' to the async buffer * url-http.el (url-http): Copy over `url-show-status' to the async buffer so that `url-display-percentage' does the right thing (bug#4680). --- lisp/url/ChangeLog | 6 ++++++ lisp/url/url-http.el | 2 ++ 2 files changed, 8 insertions(+) diff --git a/lisp/url/ChangeLog b/lisp/url/ChangeLog index 80b970ac02f..6a3638c4232 100644 --- a/lisp/url/ChangeLog +++ b/lisp/url/ChangeLog @@ -1,3 +1,9 @@ +2011-07-13 Chris Newton (tiny change) + + * url-http.el (url-http): Copy over `url-show-status' to the async + buffer so that `url-display-percentage' does the right thing + (bug#4680). + 2011-07-06 Nick Dokos (tiny change) * url-cache.el (url-cache-extract): Set buffer multibyte flag to diff --git a/lisp/url/url-http.el b/lisp/url/url-http.el index 7e8b0d958cc..def35449397 100644 --- a/lisp/url/url-http.el +++ b/lisp/url/url-http.el @@ -1172,6 +1172,7 @@ CBARGS as the arguments." url-http-after-change-function url-callback-function url-callback-arguments + url-show-status url-http-method url-http-extra-headers url-http-data @@ -1206,6 +1207,7 @@ CBARGS as the arguments." url-http-chunked-start url-callback-function url-callback-arguments + url-show-status url-http-process url-http-method url-http-extra-headers From 343c3b5a4ed1e8cab5ca6dde473c3a151364dd2b Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 16:20:45 +0200 Subject: [PATCH 10/38] (tags-search): Document `file-list-form' --- lisp/ChangeLog | 5 +++++ lisp/progmodes/etags.el | 6 +++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3baec994c6e..717ad6d94f5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * progmodes/etags.el (tags-search): Document `file-list-form' + (bug#4731). + 2011-07-13 Lawrence Mitchell * net/browse-url.el (browse-url-default-browser) diff --git a/lisp/progmodes/etags.el b/lisp/progmodes/etags.el index 8abf298bb76..385adf1af0a 100644 --- a/lisp/progmodes/etags.el +++ b/lisp/progmodes/etags.el @@ -1860,7 +1860,11 @@ nil, we exit; otherwise we scan the next file." Stops when a match is found. To continue searching for next match, use command \\[tags-loop-continue]. -See documentation of variable `tags-file-name'." +If `file-list-form' is non-nil, it should be a form that, when +evaluated, will return a list of file names. The search will be +restricted to these files. + +Aleso see the documentation of the `tags-file-name' variable." (interactive "sTags search (regexp): ") (if (and (equal regexp "") (eq (car tags-loop-scan) 're-search-forward) From bb388cc58ba4b00c7a30b399760058024030a35e Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 16:34:10 +0200 Subject: [PATCH 11/38] (prefer-coding-system): Add an example Fixes: debbugs:4869 --- lisp/ChangeLog | 3 +++ lisp/international/mule-cmds.el | 6 +++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 717ad6d94f5..87d62690f7c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * international/mule-cmds.el (prefer-coding-system): Add an + example (bug#4869). + * progmodes/etags.el (tags-search): Document `file-list-form' (bug#4731). diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el index e75a22d6415..6a73aaaa838 100644 --- a/lisp/international/mule-cmds.el +++ b/lisp/international/mule-cmds.el @@ -397,7 +397,11 @@ If CODING-SYSTEM specifies a certain type of EOL conversion, the coding systems set by this function will use that type of EOL conversion. A coding system that requires automatic detection of text+encoding -\(e.g. undecided, unix) can't be preferred." +\(e.g. undecided, unix) can't be preferred. + +To prefer, for instance, utf-8, say the following: + + \(prefer-coding-system 'utf-8)" (interactive "zPrefer coding system: ") (if (not (and coding-system (coding-system-p coding-system))) (error "Invalid coding system `%s'" coding-system)) From c26fdcf522246239b2399422b9a1900826ef69b1 Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 16:57:28 +0200 Subject: [PATCH 12/38] Say that we were unable to find the match within the limit * simple.el (blink-matching-open): Say that we were unable to find the match within the limit, if we're limited (bug#5122). --- lisp/ChangeLog | 3 +++ lisp/simple.el | 22 +++++++++++++--------- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 87d62690f7c..60639bcffb2 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * simple.el (blink-matching-open): Say that we were unable to find + the match within the limit, if we're limited (bug#5122). + * international/mule-cmds.el (prefer-coding-system): Add an example (bug#4869). diff --git a/lisp/simple.el b/lisp/simple.el index 2c792a2c78e..383f66a5a13 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -5487,15 +5487,19 @@ The function should return non-nil if the two tokens do not match.") (when (and (not (bobp)) blink-matching-paren) (let* ((oldpos (point)) + (limit-message "") (message-log-max nil) ; Don't log messages about paren matching. (blinkpos (save-excursion (save-restriction - (if blink-matching-paren-distance - (narrow-to-region - (max (minibuffer-prompt-end) ;(point-min) unless minibuf. - (- (point) blink-matching-paren-distance)) - oldpos)) + (when blink-matching-paren-distance + (let ((start (- (point) blink-matching-paren-distance))) + (when (> start (minibuffer-prompt-end)) + (setq limit-message " within the limit")) + (narrow-to-region + (max (minibuffer-prompt-end) ;(point-min) unless minibuf. + start) + oldpos))) (let ((parse-sexp-ignore-comments (and parse-sexp-ignore-comments (not blink-matching-paren-dont-ignore-comments)))) @@ -5517,11 +5521,11 @@ The function should return non-nil if the two tokens do not match.") (mismatch (if blinkpos (if (minibufferp) - (minibuffer-message "Mismatched parentheses") - (message "Mismatched parentheses")) + (minibuffer-message "Mismatched parentheses%s" limit-message) + (message "Mismatched parentheses%s" limit-message)) (if (minibufferp) - (minibuffer-message "Unmatched parenthesis") - (message "Unmatched parenthesis")))) + (minibuffer-message "Unmatched parenthesis%s" limit-message) + (message "Unmatched parenthesis%s" limit-message)))) ((not blinkpos) nil) ((pos-visible-in-window-p blinkpos) ;; Matching open within window, temporarily move to blinkpos but only From f987fde4480f009ccdb588197e4553ef42ba2b9d Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 17:07:57 +0200 Subject: [PATCH 13/38] (General Escape Syntax): "a with grave accent" is ?xe0, not ?x8e0. Fixes: debbugs:5259 --- doc/lispref/ChangeLog | 5 +++++ doc/lispref/objects.texi | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index 1d1730e078d..d7a0fd14ae4 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * objects.texi (General Escape Syntax): "a with grave accent" is + ?xe0, not ?x8e0 (bug#5259). + 2011-07-12 Chong Yidong * display.texi (Face Attributes, Font Selection): Add references diff --git a/doc/lispref/objects.texi b/doc/lispref/objects.texi index 27d9ba10aef..6d63bb7b750 100644 --- a/doc/lispref/objects.texi +++ b/doc/lispref/objects.texi @@ -392,7 +392,7 @@ value is more important than the @acronym{ASCII} representation. and the hexadecimal character code. You can use any number of hex digits, so you can represent any character code in this way. Thus, @samp{?\x41} for the character @kbd{A}, @samp{?\x1} for the -character @kbd{C-a}, and @code{?\x8e0} for the Latin-1 character +character @kbd{C-a}, and @code{?\xe0} for the Latin-1 character @iftex @samp{@`a}. @end iftex @@ -1037,7 +1037,7 @@ digits as necessary. (Multibyte non-@acronym{ASCII} character codes are all greater than 256.) Any character which is not a valid hex digit terminates this construct. If the next character in the string could be interpreted as a hex digit, write @w{@samp{\ }} (backslash and space) to -terminate the hex escape---for example, @w{@samp{\x8e0\ }} represents +terminate the hex escape---for example, @w{@samp{\xe0\ }} represents one character, @samp{a} with grave accent. @w{@samp{\ }} in a string constant is just like backslash-newline; it does not contribute any character to the string, but it does terminate the preceding hex escape. From 7e9505c5eb2fdaef0b85ea64ee9954e8e51dd05a Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 17:15:26 +0200 Subject: [PATCH 14/38] (dired-insert-set-properties): Make the doc string reflect what it does now Fixes: debbugs:5325 --- lisp/ChangeLog | 3 +++ lisp/dired.el | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 60639bcffb2..d27f6b3c2be 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * dired.el (dired-insert-set-properties): Make the doc string + reflect what it does now (bug#5325). + * simple.el (blink-matching-open): Say that we were unable to find the match within the limit, if we're limited (bug#5122). diff --git a/lisp/dired.el b/lisp/dired.el index 62420348d0f..96709ffecd8 100644 --- a/lisp/dired.el +++ b/lisp/dired.el @@ -1175,7 +1175,7 @@ If HDR is non-nil, insert a header line with the directory name." (insert " wildcard " (file-name-nondirectory dir) "\n"))))) (defun dired-insert-set-properties (beg end) - "Make the file names highlight when the mouse is on them." + "Add various text properties to the lines in the region." (save-excursion (goto-char beg) (while (< (point) end) From bf6012e5b1ec29b02dbb2f6b000471ca418055dc Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 13 Jul 2011 17:33:08 +0200 Subject: [PATCH 15/38] Use "yellow" on low color terminals for comments * font-lock.el (font-lock-comment-face): Use the high contrast "yellow" color for font-lock-comment-face on low color terminals using a dark background color. Fixes: debbugs:4221 --- lisp/ChangeLog | 6 ++++++ lisp/font-lock.el | 10 ++-------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d27f6b3c2be..2bc706f8a61 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2011-07-13 Dan Nicolaescu + + * font-lock.el (font-lock-comment-face): Use the high contrast + "yellow" color for font-lock-comment-face on low color terminals + using a dark background color (bug#4221). + 2011-07-13 Lars Magne Ingebrigtsen * dired.el (dired-insert-set-properties): Make the doc string diff --git a/lisp/font-lock.el b/lisp/font-lock.el index 3743dd54b7a..6c76142c59d 100644 --- a/lisp/font-lock.el +++ b/lisp/font-lock.el @@ -1856,19 +1856,13 @@ Sets various variables using `font-lock-defaults' and (((class color) (min-colors 8) (background light)) (:foreground "red")) (((class color) (min-colors 8) (background dark)) - ) + (:foreground "yellow")) (t (:weight bold :slant italic))) "Font Lock mode face used to highlight comments." :group 'font-lock-faces) (defface font-lock-comment-delimiter-face - '((default :inherit font-lock-comment-face) - (((class grayscale))) - (((class color) (min-colors 16))) - (((class color) (min-colors 8) (background light)) - :foreground "red") - (((class color) (min-colors 8) (background dark)) - :foreground "red1")) + '((default :inherit font-lock-comment-face)) "Font Lock mode face used to highlight comment delimiters." :group 'font-lock-faces) From 5fc4038e207dc31e10a6d58d9294617fcda054bf Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Wed, 13 Jul 2011 12:15:07 -0400 Subject: [PATCH 16/38] * simple.el (blink-matching-open): Make error message from last change less verbose. --- lisp/ChangeLog | 5 +++++ lisp/simple.el | 22 +++++++++------------- 2 files changed, 14 insertions(+), 13 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2bc706f8a61..3dccc44375a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Chong Yidong + + * simple.el (blink-matching-open): Make the error message from the + last change less verbose. + 2011-07-13 Dan Nicolaescu * font-lock.el (font-lock-comment-face): Use the high contrast diff --git a/lisp/simple.el b/lisp/simple.el index 383f66a5a13..0f301dae505 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -5487,19 +5487,15 @@ The function should return non-nil if the two tokens do not match.") (when (and (not (bobp)) blink-matching-paren) (let* ((oldpos (point)) - (limit-message "") (message-log-max nil) ; Don't log messages about paren matching. (blinkpos (save-excursion (save-restriction - (when blink-matching-paren-distance - (let ((start (- (point) blink-matching-paren-distance))) - (when (> start (minibuffer-prompt-end)) - (setq limit-message " within the limit")) - (narrow-to-region - (max (minibuffer-prompt-end) ;(point-min) unless minibuf. - start) - oldpos))) + (if blink-matching-paren-distance + (narrow-to-region + (max (minibuffer-prompt-end) ;(point-min) unless minibuf. + (- (point) blink-matching-paren-distance)) + oldpos)) (let ((parse-sexp-ignore-comments (and parse-sexp-ignore-comments (not blink-matching-paren-dont-ignore-comments)))) @@ -5521,11 +5517,11 @@ The function should return non-nil if the two tokens do not match.") (mismatch (if blinkpos (if (minibufferp) - (minibuffer-message "Mismatched parentheses%s" limit-message) - (message "Mismatched parentheses%s" limit-message)) + (minibuffer-message "Mismatched parentheses") + (message "Mismatched parentheses")) (if (minibufferp) - (minibuffer-message "Unmatched parenthesis%s" limit-message) - (message "Unmatched parenthesis%s" limit-message)))) + (minibuffer-message "No matching parenthesis found") + (message "No matching parenthesis found")))) ((not blinkpos) nil) ((pos-visible-in-window-p blinkpos) ;; Matching open within window, temporarily move to blinkpos but only From 1d8c2ccc666d9427741f301334fd03bf73e4d40a Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 18:39:49 +0200 Subject: [PATCH 17/38] Clarify doc string * simple.el (toggle-truncate-lines): Clarify what is toggled (bug#5580). Text by Drew Adams. --- lisp/ChangeLog | 5 +++++ lisp/simple.el | 9 +++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3dccc44375a..c5eb9f94e53 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * simple.el (toggle-truncate-lines): Clarify what is toggled + (bug#5580). Text by Drew Adams. + 2011-07-13 Chong Yidong * simple.el (blink-matching-open): Make the error message from the diff --git a/lisp/simple.el b/lisp/simple.el index 0f301dae505..895496a34f8 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -5303,11 +5303,12 @@ The variable `selective-display' has a separate value for each buffer." (defvaralias 'indicate-unused-lines 'indicate-empty-lines) (defun toggle-truncate-lines (&optional arg) - "Toggle whether to fold or truncate long lines for the current buffer. + "Toggle truncating of long lines for the current buffer. +When truncating is off, long lines are folded. With prefix argument ARG, truncate long lines if ARG is positive, -otherwise don't truncate them. Note that in side-by-side windows, -this command has no effect if `truncate-partial-width-windows' -is non-nil." +otherwise fold them. Note that in side-by-side windows, this +command has no effect if `truncate-partial-width-windows' is +non-nil." (interactive "P") (setq truncate-lines (if (null arg) From c75883645245f01232b98b72e3b417a1fd3c6569 Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 18:58:15 +0200 Subject: [PATCH 18/38] Clarify `mark-ring-max' documentation. * mark.texi (Mark Ring): Clarify how many locations are saved (bug#5770). (Global Mark Ring): Ditto. --- doc/emacs/ChangeLog | 6 ++++++ doc/emacs/mark.texi | 8 ++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index bd5cfdce66b..ce2a5e998e3 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -1,3 +1,9 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * mark.texi (Mark Ring): Clarify how many locations are saved + (bug#5770). + (Global Mark Ring): Ditto. + 2011-07-12 Lars Magne Ingebrigtsen * text.texi (Table Recognition): Use "at point" instead of "under diff --git a/doc/emacs/mark.texi b/doc/emacs/mark.texi index 20cc127d272..1a93f5b79c8 100644 --- a/doc/emacs/mark.texi +++ b/doc/emacs/mark.texi @@ -253,7 +253,9 @@ Another effect of this mode is that some keys, such as @key{DEL} and @cindex mark ring Aside from delimiting the region, the mark is also useful for remembering spots that you may want to go back to. Each buffer -remembers 16 previous locations of the mark, in the @dfn{mark ring}. +remembers @code{mark-ring-max} previous locations of the mark, in the +@dfn{mark ring}. This defaults to 16 locations. + Commands that set the mark also push the old mark onto this ring. @table @kbd @@ -315,10 +317,12 @@ Positions in Registers}). @section The Global Mark Ring @cindex global mark ring +@vindex global-mark-ring-max In addition to the ordinary mark ring that belongs to each buffer, Emacs has a single @dfn{global mark ring}. Each time you set a mark, in any buffer, this is recorded in the global mark ring in addition to -the current buffer's own mark ring. +the current buffer's own mark ring. The length of this ring can be +controlled by @code{global-mark-ring-max}, and is 16 by default. @kindex C-x C-@key{SPC} @findex pop-global-mark From 6240145a7f5a355575a5ca3206e89c3baba95b3c Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 13 Jul 2011 13:34:31 -0400 Subject: [PATCH 19/38] Small dired fixes related to bug#9039. * lisp/dired.el (dired-use-ls-dired): Doc fix. (dired-insert-directory): Give a message the first time if ls is found not to support --dired. --- lisp/ChangeLog | 6 ++++++ lisp/dired.el | 26 +++++++++++++++++++++----- 2 files changed, 27 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c5eb9f94e53..22f5d304f6f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2011-07-13 Glenn Morris + + * dired.el (dired-use-ls-dired): Doc fix. (Bug#9039). + (dired-insert-directory): Give a message the first time + if ls is found not to support --dired. + 2011-07-13 Lars Magne Ingebrigtsen * simple.el (toggle-truncate-lines): Clarify what is toggled diff --git a/lisp/dired.el b/lisp/dired.el index 96709ffecd8..3606e3df335 100644 --- a/lisp/dired.el +++ b/lisp/dired.el @@ -78,10 +78,22 @@ If nil, `dired-listing-switches' is used." :type 'file) (defcustom dired-use-ls-dired 'unspecified - "Non-nil means Dired should use \"ls --dired\". + "Non-nil means Dired should pass the \"--dired\" option to \"ls\". The special value of `unspecified' means to check explicitly, and save the result in this variable. This is performed the first -time `dired-insert-directory' is called." +time `dired-insert-directory' is called. + +Note that if you set this option to nil, either through choice or +because your \"ls\" program does not support \"--dired\", Dired +will fail to parse some \"unusual\" file names, e.g. those with leading +spaces. You might want to install ls from GNU Coreutils, which does +support this option. Alternatively, you might want to use Emacs's +own emulation of \"ls\", by using: + \(setq ls-lisp-use-insert-directory-program nil) + \(require 'ls-lisp) +This is used by default on MS Windows, which does not have an \"ls\" program. +Note that `ls-lisp' does not support as many options as GNU ls, though. +For more details, see Info node `(emacs)ls in Lisp'." :group 'dired :type '(choice (const :tag "Check for --dired support" unspecified) (const :tag "Do not use --dired" nil) @@ -1119,9 +1131,13 @@ If HDR is non-nil, insert a header line with the directory name." (or (if (eq dired-use-ls-dired 'unspecified) ;; Check whether "ls --dired" gives exit code 0, and ;; save the answer in `dired-use-ls-dired'. - (setq dired-use-ls-dired - (eq (call-process insert-directory-program nil nil nil "--dired") - 0)) + (or (setq dired-use-ls-dired + (eq 0 (call-process insert-directory-program + nil nil nil "--dired"))) + (progn + (message "ls does not support --dired; \ +see `dired-use-ls-dired' for more details.") + nil)) dired-use-ls-dired) (file-remote-p dir))) (setq switches (concat "--dired " switches))) From 3af98a7b7df9ae243e9c05f34a80fdfb92ea42a3 Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 19:47:17 +0200 Subject: [PATCH 20/38] Doc string fix. * progmodes/cperl-mode.el (cperl-syntaxify-by-font-lock): Rewrite to avoid awkward possessive "s". Fixes: debbugs:5986 --- lisp/ChangeLog | 5 +++++ lisp/progmodes/cperl-mode.el | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 22f5d304f6f..1a0c445f965 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * progmodes/cperl-mode.el (cperl-syntaxify-by-font-lock): Rewrite + to avoid awkward possessive "s" (bug#5986). + 2011-07-13 Glenn Morris * dired.el (dired-use-ls-dired): Doc fix. (Bug#9039). diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el index 48df73a678f..ad3b777977c 100644 --- a/lisp/progmodes/cperl-mode.el +++ b/lisp/progmodes/cperl-mode.el @@ -613,7 +613,7 @@ One should tune up `cperl-close-paren-offset' as well." (defcustom cperl-syntaxify-by-font-lock (and cperl-can-font-lock (boundp 'parse-sexp-lookup-properties)) - "*Non-nil means that CPerl uses `font-lock's routines for syntaxification." + "*Non-nil means that CPerl uses the `font-lock' routines for syntaxification." :type '(choice (const message) boolean) :group 'cperl-speed) From 90a6258b05e00c6e47acc4e85edabf6e92ea1e84 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 13 Jul 2011 13:55:04 -0400 Subject: [PATCH 21/38] * doc/emacs/dired.texi (Dired Enter): Mention --dired. (Bug#9039) --- doc/emacs/ChangeLog | 4 ++++ doc/emacs/dired.texi | 7 +++++++ 2 files changed, 11 insertions(+) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index ce2a5e998e3..0102e028d49 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -1,3 +1,7 @@ +2011-07-13 Glenn Morris + + * dired.texi (Dired Enter): Mention --dired. (Bug#9039) + 2011-07-13 Lars Magne Ingebrigtsen * mark.texi (Mark Ring): Clarify how many locations are saved diff --git a/doc/emacs/dired.texi b/doc/emacs/dired.texi index fb3521e4316..501c4152e6a 100644 --- a/doc/emacs/dired.texi +++ b/doc/emacs/dired.texi @@ -81,6 +81,13 @@ specified, the @code{ls} switches can include short options (that is, single characters) requiring no arguments, and long options (starting with @samp{--}) whose arguments are specified with @samp{=}. +@vindex dired-use-ls-dired + Note that Dired automatically adds the option @samp{--dired}, if +your @code{ls} program supports it, unless you explicitly set +the variable @code{dired-use-ls-dired} to @code{nil}. Without this +option, Dired will have trouble parsing some @samp{unusual} file-names. +See the documentation of @code{dired-use-ls-dired} for more details. + On MS-Windows and MS-DOS systems, Emacs @emph{emulates} @code{ls}; see @ref{ls in Lisp}, for options and peculiarities of that emulation. From bead9a43c1c13b812b4c4f10219a79897e18617d Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 13 Jul 2011 20:12:05 +0200 Subject: [PATCH 22/38] Preserve point when doing untabify * tabify.el (untabify): Preserve the current column so that point doesn't move. Fixes: debbugs:6032 --- lisp/ChangeLog | 5 +++++ lisp/tabify.el | 28 +++++++++++++++------------- 2 files changed, 20 insertions(+), 13 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1a0c445f965..47f6b6c9aa6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Juanma Barranquero + + * tabify.el (untabify): Preserve the current column so that point + doesn't move (bug#6032). + 2011-07-13 Lars Magne Ingebrigtsen * progmodes/cperl-mode.el (cperl-syntaxify-by-font-lock): Rewrite diff --git a/lisp/tabify.el b/lisp/tabify.el index da1038a2164..0b2411d0316 100644 --- a/lisp/tabify.el +++ b/lisp/tabify.el @@ -34,19 +34,21 @@ Called non-interactively, the region is specified by arguments START and END, rather than by the position of point and mark. The variable `tab-width' controls the spacing of tab stops." (interactive "r") - (save-excursion - (save-restriction - (narrow-to-region (point-min) end) - (goto-char start) - (while (search-forward "\t" nil t) ; faster than re-search - (forward-char -1) - (let ((tab-beg (point)) - (indent-tabs-mode nil) - column) - (skip-chars-forward "\t") - (setq column (current-column)) - (delete-region tab-beg (point)) - (indent-to column)))))) + (let ((c (current-column))) + (save-excursion + (save-restriction + (narrow-to-region (point-min) end) + (goto-char start) + (while (search-forward "\t" nil t) ; faster than re-search + (forward-char -1) + (let ((tab-beg (point)) + (indent-tabs-mode nil) + column) + (skip-chars-forward "\t") + (setq column (current-column)) + (delete-region tab-beg (point)) + (indent-to column))))) + (move-to-column c))) (defvar tabify-regexp " [ \t]+" "Regexp matching whitespace that tabify should consider. From ac389d0c75f29a4c5bdf05c7180cabd96a7ae7e6 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 13 Jul 2011 22:33:44 +0200 Subject: [PATCH 23/38] src/gnutls.c (init_gnutls_functions): Honor gnutls_log_level (bug#9059). --- src/ChangeLog | 14 +++++++++----- src/gnutls.c | 9 +++++++-- 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 2721704223c..a045a7ddd21 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2011-07-13 Juanma Barranquero + + * gnutls.c (init_gnutls_functions): Honor gnutls_log_level (bug#9059). + 2011-07-13 Eli Zaretskii * buffer.c (mmap_find): Fix a typo. @@ -16,7 +20,7 @@ 2011-07-13 Paul Eggert - * buffer.c (Fget_buffer_create): Initialized inhibit_shrinking. + * buffer.c (Fget_buffer_create): Initialize inhibit_shrinking. The old code sometimes used this field without initializing it. * alloc.c (gc_sweep): Don't read past end of array. @@ -26,7 +30,7 @@ 2011-07-12 Andreas Schwab * character.c (Fcharacterp): Don't advertise optional ignored - argument. (Bug#4026) + argument. (Bug#4026) 2011-07-12 Lars Magne Ingebrigtsen @@ -240,7 +244,7 @@ (char_table_ascii): Uncompress the compressed values. (sub_char_table_ref): New arg is_uniprop. Callers changed. Uncompress the compressed values. - (sub_char_table_ref_and_range): Likewise. + (sub_char_table_ref_and_range): Likewise. (char_table_ref_and_range): Uncompress the compressed values. (sub_char_table_set): New arg is_uniprop. Callers changed. Uncompress the compressed values. @@ -1918,7 +1922,7 @@ (xpm_put_color_table_h): * lisp.h (struct Lisp_Hash_Table): * minibuf.c (Ftry_completion, Fall_completions, Ftest_completion): - * print.c (print): Use 'EMACS_UINT' and 'EMACS_INT' + * print.c (print): Use 'EMACS_UINT' and 'EMACS_INT' for hashes and hash indexes, instead of 'unsigned' and 'int'. * alloc.c (allocate_vectorlike): Check for overflow in vector size calculations. @@ -2215,7 +2219,7 @@ * dispnew.c (shift_glyph_matrix, scrolling_window): Mark scrolled row for fringe update if it has periodic bitmap. - (row_equal_p): Also compare left_fringe_offset, right_fringe_offset, + (row_equal_p): Also compare left_fringe_offset, right_fringe_offset, and fringe_bitmap_periodic_p. * fringe.c (get_fringe_bitmap_data): New function. diff --git a/src/gnutls.c b/src/gnutls.c index 76cfa5dcc98..3761951b866 100644 --- a/src/gnutls.c +++ b/src/gnutls.c @@ -143,10 +143,12 @@ static int init_gnutls_functions (Lisp_Object libraries) { HMODULE library; + Lisp_Object gnutls_log_level = Fsymbol_value (Qgnutls_log_level); + int max_log_level = 1; if (!(library = w32_delayed_load (libraries, Qgnutls_dll))) { - GNUTLS_LOG (1, 1, "GnuTLS library not found"); + GNUTLS_LOG (1, max_log_level, "GnuTLS library not found"); return 0; } @@ -189,7 +191,10 @@ init_gnutls_functions (Lisp_Object libraries) LOAD_GNUTLS_FN (library, gnutls_x509_crt_import); LOAD_GNUTLS_FN (library, gnutls_x509_crt_init); - GNUTLS_LOG2 (1, 1, "GnuTLS library loaded:", + if (NUMBERP (gnutls_log_level)) + max_log_level = XINT (gnutls_log_level); + + GNUTLS_LOG2 (1, max_log_level, "GnuTLS library loaded:", SDATA (Fget (Qgnutls_dll, QCloaded_from))); return 1; } From 5827450416985ed689cfa0ca1843a2ec2b0cd31d Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 23:27:13 +0200 Subject: [PATCH 24/38] * dired.el (dired-flagged): Clarify doc string. Fixes: debbugs:6117 --- lisp/ChangeLog | 4 ++++ lisp/dired.el | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 47f6b6c9aa6..41a7f0b1d2e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * dired.el (dired-flagged): Clarify doc string (bug#6117). + 2011-07-13 Juanma Barranquero * tabify.el (untabify): Preserve the current column so that point diff --git a/lisp/dired.el b/lisp/dired.el index 3606e3df335..01d41bba27d 100644 --- a/lisp/dired.el +++ b/lisp/dired.el @@ -351,11 +351,11 @@ Subexpression 2 must end right before the \\n or \\r.") (defface dired-flagged '((t (:inherit font-lock-warning-face))) - "Face used for flagged files." + "Face used for files flagged for deletion." :group 'dired-faces :version "22.1") (defvar dired-flagged-face 'dired-flagged - "Face name used for flagged files.") + "Face name used for files flagged for deletion.") (defface dired-warning ;; Inherit from font-lock-warning-face since with min-colors 8 From 465c5fc88d4d7f0cbeba1a12852a4be70d6ed28b Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 23:38:56 +0200 Subject: [PATCH 25/38] Clarify manual and `add-hook' doc string about buffer-local hooks --- doc/emacs/ChangeLog | 4 ++++ doc/emacs/custom.texi | 6 ++++++ lisp/ChangeLog | 3 +++ lisp/subr.el | 8 ++++---- 4 files changed, 17 insertions(+), 4 deletions(-) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index 0102e028d49..e21a02f700f 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -1,3 +1,7 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * custom.texi (Hooks): Mention buffer-local hooks (bug#6218). + 2011-07-13 Glenn Morris * dired.texi (Dired Enter): Mention --dired. (Bug#9039) diff --git a/doc/emacs/custom.texi b/doc/emacs/custom.texi index 8465dd93519..6a6d465438d 100644 --- a/doc/emacs/custom.texi +++ b/doc/emacs/custom.texi @@ -820,6 +820,12 @@ the versions you added will remain in the hook variable together. You can clear out individual functions by calling @code{remove-hook}, or do @code{(setq @var{hook-variable} nil)} to remove everything. +@cindex buffer-local hooks + If the hook variable is buffer-local, the buffer-local variable will +be used instead of the global variable. However, if the buffer-local +variable contains the element @code{t}, the global hook variable will +be run as well. + @node Locals @subsection Local Variables diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 41a7f0b1d2e..be42c4b8b2a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * subr.el (add-hook): Clarify section about buffer-local hooks + (bug#6218). + * dired.el (dired-flagged): Clarify doc string (bug#6117). 2011-07-13 Juanma Barranquero diff --git a/lisp/subr.el b/lisp/subr.el index 5c9d6c8d724..a2f560461eb 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -1262,10 +1262,10 @@ unless the optional argument APPEND is non-nil, in which case FUNCTION is added at the end. The optional fourth argument, LOCAL, if non-nil, says to modify -the hook's buffer-local value rather than its default value. -This makes the hook buffer-local if needed, and it makes t a member -of the buffer-local value. That acts as a flag to run the hook -functions in the default value as well as in the local value. +the hook's buffer-local value rather than its global value. +This makes the hook buffer-local, and it makes t a member of the +buffer-local value. That acts as a flag to run the hook +functions of the global value as well as in the local value. HOOK should be a symbol, and FUNCTION may be any valid function. If HOOK is void, it is first set to nil. If HOOK's value is a single From 63d55f1f91e7ed9bc9a190a9861103b955ef6381 Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 23:42:54 +0200 Subject: [PATCH 26/38] * modes.texi (Running Hooks): Mention buffer-local hook variables Fixes: debbugs:6218 --- doc/lispref/ChangeLog | 3 +++ doc/lispref/modes.texi | 15 ++++++++++----- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index d7a0fd14ae4..1a62dd88dfc 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * modes.texi (Running Hooks): Mention buffer-local hook variables + (bug#6218). + * objects.texi (General Escape Syntax): "a with grave accent" is ?xe0, not ?x8e0 (bug#5259). diff --git a/doc/lispref/modes.texi b/doc/lispref/modes.texi index a8a10f750cc..dd3b2e3038f 100644 --- a/doc/lispref/modes.texi +++ b/doc/lispref/modes.texi @@ -101,6 +101,11 @@ one, with no arguments. The hook variable's value can also be a single function---either a lambda expression or a symbol with a function definition---which @code{run-hooks} calls. But this usage is obsolete. + +If the hook variable is buffer-local, the buffer-local variable will +be used instead of the global variable. However, if the buffer-local +variable contains the element @code{t}, the global hook variable will +be run as well. @end defun @defun run-hook-with-args hook &rest args @@ -169,11 +174,11 @@ function goes at the end of the hook list and will be executed last. value is a single function; it sets or changes the value to a list of functions. -If @var{local} is non-@code{nil}, that says to add @var{function} to -the buffer-local hook list instead of to the global hook list. If -needed, this makes the hook buffer-local and adds @code{t} to the -buffer-local value. The latter acts as a flag to run the hook -functions in the default value as well as in the local value. +If @var{local} is non-@code{nil}, that says to add @var{function} to the +buffer-local hook list instead of to the global hook list. This makes +the hook buffer-local and adds @code{t} to the buffer-local value. The +latter acts as a flag to run the hook functions in the default value as +well as in the local value. @end defun @defun remove-hook hook function &optional local From 0f04b32ce1d0f6f6e94b77931122acf3da3b3680 Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Wed, 13 Jul 2011 23:53:41 +0200 Subject: [PATCH 27/38] * startup.el (initial-buffer-choice): Add `none' as a choice Fixes: debbugs:6234 --- lisp/ChangeLog | 3 +++ lisp/startup.el | 9 ++++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index be42c4b8b2a..86bc82f3ecd 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * startup.el (initial-buffer-choice): Add `none' as a choice + (bug#6234). + * subr.el (add-hook): Clarify section about buffer-local hooks (bug#6218). diff --git a/lisp/startup.el b/lisp/startup.el index c6f3063ca90..66deb11623a 100644 --- a/lisp/startup.el +++ b/lisp/startup.el @@ -41,13 +41,16 @@ (defcustom initial-buffer-choice nil "Buffer to show after starting Emacs. If the value is nil and `inhibit-startup-screen' is nil, show the -startup screen. If the value is string, visit the specified file or -directory using `find-file'. If t, open the `*scratch*' buffer." +startup screen. If the value is string, visit the specified file +or directory using `find-file'. If t, open the `*scratch*' +buffer. If `none', don't select anything, but show the +buffer (if any) selected by the startup file." :type '(choice (const :tag "Startup screen" nil) (directory :tag "Directory" :value "~/") (file :tag "File" :value "~/.emacs") - (const :tag "Lisp scratch buffer" t)) + (const :tag "Lisp scratch buffer" t) + (const :tag "Select no buffer" 'none)) :version "23.1" :group 'initialization) From bee0fcef3d9c332b9907369b4e6f6f61d6fbdf35 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Wed, 13 Jul 2011 18:00:48 -0400 Subject: [PATCH 28/38] Add FORCE-SAME-WINDOW argument to switch-to-buffer. * lisp/window.el (switch-to-buffer): New arg FORCE-SAME-WINDOW. Use pop-to-buffer buffer-or-name if it is nil. * lisp/emacs-lisp/bytecomp.el (byte-compile-interactive-only-functions): Remove switch-to-buffer. --- etc/NEWS | 9 ++++++++ lisp/ChangeLog | 8 +++++++ lisp/emacs-lisp/bytecomp.el | 2 +- lisp/window.el | 42 ++++++++++++++++++++++--------------- 4 files changed, 43 insertions(+), 18 deletions(-) diff --git a/etc/NEWS b/etc/NEWS index 8a37735b41f..3f23c23fe3a 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -986,6 +986,15 @@ sc.el, x-menu.el, rnews.el, rnewspost.el * Lisp changes in Emacs 24.1 +** Window changes + +*** `switch-to-buffer' has a new optional argument FORCE-SAME-WINDOW, +which if non-nil requires the buffer to be displayed in the currently +selected window, signaling an error otherwise. If nil, another window +can be used, e.g. if the selected one is strongly dedicated. + +*** FIXME: buffer-display-alist changes + ** Completion *** New variable completion-extra-properties used to specify extra properties of the current completion: diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 86bc82f3ecd..17cbc948536 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2011-07-13 Chong Yidong + + * window.el (switch-to-buffer): New arg FORCE-SAME-WINDOW. Use + pop-to-buffer buffer-or-name if it is nil. + + * emacs-lisp/bytecomp.el (byte-compile-interactive-only-functions): + Remove switch-to-buffer. + 2011-07-13 Lars Magne Ingebrigtsen * startup.el (initial-buffer-choice): Add `none' as a choice diff --git a/lisp/emacs-lisp/bytecomp.el b/lisp/emacs-lisp/bytecomp.el index 223e9667ac3..127f93c6858 100644 --- a/lisp/emacs-lisp/bytecomp.el +++ b/lisp/emacs-lisp/bytecomp.el @@ -355,7 +355,7 @@ else the global value will be modified." (defvar byte-compile-interactive-only-functions '(beginning-of-buffer end-of-buffer replace-string replace-regexp insert-file insert-buffer insert-file-literally previous-line next-line - goto-line comint-run delete-backward-char switch-to-buffer) + goto-line comint-run delete-backward-char) "List of commands that are not meant to be called from Lisp.") (defvar byte-compile-not-obsolete-vars nil diff --git a/lisp/window.el b/lisp/window.el index 999e408bdb1..593fa14d215 100644 --- a/lisp/window.el +++ b/lisp/window.el @@ -5925,7 +5925,7 @@ buffer with the name BUFFER-OR-NAME and return that buffer." buffer)) (other-buffer))) -(defun switch-to-buffer (buffer-or-name &optional norecord) +(defun switch-to-buffer (buffer-or-name &optional norecord force-same-window) "Switch to buffer BUFFER-OR-NAME in the selected window. If called interactively, prompt for the buffer name using the minibuffer. The variable `confirm-nonexistent-file-or-buffer' @@ -5941,25 +5941,33 @@ BUFFER-OR-NAME is nil, switch to the buffer returned by Optional argument NORECORD non-nil means do not put the buffer specified by BUFFER-OR-NAME at the front of the buffer list and do not make the window displaying it the most recently selected -one. Return the buffer switched to. +one. -This function is intended for interactive use only. Lisp -functions should call `pop-to-buffer-same-window' instead." +If FORCE-SAME-WINDOW is non-nil, BUFFER-OR-NAME must be displayed +in the currently selected window; signal an error if that is +impossible (e.g. if the selected window is minibuffer-only). +If non-nil, BUFFER-OR-NAME may be displayed in another window. + +Return the buffer switched to." (interactive - (list (read-buffer-to-switch "Switch to buffer: "))) + (list (read-buffer-to-switch "Switch to buffer: ") nil nil)) (let ((buffer (window-normalize-buffer-to-switch-to buffer-or-name))) - (cond - ;; Don't call set-window-buffer if it's not needed since it - ;; might signal an error (e.g. if the window is dedicated). - ((eq buffer (window-buffer)) nil) - ((window-minibuffer-p) - (error "Cannot switch buffers in minibuffer window")) - ((eq (window-dedicated-p) t) - (error "Cannot switch buffers in a dedicated window")) - (t (set-window-buffer nil buffer))) - (unless norecord - (select-window (selected-window))) - (set-buffer buffer))) + (if (null force-same-window) + (pop-to-buffer buffer-or-name + '(same-window (reuse-window-dedicated . weak)) + norecord nil) + (cond + ;; Don't call set-window-buffer if it's not needed since it + ;; might signal an error (e.g. if the window is dedicated). + ((eq buffer (window-buffer)) nil) + ((window-minibuffer-p) + (error "Cannot switch buffers in minibuffer window")) + ((eq (window-dedicated-p) t) + (error "Cannot switch buffers in a dedicated window")) + (t (set-window-buffer nil buffer))) + (unless norecord + (select-window (selected-window))) + (set-buffer buffer)))) (defun switch-to-buffer-same-frame (buffer-or-name &optional norecord) "Switch to buffer BUFFER-OR-NAME in a window on the selected frame. From bd2fcc8d5cb29bfce6a4f30c8aa42feb3b24706f Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Thu, 14 Jul 2011 00:22:08 +0200 Subject: [PATCH 29/38] (make-directory): Clarify that an error will be raised if there's an error Fixes: debbugs:6387 --- lisp/ChangeLog | 3 +++ lisp/files.el | 5 ++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 17cbc948536..00a48ff73c1 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -8,6 +8,9 @@ 2011-07-13 Lars Magne Ingebrigtsen + * files.el (make-directory): Clarify that an error will be raised + if there's an error (bug#6397). + * startup.el (initial-buffer-choice): Add `none' as a choice (bug#6234). diff --git a/lisp/files.el b/lisp/files.el index bf38ce39a07..0b253fcc297 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -4778,7 +4778,10 @@ visited a file in a nonexistent directory. Noninteractively, the second (optional) argument PARENTS, if non-nil, says whether to create parent directories that don't -exist. Interactively, this happens by default." +exist. Interactively, this happens by default. + +If creating the directory or directories fail, an error will be +raised." (interactive (list (read-file-name "Make directory: " default-directory default-directory nil nil) From 0bc59b255ed42e57192b0d41c4848685d1019490 Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Thu, 14 Jul 2011 01:17:24 +0200 Subject: [PATCH 30/38] Mention :visible menu bar separators * keymaps.texi (Menu Bar): Mention :visible and :enable (bug#6344). Text by Drew Adams. Fixes: debbugs:6334 --- doc/lispref/ChangeLog | 3 +++ doc/lispref/keymaps.texi | 11 +++++++++++ 2 files changed, 14 insertions(+) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index 1a62dd88dfc..3e40384eec7 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * keymaps.texi (Menu Bar): Mention :visible and :enable + (bug#6344). Text by Drew Adams. + * modes.texi (Running Hooks): Mention buffer-local hook variables (bug#6218). diff --git a/doc/lispref/keymaps.texi b/doc/lispref/keymaps.texi index cf1db5b7fce..15b2f2079ba 100644 --- a/doc/lispref/keymaps.texi +++ b/doc/lispref/keymaps.texi @@ -2262,6 +2262,17 @@ the double-dash and replacing each single dash with capitalization of the following word. Thus, @code{"--:singleLine"}, is equivalent to @code{"--single-line"}. + You can use a longer form to specify keywords such as @code{:enable} +and @code{:visible} for a menu separator: + +@code{(menu-item @var{separator-type} nil . @var{item-property-list})} + +For example: + +@example +(menu-item "--" nil :visible (boundp 'foo)) +@end example + Some systems and display toolkits don't really handle all of these separator types. If you use a type that isn't supported, the menu displays a similar kind of separator that is supported. From 15853710e143abed3bbfab05b10960a5fc9eb79a Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Thu, 14 Jul 2011 01:35:36 +0200 Subject: [PATCH 31/38] Doc fix for eval-expression * simple.el (eval-expression): Note what it does if called interactively. Fixes: debbugs:6495 --- lisp/ChangeLog | 5 +++++ lisp/simple.el | 2 ++ 2 files changed, 7 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 00a48ff73c1..71faf19b621 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * simple.el (eval-expression): Note what it does if called + interactively (bug#6495). + 2011-07-13 Chong Yidong * window.el (switch-to-buffer): New arg FORCE-SAME-WINDOW. Use diff --git a/lisp/simple.el b/lisp/simple.el index 895496a34f8..64333402924 100644 --- a/lisp/simple.el +++ b/lisp/simple.el @@ -1152,6 +1152,8 @@ display the result of expression evaluation." (defun eval-expression (eval-expression-arg &optional eval-expression-insert-value) "Evaluate EVAL-EXPRESSION-ARG and print value in the echo area. +When called interactively, read an Emacs Lisp expression and +evaluate it. Value is also consed on to front of the variable `values'. Optional argument EVAL-EXPRESSION-INSERT-VALUE non-nil (interactively, with prefix argument) means insert the result into the current buffer From a28e4607f0c5c5812a87dd816559d1601ed146ba Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Thu, 14 Jul 2011 01:40:11 +0200 Subject: [PATCH 32/38] Doc fix for with-silent-modifications * subr.el (with-silent-modifications): Clarify somewhat what the macro inhibits. Fixes: debbugs:6525 --- lisp/ChangeLog | 3 +++ lisp/subr.el | 11 +++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 71faf19b621..b78a6a4c580 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2011-07-13 Lars Magne Ingebrigtsen + * subr.el (with-silent-modifications): Clarify somewhat what the + macro inhibits (bug#6525). + * simple.el (eval-expression): Note what it does if called interactively (bug#6495). diff --git a/lisp/subr.el b/lisp/subr.el index a2f560461eb..5c890eefa29 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -3072,8 +3072,15 @@ See also `with-temp-file' and `with-output-to-string'." "Execute BODY, pretending it does not modify the buffer. If BODY performs real modifications to the buffer's text, other than cosmetic ones, undo data may become corrupted. -Typically used around modifications of text-properties which do not really -affect the buffer's content." + +This macro will run BODY normally, but doesn't count its buffer +modifications as being buffer modifications. This affects things +like buffer-modified-p, checking whether the file is locked by +someone else, running buffer modification hooks, and other things +of that nature. + +Typically used around modifications of text-properties which do +not really affect the buffer's content." (declare (debug t) (indent 0)) (let ((modified (make-symbol "modified"))) `(let* ((,modified (buffer-modified-p)) From 837c31f8306d5e21689e325807ef2fff4e5bae9e Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Thu, 14 Jul 2011 01:48:35 +0200 Subject: [PATCH 33/38] Fstring_to_char doc clarification * editfns.c (Fstring_to_char): Clarify just what is returned (bug#6576). Text by Eli Zaretskii. --- src/ChangeLog | 5 +++++ src/editfns.c | 8 ++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index a045a7ddd21..36a7539b888 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2011-07-13 Lars Magne Ingebrigtsen + + * editfns.c (Fstring_to_char): Clarify just what is returned + (bug#6576). Text by Eli Zaretskii. + 2011-07-13 Juanma Barranquero * gnutls.c (init_gnutls_functions): Honor gnutls_log_level (bug#9059). diff --git a/src/editfns.c b/src/editfns.c index bb36d0dee71..6df44352756 100644 --- a/src/editfns.c +++ b/src/editfns.c @@ -194,8 +194,12 @@ DEFUN ("byte-to-string", Fbyte_to_string, Sbyte_to_string, 1, 1, 0, } DEFUN ("string-to-char", Fstring_to_char, Sstring_to_char, 1, 1, 0, - doc: /* Convert arg STRING to a character, the first character of that string. -A multibyte character is handled correctly. */) + doc: /* Return the first character in STRING. +A multibyte character is handled correctly. +The value returned is a Unicode codepoint if it is below #x110000 (in +hex). Codepoints beyond that are Emacs extensions of Unicode. In +particular, eight-bit characters are returned as codepoints in the +range #x3FFF80 through #x3FFFFF, inclusive. */) (register Lisp_Object string) { register Lisp_Object val; From f2027cdf5adf8bcb620a31addf5a5851e542affd Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Thu, 14 Jul 2011 02:02:09 +0200 Subject: [PATCH 34/38] (Documentation Basics): Add a link to the Function Documentation node. Fixes: debbugs:6580 --- doc/lispref/ChangeLog | 5 +++++ doc/lispref/help.texi | 11 ++++++----- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index 3e40384eec7..19da0a3c442 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,3 +1,8 @@ +2011-07-14 Lars Magne Ingebrigtsen + + * help.texi (Documentation Basics): Add a link to the Function + Documentation node (bug#6580). + 2011-07-13 Lars Magne Ingebrigtsen * keymaps.texi (Menu Bar): Mention :visible and :enable diff --git a/doc/lispref/help.texi b/doc/lispref/help.texi index 63fc06c929b..0ce05d55a07 100644 --- a/doc/lispref/help.texi +++ b/doc/lispref/help.texi @@ -78,11 +78,12 @@ function or variable that it describes: @item @kindex function-documentation The documentation for a function is usually stored in the function -definition itself (@pxref{Lambda Expressions}). The function -@code{documentation} knows how to extract it. You can also put -function documentation in the @code{function-documentation} property -of the function name. That is useful with definitions such as -keyboard macros that can't hold a documentation string. +definition itself (@pxref{Lambda Expressions} and @pxref{Function +Documentation}). The function @code{documentation} knows how to +extract it. You can also put function documentation in the +@code{function-documentation} property of the function name. That is +useful with definitions such as keyboard macros that can't hold a +documentation string. @item @kindex variable-documentation From c0a8ae956f71631400fcb52669f4f923ed4151af Mon Sep 17 00:00:00 2001 From: Kevin Ryde Date: Thu, 14 Jul 2011 02:14:35 +0200 Subject: [PATCH 35/38] * cl.texi (For Clauses): Add destructuring example processing an alist. --- doc/misc/ChangeLog | 5 +++++ doc/misc/cl.texi | 9 ++++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 3738301ceea..9687f474286 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,8 @@ +2010-07-10 Kevin Ryde + + * cl.texi (For Clauses): Add destructuring example processing an + alist (bug#6596). + 2011-07-12 Lars Magne Ingebrigtsen * org.texi (Special agenda views): Fix double quoting (bug#3509). diff --git a/doc/misc/cl.texi b/doc/misc/cl.texi index ab54b99138a..3f3d616e343 100644 --- a/doc/misc/cl.texi +++ b/doc/misc/cl.texi @@ -2586,7 +2586,14 @@ the trailing values are ignored, and if there are more variables than values the trailing variables get the value @code{nil}. If @code{nil} is used as a variable name, the corresponding values are ignored. Destructuring may be nested, and dotted -lists of variables like @code{(x . y)} are allowed. +lists of variables like @code{(x . y)} are allowed, so for example +to process an alist + +@example +(loop for (key . value) in '((a . 1) (b . 2)) + collect value) + @result{} (1 2) +@end example @node Iteration Clauses, Accumulation Clauses, For Clauses, Loop Facility @subsection Iteration Clauses From 5eba16a37cacff2065186df8cb6153ccaebae298 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 14 Jul 2011 03:09:00 +0200 Subject: [PATCH 36/38] Fix typos. --- admin/charsets/mule-charsets.el | 2 +- lisp/ChangeLog | 6 +++++ lisp/ChangeLog.6 | 2 +- lisp/emacs-lisp/testcover.el | 2 +- lisp/follow.el | 46 ++++++++++++++++----------------- lisp/gnus/ChangeLog.2 | 2 +- lisp/jka-cmpr-hook.el | 2 +- lisp/winner.el | 2 +- src/ChangeLog.6 | 2 +- test/eshell.el | 2 +- 10 files changed, 37 insertions(+), 31 deletions(-) diff --git a/admin/charsets/mule-charsets.el b/admin/charsets/mule-charsets.el index 59969c3df28..9ac08bef724 100644 --- a/admin/charsets/mule-charsets.el +++ b/admin/charsets/mule-charsets.el @@ -1,4 +1,4 @@ -;; mule-charsets.el -- Generate Mule-orignal charset maps. +;; mule-charsets.el -- Generate Mule-original charset maps. ;; Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 ;; National Institute of Advanced Industrial Science and Technology (AIST) ;; Registration Number H13PRO009 diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b78a6a4c580..4aa24d499e2 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2011-07-14 Juanma Barranquero + + * follow.el (follow-debug-message, follow-redisplay): + * jka-cmpr-hook.el (with-auto-compression-mode): + Fix typos in docstrings. + 2011-07-13 Lars Magne Ingebrigtsen * subr.el (with-silent-modifications): Clarify somewhat what the diff --git a/lisp/ChangeLog.6 b/lisp/ChangeLog.6 index 2f73c290231..7ba9261ccf0 100644 --- a/lisp/ChangeLog.6 +++ b/lisp/ChangeLog.6 @@ -6892,7 +6892,7 @@ (find-file-noselect): Use it if new optional argument `rawfile' is non-nil. - * startup.el (command-line-1): Add option --eval to evalute an + * startup.el (command-line-1): Add option --eval to evaluate an expression on the command line and print the result. 1995-08-14 Richard Stallman diff --git a/lisp/emacs-lisp/testcover.el b/lisp/emacs-lisp/testcover.el index 2f168180cf6..4c83e7e2e0d 100644 --- a/lisp/emacs-lisp/testcover.el +++ b/lisp/emacs-lisp/testcover.el @@ -28,7 +28,7 @@ ;; * Use `testcover-mark-all' to add overlay "splotches" to the Lisp file's ;; buffer to show where coverage is lacking. Normally, a red splotch ;; indicates the form was never evaluated; a brown splotch means it always -;; evaluted to the same value. +;; evaluated to the same value. ;; * Use `testcover-next-mark' (bind it to a key!) to jump to the next spot ;; that has a splotch. diff --git a/lisp/follow.el b/lisp/follow.el index 9bf472e547c..94a542f1016 100644 --- a/lisp/follow.el +++ b/lisp/follow.el @@ -118,7 +118,7 @@ ;; (setq pixel-vertical-clip-threshold 30) -;; The correct way to cofigurate Follow mode, or any other mode for +;; The correct way to configurate Follow mode, or any other mode for ;; that matter, is to create one or more functions that do ;; whatever you would like to do. These functions are then added to ;; a hook. @@ -189,7 +189,7 @@ ;; positions in the text? Here are two simple methods to use: ;; ;; 1) Use multiple frames; `follow' mode only affects windows displayed -;; in the same frame. (My apoligies to you who can't use frames.) +;; in the same frame. (My apologies to you who can't use frames.) ;; ;; 2) Bind `follow-mode' to key so you can turn it off whenever ;; you want to view two locations. Of course, `follow' mode can @@ -209,15 +209,15 @@ ;; ;; Follow mode does this in three places: ;; 1) After each user command. -;; 2) After a process output has been perfomed. +;; 2) After a process output has been performed. ;; 3) When a scrollbar has been moved. ;; ;; This will cover most situations. (Let me know if there are other ;; situations that should be covered.) ;; ;; Note that only the selected window is checked, for the reason of -;; efficiency and code complexity. (I.e. it is possible to make a -;; non-selected windows unaligned. It will, however, pop right back +;; efficiency and code complexity. (I.e. it is possible to make a +;; non-selected window unaligned. It will, however, pop right back ;; when it is selected.) ;;}}} @@ -244,7 +244,7 @@ ;; (funcall (symbol-function 'set) 'bar ...) ;; ;; Note: When this file is interpreted, `eval-when-compile' is -;; evaluted. Since it doesn't hurt to evaluate it, but it is a bit +;; evaluated. Since it doesn't hurt to evaluate it, but it is a bit ;; annoying, we test if the byte-compiler has been loaded. This can, ;; of course, lead to some occasional unintended evaluation... ;; @@ -456,7 +456,7 @@ Used by `follow-window-size-change'.") ;; the variable is not set. (defsubst follow-debug-message (&rest args) - "Like message, but only active when `follow-debug' is non-nil." + "Like `message', but only active when `follow-debug' is non-nil." (if (and (boundp 'follow-debug) follow-debug) (apply 'message args))) @@ -1000,7 +1000,7 @@ Note that this handles the case when the cache has been set to nil." res)) -;; Make sure WIN always starts at the beginning of an whole screen +;; Make sure WIN always starts at the beginning of a whole screen ;; line. If WIN is not aligned the start is updated which probably ;; will lead to a redisplay of the screen later on. ;; @@ -1057,8 +1057,8 @@ Return the selected window." win)) -;; Lets select a window showing the end. Make sure we only select it if it -;; it wasn't just moved here. (i.e. M-> shall not unconditionally place +;; Lets select a window showing the end. Make sure we only select it if +;; it wasn't just moved here. (I.e. M-> shall not unconditionally place ;; the point in the selected window.) ;; ;; (Compatibility cludge: in Emacs `window-end' is equal to `point-max'; @@ -1134,7 +1134,7 @@ Otherwise, return nil." "Reposition the WINDOWS around WIN. Should the point be too close to the roof we redisplay everything from the top. WINDOWS should contain a list of windows to -redisplay, it is assumed that WIN is a member of the list. +redisplay; it is assumed that WIN is a member of the list. Should WINDOWS be nil, the windows displaying the same buffer as WIN, in the current frame, are used. Should WIN be nil, the selected window is used. @@ -1231,7 +1231,7 @@ should be a member of WINDOWS, starts at position START." (setq done t res (point))) ((= win-start start) ; Perfect match, use this value (setq done t res (point))) - ((< win-start start) ; Walked to far, use preious result + ((< win-start start) ; Walked to far, use previous result (setq done t)) (t ; Store result for next iteration (setq res (point)))))) @@ -1241,12 +1241,12 @@ should be a member of WINDOWS, starts at position START." ;;{{{ Avoid tail recenter ;; This sets the window internal flag `force_start'. The effect is that -;; windows only displaying the tail isn't recentered. +;; windows only displaying the tail aren't recentered. ;; Has to be called before every redisplay... (Great isn't it?) ;; ;; XEmacs doesn't recenter the tail, GOOD! ;; -;; A window displaying only the tail, is a windows whose +;; A window displaying only the tail, is a window whose ;; window-start position is equal to (point-max) of the buffer it ;; displays. ;; @@ -1487,12 +1487,12 @@ non-first windows in Follow mode." ;;;; Scroll-bar support code. ;; Why is it needed? Well, if the selected window is in follow mode, -;; all its follower stick to it blindly. If one of them is scrolled, +;; all its followers stick to it blindly. If one of them is scrolled, ;; it immediately returns to the original position when the mouse is ;; released. If the selected window is not a follower of the dragged ;; window the windows will be unaligned. -;; The advices doesn't get compiled. Aestetically, this might be a +;; The advices don't get compiled. Aesthetically, this might be a ;; problem but in practical life it isn't. ;; Discussion: Now when the other windows in the chain follow the @@ -1700,8 +1700,8 @@ magic stuff before the real process filter is called." ;;}}} ;;{{{ Start/stop interception of processes. -;; Normally, all new processed are intercepted by our `set-process-filter'. -;; This is needed to intercept old processed that were started before we were +;; Normally, all new processes are intercepted by our `set-process-filter'. +;; This is needed to intercept old processes that were started before we were ;; loaded, and processes we have forgotten by calling ;; `follow-stop-intercept-process-output'. @@ -1749,7 +1749,7 @@ report this using the `report-emacs-bug' function." ;; The following section is a naive method to make buffers with ;; process output to work with Follow mode. Whenever the start of the -;; window displaying the buffer is moved, we moves it back to its +;; window displaying the buffer is moved, we move it back to its ;; original position and try to select a new window. (If we fail, ;; the normal redisplay functions of Emacs will scroll it right ;; back!) @@ -1767,7 +1767,7 @@ report this using the `report-emacs-bug' function." ;; If input is pending, the `sit-for' below won't redraw the ;; display. In that case, calling `follow-avoid-tail-recenter' may - ;; provoke the process hadnling code to sceduling a redisplay. + ;; provoke the process handling code to schedule a redisplay. ;(or (input-pending-p) ; (follow-avoid-tail-recenter)) @@ -1788,7 +1788,7 @@ report this using the `report-emacs-bug' function." (inhibit-read-only t)) (save-excursion (goto-char (process-mark proc)) - ;; `insert-before-markers' just in case the users next + ;; `insert-before-markers' just in case the user's next ;; command is M-y. (insert-before-markers output) (set-marker (process-mark proc) (point))) @@ -1848,7 +1848,7 @@ report this using the `report-emacs-bug' function." (t (follow-debug-message "filter: nothing"))) - ;; Here we have slected a window. Make sure the + ;; Here we have selected a window. Make sure the ;; windows are aligned and the point is visible ;; in the selected window. (if (and (not (follow-pos-visible @@ -1866,7 +1866,7 @@ report this using the `report-emacs-bug' function." ;; return to the original window. (if return-to-orig-win (select-window orig-win)) - ;; Restore the orignal buffer, unless the filter explicitly + ;; Restore the original buffer, unless the filter explicitly ;; changed buffer or killed the old buffer. (if (and (eq buf (current-buffer)) (buffer-name old-buffer)) diff --git a/lisp/gnus/ChangeLog.2 b/lisp/gnus/ChangeLog.2 index 4882032f284..779c84296f4 100644 --- a/lisp/gnus/ChangeLog.2 +++ b/lisp/gnus/ChangeLog.2 @@ -9243,7 +9243,7 @@ (nnmaildir--with-nntp-buffer, nnmaildir--with-work-buffer, nnmaildir--with-nov-buffer, nnmaildir--with-move-buffer, nnmaildir--group-ls): New macros/functions. Use them. - (nnmaildir--unlink): Evalutate argument only once. + (nnmaildir--unlink): Evaluate argument only once. 2002-03-27 Jesper Harder diff --git a/lisp/jka-cmpr-hook.el b/lisp/jka-cmpr-hook.el index fda9804bbb8..e1cf2a661ed 100644 --- a/lisp/jka-cmpr-hook.el +++ b/lisp/jka-cmpr-hook.el @@ -340,7 +340,7 @@ Return the new status of auto compression (non-nil means on)." (t (jka-compr-uninstall))))) (defmacro with-auto-compression-mode (&rest body) - "Evalute BODY with automatic file compression and uncompression enabled." + "Evaluate BODY with automatic file compression and uncompression enabled." (declare (indent 0)) (let ((already-installed (make-symbol "already-installed"))) `(let ((,already-installed (jka-compr-installed-p))) diff --git a/lisp/winner.el b/lisp/winner.el index e5855ad8aac..70038362c2e 100644 --- a/lisp/winner.el +++ b/lisp/winner.el @@ -145,7 +145,7 @@ You may want to include buffer names such as *Help*, *Apropos*, ;;; Saved configurations -;; This variable contains the window cofiguration rings. +;; This variable contains the window configuration rings. ;; The key in this alist is the frame. (defvar winner-ring-alist nil) diff --git a/src/ChangeLog.6 b/src/ChangeLog.6 index d7903568102..f9372aa666a 100644 --- a/src/ChangeLog.6 +++ b/src/ChangeLog.6 @@ -4599,7 +4599,7 @@ 1995-08-14 Erik Naggum - * emacs.c (standard_args): Add option --eval to evalute an + * emacs.c (standard_args): Add option --eval to evaluate an expression on the command line and print the result. 1995-08-14 Richard Stallman diff --git a/test/eshell.el b/test/eshell.el index 3b392e84c24..8a9e62a759a 100644 --- a/test/eshell.el +++ b/test/eshell.el @@ -396,7 +396,7 @@ (eshell-command-result-p "+ ${+ 1 2} 3" "6\n")) (eshell-deftest var interp-lisp - "Interpolate Lisp form evalution" + "Interpolate Lisp form evaluation" (eshell-command-result-p "+ $(+ 1 2) 3" "6\n")) (eshell-deftest var interp-concat From 8bdfa0649baea761588c1c9a741570689cecc66c Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Wed, 13 Jul 2011 21:40:30 -0400 Subject: [PATCH 37/38] Adapt 2011-07-05 switch-to-buffer changes to new switch-to-buffer * lisp/bindings.el (mode-line-other-buffer): * lisp/bookmark.el (bookmark-bmenu-2-window): * lisp/bs.el (bs-cycle-next, bs-cycle-previous): * lisp/net/tramp-cmds.el (tramp-append-tramp-buffers): Revert to using switch-to-buffer. * lisp/net/tramp-compat.el (tramp-compat-pop-to-buffer-same-window): Deleted. --- lisp/ChangeLog | 11 +++++++++++ lisp/bindings.el | 3 +-- lisp/bookmark.el | 3 +-- lisp/bs.el | 6 ++---- lisp/net/tramp-cmds.el | 4 ++-- lisp/net/tramp-compat.el | 9 --------- 6 files changed, 17 insertions(+), 19 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4aa24d499e2..1778fa9bc97 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2011-07-14 Chong Yidong + + * bindings.el (mode-line-other-buffer): + * bookmark.el (bookmark-bmenu-2-window): + * bs.el (bs-cycle-next, bs-cycle-previous): + * net/tramp-cmds.el (tramp-append-tramp-buffers): Revert to using + switch-to-buffer. + + * net/tramp-compat.el (tramp-compat-pop-to-buffer-same-window): + Deleted. + 2011-07-14 Juanma Barranquero * follow.el (follow-debug-message, follow-redisplay): diff --git a/lisp/bindings.el b/lisp/bindings.el index 57601637ed6..3d7135c16de 100644 --- a/lisp/bindings.el +++ b/lisp/bindings.el @@ -471,8 +471,7 @@ Like `bury-buffer', but temporarily select EVENT's window." (defun mode-line-other-buffer () "\ Switch to the most recently selected buffer other than the current one." (interactive) - (with-no-warnings ; We really do want to call `switch-to-buffer' here. - (switch-to-buffer (other-buffer)))) + (switch-to-buffer (other-buffer) nil t)) (defun mode-line-next-buffer (event) "Like `next-buffer', but temporarily select EVENT's window." diff --git a/lisp/bookmark.el b/lisp/bookmark.el index 9f90ecedc4d..bb7ad153e8b 100644 --- a/lisp/bookmark.el +++ b/lisp/bookmark.el @@ -1841,8 +1841,7 @@ With a prefix arg, prompts for a file to save them in." (menu (current-buffer)) (pop-up-windows t)) (delete-other-windows) - (with-no-warnings ; We really do want to call `switch-to-buffer' here. - (switch-to-buffer (other-buffer))) + (switch-to-buffer (other-buffer) nil t) (bookmark--jump-via bmrk 'pop-to-buffer) (bury-buffer menu))) diff --git a/lisp/bs.el b/lisp/bs.el index c7326eedd26..49ffb3f822c 100644 --- a/lisp/bs.el +++ b/lisp/bs.el @@ -1215,8 +1215,7 @@ by buffer configuration `bs-cycle-configuration-name'." ;; We don't want the frame iconified if the only window in the frame ;; happens to be dedicated. (bury-buffer (current-buffer)) - (with-no-warnings ; We really do want to call `switch-to-buffer' here. - (switch-to-buffer next)) + (switch-to-buffer next nil t) (setq bs--cycle-list (append (cdr cycle-list) (list (car cycle-list)))) (bs-message-without-log "Next buffers: %s" @@ -1245,8 +1244,7 @@ by buffer configuration `bs-cycle-configuration-name'." bs--cycle-list))) (prev-buffer (car tupel)) (cycle-list (cdr tupel))) - (with-no-warnings ; We really do want to call `switch-to-buffer' here. - (switch-to-buffer prev-buffer)) + (switch-to-buffer prev-buffer nil t) (setq bs--cycle-list (append (last cycle-list) (reverse (cdr (reverse cycle-list))))) (bs-message-without-log "Previous buffers: %s" diff --git a/lisp/net/tramp-cmds.el b/lisp/net/tramp-cmds.el index f20040e8a9a..fcf523a7068 100644 --- a/lisp/net/tramp-cmds.el +++ b/lisp/net/tramp-cmds.el @@ -308,7 +308,7 @@ buffer in your bug report. ;; There is at least one Tramp buffer. (when buffer-list - (tramp-compat-pop-to-buffer-same-window (list-buffers-noselect nil)) + (switch-to-buffer (list-buffers-noselect nil)) (delete-other-windows) (setq buffer-read-only nil) (goto-char (point-min)) @@ -343,7 +343,7 @@ the debug buffer(s).") ;; OK, let's send. First we delete the buffer list. (progn (kill-buffer nil) - (tramp-compat-pop-to-buffer-same-window curbuf) + (switch-to-buffer curbuf) (goto-char (point-max)) (insert "\n\ This is a special notion of the `gnus/message' package. If you diff --git a/lisp/net/tramp-compat.el b/lisp/net/tramp-compat.el index e7ea4354b51..460c9f0e118 100644 --- a/lisp/net/tramp-compat.el +++ b/lisp/net/tramp-compat.el @@ -502,15 +502,6 @@ EOL-TYPE can be one of `dos', `unix', or `mac'." "`dos', `unix', or `mac'"))))) (t (error "Can't change EOL conversion -- is MULE missing?")))) -;; `pop-to-buffer-same-window' has been introduced with Emacs 24.1. -(defun tramp-compat-pop-to-buffer-same-window - (&optional buffer-or-name norecord label) - "Pop to buffer specified by BUFFER-OR-NAME in the selected window." - (if (fboundp 'pop-to-buffer-same-window) - (tramp-compat-funcall - 'pop-to-buffer-same-window buffer-or-name norecord label) - (tramp-compat-funcall 'switch-to-buffer buffer-or-name norecord))) - (add-hook 'tramp-unload-hook (lambda () (unload-feature 'tramp-compat 'force))) From 27fa387ad10e6a5639de1ab08e7559c06e9d802d Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Wed, 13 Jul 2011 21:58:51 -0400 Subject: [PATCH 38/38] * bindings.el: Add advertised binding for set-mark-command (Bug#5772). --- lisp/ChangeLog | 5 +++++ lisp/bindings.el | 2 ++ 2 files changed, 7 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1778fa9bc97..6d652931328 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-07-14 Chong Yidong + + * bindings.el: Add advertised binding for set-mark-command + (Bug#5772). + 2011-07-14 Chong Yidong * bindings.el (mode-line-other-buffer): diff --git a/lisp/bindings.el b/lisp/bindings.el index 3d7135c16de..c4f9369219a 100644 --- a/lisp/bindings.el +++ b/lisp/bindings.el @@ -849,6 +849,8 @@ if `inhibit-field-text-motion' is non-nil." (define-key global-map "\C-@" 'set-mark-command) ;; Many people are used to typing C-SPC and getting C-@. (define-key global-map [?\C- ] 'set-mark-command) +(put 'set-mark-command :advertised-binding [?\C- ]) + (define-key ctl-x-map "\C-x" 'exchange-point-and-mark) (define-key ctl-x-map "\C-@" 'pop-global-mark) (define-key ctl-x-map [?\C- ] 'pop-global-mark)