From 71d73c9c284c7a617f488c00c1fe0a923d553ebd Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sat, 9 Apr 2011 15:57:47 -0400 Subject: [PATCH 01/16] Image mode doc fixes (Bug#8098). * lisp/image-mode.el (image-type, image-mode-map, image-minor-mode-map) (image-toggle-display): Doc fixes. --- lisp/ChangeLog | 5 +++++ lisp/image-mode.el | 14 +++++++------- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8f24803e3e9..f85300264ff 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-04-09 Chong Yidong + + * image-mode.el (image-type, image-mode-map, image-minor-mode-map) + (image-toggle-display): + 2011-04-06 Juanma Barranquero Backport revno:103823 and revno:103824 from trunk. diff --git a/lisp/image-mode.el b/lisp/image-mode.el index 191e347330d..9ef43442980 100644 --- a/lisp/image-mode.el +++ b/lisp/image-mode.el @@ -304,8 +304,7 @@ This function assumes the current frame has only one window." ;;; Image Mode setup (defvar image-type nil - "Current image type. -This variable is used to display the current image type in the mode line.") + "The image type for the current Image mode buffer.") (make-variable-buffer-local 'image-type) (defvar image-mode-previous-major-mode nil @@ -329,13 +328,13 @@ This variable is used to display the current image type in the mode line.") (define-key map [remap beginning-of-buffer] 'image-bob) (define-key map [remap end-of-buffer] 'image-eob) map) - "Major mode keymap for viewing images in Image mode.") + "Mode keymap for `image-mode'.") (defvar image-minor-mode-map (let ((map (make-sparse-keymap))) (define-key map "\C-c\C-c" 'image-toggle-display) map) - "Minor mode keymap for viewing images as text in Image mode.") + "Mode keymap for `image-minor-mode'.") (defvar bookmark-make-record-function) @@ -521,9 +520,10 @@ was inserted." (message "Repeat this command to go back to displaying the file as text")))) (defun image-toggle-display () - "Start or stop displaying an image file as the actual image. -This command toggles between `image-mode-as-text' showing the text of -the image file and `image-mode' showing the image as an image." + "Toggle between image and text display. +If the current buffer is displaying an image file as an image, +call `image-mode-as-text' to switch to text. Otherwise, display +the image by calling `image-mode'." (interactive) (if (image-get-display-property) (image-mode-as-text) From 6395aab9034182b316869c56ee82241adb7a76eb Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sat, 9 Apr 2011 16:29:22 -0400 Subject: [PATCH 02/16] Fix last change. --- lisp/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index f85300264ff..9f7577fa829 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,7 +1,7 @@ 2011-04-09 Chong Yidong * image-mode.el (image-type, image-mode-map, image-minor-mode-map) - (image-toggle-display): + (image-toggle-display): Doc fix. 2011-04-06 Juanma Barranquero From 3ad8bad03884c5e3a1609083973997abe1feeb8c Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sat, 9 Apr 2011 22:10:52 -0400 Subject: [PATCH 03/16] Handle deferred `event-kind' property when using unread-command-events. * src/mouse.el (mouse-drag-mode-line-1): Make sure that if we push mouse-2 into unread-command-events, it is interpreted correctly. --- lisp/ChangeLog | 5 +++++ lisp/mouse.el | 3 +++ 2 files changed, 8 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9f7577fa829..a2ed50e4b6f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-04-10 Chong Yidong + + * mouse.el (mouse-drag-mode-line-1): Make sure that if we push + mouse-2 into unread-command-events, it is interpreted correctly. + 2011-04-09 Chong Yidong * image-mode.el (image-type, image-mode-map, image-minor-mode-map) diff --git a/lisp/mouse.el b/lisp/mouse.el index bed4776c135..628f900e886 100644 --- a/lisp/mouse.el +++ b/lisp/mouse.el @@ -538,6 +538,9 @@ MODE-LINE-P non-nil means dragging a mode line; nil means a header line." ;; a `drag-mouse-1'. In any case `on-link' would have been nulled ;; above if there had been any significant mouse movement. (when (and on-link (eq 'mouse-1 (car-safe event))) + ;; If mouse-2 has never been done by the user, it doesn't + ;; have the necessary property to be interpreted correctly. + (put 'mouse-2 'event-kind 'mouse-click) (push (cons 'mouse-2 (cdr event)) unread-command-events)))))) (defun mouse-drag-mode-line (start-event) From 4095436808b499ffb813daac6f7cea828318faa5 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sun, 10 Apr 2011 16:43:35 -0400 Subject: [PATCH 04/16] Doc fix for left-fringe and right-fringe parameters (Bug#6930) * doc/lispref/frames.texi (Layout Parameters): Note the difference between querying and setting parameters for left-fringe and right-fringe. --- doc/lispref/ChangeLog | 6 ++++++ doc/lispref/frames.texi | 21 ++++++++++++--------- 2 files changed, 18 insertions(+), 9 deletions(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index 440159a9a58..035fee67f8d 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,3 +1,9 @@ +2011-04-10 Chong Yidong + + * frames.texi (Layout Parameters): Note the difference between + querying and setting parameters for left-fringe and right-fringe + (Bug#6930). + 2011-03-21 Stefan Monnier * minibuf.texi (Basic Completion): Be a bit more precise about the diff --git a/doc/lispref/frames.texi b/doc/lispref/frames.texi index a99782b95e1..0c81718750a 100644 --- a/doc/lispref/frames.texi +++ b/doc/lispref/frames.texi @@ -654,17 +654,20 @@ use the default width. @itemx right-fringe The default width of the left and right fringes of windows in this frame (@pxref{Fringes}). If either of these is zero, that effectively -removes the corresponding fringe. A value of @code{nil} stands for -the standard fringe width, which is the width needed to display the -fringe bitmaps. +removes the corresponding fringe. + +When you use @code{frame-parameter} to query the value of either of +these two frame parameters, the return value is always an integer. +When using @code{set-frame-parameter}, passing a @code{nil} value +imposes an actual default value of 8 pixels. The combined fringe widths must add up to an integral number of -columns, so the actual default fringe widths for the frame may be -larger than the specified values. The extra width needed to reach an -acceptable total is distributed evenly between the left and right -fringe. However, you can force one fringe or the other to a precise -width by specifying that width as a negative integer. If both widths are -negative, only the left fringe gets the specified width. +columns, so the actual default fringe widths for the frame, as +reported by @code{frame-parameter}, may be larger than what you +specify. Any extra width is distributed evenly between the left and +right fringe. However, you can force one fringe or the other to a +precise width by specifying that width as a negative integer. If both +widths are negative, only the left fringe gets the specified width. @item menu-bar-lines The number of lines to allocate at the top of the frame for a menu From 7e735aaf4d422be1c3bdf6a72e0ce6043a3e2cdf Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sun, 10 Apr 2011 16:52:31 -0400 Subject: [PATCH 05/16] Fix for what-page (Bug#6825). * textmodes/page.el (what-page): Use line-number-at-pos to calculate line number. --- lisp/ChangeLog | 5 +++++ lisp/textmodes/page.el | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index a2ed50e4b6f..c89bb3f281a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-04-10 Stephen Berman + + * textmodes/page.el (what-page): Use line-number-at-pos to + calculate line number (Bug#6825). + 2011-04-10 Chong Yidong * mouse.el (mouse-drag-mode-line-1): Make sure that if we push diff --git a/lisp/textmodes/page.el b/lisp/textmodes/page.el index d71e20030ff..a758a9ba998 100644 --- a/lisp/textmodes/page.el +++ b/lisp/textmodes/page.el @@ -156,9 +156,9 @@ thus showing a page other than the one point was originally in." (if (= (match-beginning 0) (match-end 0)) (forward-char 1)) (setq count (1+ count))) - (message "Page %d, line %d" - count - (1+ (count-lines (point) opoint))))))) + (message "Page %d, line %d" count (line-number-at-pos opoint)))))) + + ;;; Place `provide' at end of file. (provide 'page) From fde4eb868f9ec91cb3a281f798da2c0ebdadd5a3 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sun, 10 Apr 2011 16:55:52 -0400 Subject: [PATCH 06/16] * src/buffer.c (syms_of_buffer): Doc fix (Bug#6902). --- src/ChangeLog | 4 ++++ src/buffer.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 570a55ec2a2..3c6d4fc8841 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2011-04-10 Chong Yidong + + * buffer.c (syms_of_buffer): Doc fix (Bug#6902). + 2011-04-08 Chong Yidong * ftfont.c (get_adstyle_property, ftfont_pattern_entity): Use diff --git a/src/buffer.c b/src/buffer.c index e7759cb5255..076495cfc64 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -5746,7 +5746,8 @@ Linefeed indents to this column in Fundamental mode. */); DEFVAR_PER_BUFFER ("tab-width", ¤t_buffer->tab_width, make_number (LISP_INT_TAG), - doc: /* *Distance between tab stops (for display of tab characters), in columns. */); + doc: /* *Distance between tab stops (for display of tab characters), in columns. +This should be an integer greater than zero. */); DEFVAR_PER_BUFFER ("ctl-arrow", ¤t_buffer->ctl_arrow, Qnil, doc: /* *Non-nil means display control chars with uparrow. From 6f21a3198d25844445ab58a5f08d968197e5ea4e Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sun, 10 Apr 2011 17:07:40 -0400 Subject: [PATCH 07/16] Fix completion-auto-help/icomplete-mode bad interaction (Bug#5849). * minibuffer.el (completion--do-completion): Avoid the "Next char not unique" prompt if icomplete-mode is enabled. --- lisp/ChangeLog | 5 +++++ lisp/minibuffer.el | 7 ++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c89bb3f281a..cbfbd2b71f1 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-04-10 Chong Yidong + + * minibuffer.el (completion--do-completion): Avoid the "Next char + not unique" prompt if icomplete-mode is enabled (Bug#5849). + 2011-04-10 Stephen Berman * textmodes/page.el (what-page): Use line-number-at-pos to diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 338ab4e281e..adbb9a6c539 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -574,9 +574,10 @@ E = after completion we now have an Exact match. ;; Show the completion table, if requested. (cond ((not exact) - (if (case completion-auto-help - (lazy (eq this-command last-command)) - (t completion-auto-help)) + (if (cond (icomplete-mode t) + ((eq completion-auto-help 'lazy) + (eq this-command last-command)) + (t completion-auto-help)) (minibuffer-completion-help) (minibuffer-message "Next char not unique"))) ;; If the last exact completion and this one were the same, it From 300f9fca551d3aa024ff24b85e6ab7f0ae49ae03 Mon Sep 17 00:00:00 2001 From: Samuel Thibault Date: Sun, 10 Apr 2011 18:05:04 -0400 Subject: [PATCH 08/16] Fix wait_for_termination on GNU Hurd (Bug#8467) * sysdep.c (wait_for_termination): On GNU Hurd, kill returns -1 on zombies. --- src/ChangeLog | 5 +++++ src/sysdep.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 3c6d4fc8841..f82494f8a04 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2011-04-10 Samuel Thibault (tiny change) + + * sysdep.c (wait_for_termination): On GNU Hurd, kill returns -1 on + zombies (Bug#8467). + 2011-04-10 Chong Yidong * buffer.c (syms_of_buffer): Doc fix (Bug#6902). diff --git a/src/sysdep.c b/src/sysdep.c index 1fbc0617904..3abb43f14d2 100644 --- a/src/sysdep.c +++ b/src/sysdep.c @@ -411,7 +411,7 @@ wait_for_termination (pid) while (1) { #ifdef subprocesses -#if defined (BSD_SYSTEM) || defined (HPUX) +#if (defined (BSD_SYSTEM) || defined (HPUX)) && !defined(__GNU__) /* Note that kill returns -1 even if the process is just a zombie now. But inevitably a SIGCHLD interrupt should be generated and child_sig will do wait3 and make the process go away. */ From 7ee6a1d37268f1f4b7047fc6ccad271d2ee5fd31 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 13 Apr 2011 13:50:12 +0200 Subject: [PATCH 09/16] Fix typos. --- doc/emacs/ChangeLog | 5 +++++ doc/emacs/mini.texi | 2 +- doc/emacs/screen.texi | 2 +- doc/lispref/ChangeLog | 4 ++++ doc/lispref/windows.texi | 2 +- lisp/ChangeLog.14 | 2 +- lisp/cedet/ChangeLog | 8 ++++++++ lisp/cedet/ede/pconf.el | 4 ++-- lisp/cedet/ede/proj-comp.el | 4 ++-- lisp/cedet/ede/proj-elisp.el | 8 ++++---- lisp/cedet/ede/proj-scheme.el | 2 +- src/dispextern.h | 4 ++-- src/msdos.c | 2 +- 13 files changed, 33 insertions(+), 16 deletions(-) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index edd66bddfdf..4923316c4db 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -1,3 +1,8 @@ +2011-04-13 Juanma Barranquero + + * mini.texi (Minibuffer Edit): + * screen.texi (Mode Line): Fix typo. + 2011-03-26 Chong Yidong * display.texi (Auto Scrolling): Fix scroll-up/scroll-down confusion. diff --git a/doc/emacs/mini.texi b/doc/emacs/mini.texi index bf7e4469dd9..b7bda61e238 100644 --- a/doc/emacs/mini.texi +++ b/doc/emacs/mini.texi @@ -165,7 +165,7 @@ however: for instance, you cannot split it. @xref{Windows}. @vindex resize-mini-windows Normally, the minibuffer window occupies a single screen line. However, if you add two or more lines' worth of text into the -minibuffer, it expands automatically to accomodate the text. The +minibuffer, it expands automatically to accommodate the text. The variable @code{resize-mini-windows} controls the resizing of the minibuffer. The default value is @code{grow-only}, which means the behavior we have just described. If the value is @code{t}, the diff --git a/doc/emacs/screen.texi b/doc/emacs/screen.texi index c3b2e178278..f12c03e1abf 100644 --- a/doc/emacs/screen.texi +++ b/doc/emacs/screen.texi @@ -260,7 +260,7 @@ the buffer. Minor modes are optional editing modes that provide additional features on top of the major mode. @xref{Minor Modes}. Some features are listed together with the minor modes whenever they -are turned on, even through they are not really minor modes. +are turned on, even though they are not really minor modes. @samp{Narrow} means that the buffer being displayed has editing restricted to only a portion of its text (@pxref{Narrowing}). @samp{Def} means that a keyboard macro is currently being defined diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index 035fee67f8d..fc57e20e612 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,3 +1,7 @@ +2011-04-13 Juanma Barranquero + + * windows.texi (Choosing Window): Fix typo. + 2011-04-10 Chong Yidong * frames.texi (Layout Parameters): Note the difference between diff --git a/doc/lispref/windows.texi b/doc/lispref/windows.texi index 77fd44fb162..f17fc3c718b 100644 --- a/doc/lispref/windows.texi +++ b/doc/lispref/windows.texi @@ -1015,7 +1015,7 @@ a window only if the space taken up by that window can accommodate two windows one above the other that are both at least @code{window-min-height} lines tall. Moreover, if the window that shall be split has a mode line, @code{split-window-sensibly} does not split -the window unless the new window can accomodate a mode line too. +the window unless the new window can accommodate a mode line too. @end defopt @defopt split-width-threshold diff --git a/lisp/ChangeLog.14 b/lisp/ChangeLog.14 index cf08fd0ae44..54d41f4d0ed 100644 --- a/lisp/ChangeLog.14 +++ b/lisp/ChangeLog.14 @@ -4283,7 +4283,7 @@ (proced-descend): New variable. (proced-sort): New arg descend. (proced-sort-interactive): Repeated calls toggle sort order. - (proced-format): Accomodate changes of proced-format-alist. + (proced-format): Accommodate changes of proced-format-alist. Undefined attributes are displayed as "?". (proced-process-attributes): New optional arg pid-list. Ignore processes with empty attribute list. diff --git a/lisp/cedet/ChangeLog b/lisp/cedet/ChangeLog index 2d0cbb8159b..d8a4209cc98 100644 --- a/lisp/cedet/ChangeLog +++ b/lisp/cedet/ChangeLog @@ -1,3 +1,11 @@ +2011-04-13 Juanma Barranquero + + * ede/pconf.el (ede-proj-tweak-autoconf, ede-proj-flush-autoconf): + * ede/proj-comp.el (ede-proj-tweak-autoconf, ede-proj-flush-autoconf): + * ede/proj-elisp.el (ede-proj-tweak-autoconf, ede-proj-flush-autoconf) + (ede-proj-tweak-autoconf, ede-proj-flush-autoconf): + * ede/proj-scheme.el (ede-proj-tweak-autoconf): Fix typos in docstrings. + 2011-03-07 Chong Yidong * Version 23.3 released. diff --git a/lisp/cedet/ede/pconf.el b/lisp/cedet/ede/pconf.el index a2258c1d16f..77299c7eb39 100644 --- a/lisp/cedet/ede/pconf.el +++ b/lisp/cedet/ede/pconf.el @@ -160,7 +160,7 @@ don't do it. A value of nil means to just do it.") (ede-proj-configure-synchronize this)) (defmethod ede-proj-tweak-autoconf ((this ede-proj-target)) - "Tweak the configure file (current buffer) to accomodate THIS." + "Tweak the configure file (current buffer) to accommodate THIS." ;; Check the compilers belonging to THIS, and call the autoconf ;; setup for those compilers. (mapc 'ede-proj-tweak-autoconf (ede-proj-compilers this)) @@ -168,7 +168,7 @@ don't do it. A value of nil means to just do it.") ) (defmethod ede-proj-flush-autoconf ((this ede-proj-target)) - "Flush the configure file (current buffer) to accomodate THIS. + "Flush the configure file (current buffer) to accommodate THIS. By flushing, remove any cruft that may be in the file. Subsequent calls to `ede-proj-tweak-autoconf' can restore items removed by flush." nil) diff --git a/lisp/cedet/ede/proj-comp.el b/lisp/cedet/ede/proj-comp.el index 9ec5cc64306..8757a6a1403 100644 --- a/lisp/cedet/ede/proj-comp.el +++ b/lisp/cedet/ede/proj-comp.el @@ -236,7 +236,7 @@ This will prevent rules from creating duplicate variables or rules." ;;; Methods: (defmethod ede-proj-tweak-autoconf ((this ede-compilation-program)) - "Tweak the configure file (current buffer) to accomodate THIS." + "Tweak the configure file (current buffer) to accommodate THIS." (mapcar (lambda (obj) (cond ((stringp obj) @@ -248,7 +248,7 @@ This will prevent rules from creating duplicate variables or rules." (oref this autoconf))) (defmethod ede-proj-flush-autoconf ((this ede-compilation-program)) - "Flush the configure file (current buffer) to accomodate THIS." + "Flush the configure file (current buffer) to accommodate THIS." nil) (defmacro proj-comp-insert-variable-once (varname &rest body) diff --git a/lisp/cedet/ede/proj-elisp.el b/lisp/cedet/ede/proj-elisp.el index cff68debef0..1182c41128c 100644 --- a/lisp/cedet/ede/proj-elisp.el +++ b/lisp/cedet/ede/proj-elisp.el @@ -214,7 +214,7 @@ is found, such as a `-version' variable, or the standard header." (error "Don't know how to update load path")))) (defmethod ede-proj-tweak-autoconf ((this ede-proj-target-elisp)) - "Tweak the configure file (current buffer) to accomodate THIS." + "Tweak the configure file (current buffer) to accommodate THIS." (call-next-method) ;; Ok, now we have to tweak the autoconf provided `elisp-comp' program. (let ((ec (ede-expand-filename this "elisp-comp" 'newfile))) @@ -238,7 +238,7 @@ is found, such as a `-version' variable, or the standard header." (save-buffer)) ))) (defmethod ede-proj-flush-autoconf ((this ede-proj-target-elisp)) - "Flush the configure file (current buffer) to accomodate THIS." + "Flush the configure file (current buffer) to accommodate THIS." ;; Remove crufty old paths from elisp-compile (let ((ec (ede-expand-filename this "elisp-comp" 'newfile)) ) @@ -381,11 +381,11 @@ Argument THIS is the target which needs to insert an info file." ) (defmethod ede-proj-tweak-autoconf ((this ede-proj-target-elisp-autoloads)) - "Tweak the configure file (current buffer) to accomodate THIS." + "Tweak the configure file (current buffer) to accommodate THIS." (error "Autoloads not supported in autoconf yet")) (defmethod ede-proj-flush-autoconf ((this ede-proj-target-elisp-autoloads)) - "Flush the configure file (current buffer) to accomodate THIS." + "Flush the configure file (current buffer) to accommodate THIS." nil) (provide 'ede/proj-elisp) diff --git a/lisp/cedet/ede/proj-scheme.el b/lisp/cedet/ede/proj-scheme.el index 64a17503684..e3d99129d31 100644 --- a/lisp/cedet/ede/proj-scheme.el +++ b/lisp/cedet/ede/proj-scheme.el @@ -41,7 +41,7 @@ "This target consists of scheme files.") (defmethod ede-proj-tweak-autoconf ((this ede-proj-target-scheme)) - "Tweak the configure file (current buffer) to accomodate THIS." + "Tweak the configure file (current buffer) to accommodate THIS." (autoconf-insert-new-macro "AM_INIT_GUILE_MODULE")) (provide 'ede/proj-scheme) diff --git a/src/dispextern.h b/src/dispextern.h index 8e19bdae197..8ae5e23fa97 100644 --- a/src/dispextern.h +++ b/src/dispextern.h @@ -63,7 +63,7 @@ typedef HDC XImagePtr_or_DC; #ifdef HAVE_NS #include "nsgui.h" -/* following typedef needed to accomodate the MSDOS port, believe it or not */ +/* Following typedef needed to accommodate the MSDOS port, believe it or not. */ typedef struct ns_display_info Display_Info; typedef Pixmap XImagePtr; typedef XImagePtr XImagePtr_or_DC; @@ -368,7 +368,7 @@ struct glyph doesn't have a glyph in a font. */ unsigned glyph_not_available_p : 1; - + /* Non-zero means don't display cursor here. */ unsigned avoid_cursor_p : 1; diff --git a/src/msdos.c b/src/msdos.c index 87b857bbb9d..c176680bf9d 100644 --- a/src/msdos.c +++ b/src/msdos.c @@ -960,7 +960,7 @@ IT_set_face (int face) /* According to RBIL (INTERRUP.A, V-1000), 160 is the maximum possible width of a DOS display in any known text mode. We multiply by 2 to - accomodate the screen attribute byte. */ + accommodate the screen attribute byte. */ #define MAX_SCREEN_BUF 160*2 Lisp_Object Vdos_unsupported_char_glyph; From c17819f4cd58df1a0a17593152e32fee70cc90f7 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Wed, 13 Apr 2011 14:19:23 -0400 Subject: [PATCH 10/16] * xdisp.c (init_xdisp): Initialize echo_area_window (Bug#6451). --- src/ChangeLog | 4 ++++ src/xdisp.c | 1 + 2 files changed, 5 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index f82494f8a04..cfa9426c882 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2011-04-13 Chong Yidong + + * xdisp.c (init_xdisp): Initialize echo_area_window (Bug#6451). + 2011-04-10 Samuel Thibault (tiny change) * sysdep.c (wait_for_termination): On GNU Hurd, kill returns -1 on diff --git a/src/xdisp.c b/src/xdisp.c index ade95cf3d62..c42410b9f9f 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -25139,6 +25139,7 @@ init_xdisp () mini_w = XWINDOW (minibuf_window); root_window = FRAME_ROOT_WINDOW (XFRAME (WINDOW_FRAME (mini_w))); + echo_area_window = minibuf_window; if (!noninteractive) { From 6470c3c6a99ed0d1eae68bbbe1d0a3f6ca8b4983 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 15 Apr 2011 04:56:50 +0200 Subject: [PATCH 11/16] lisp/mouse-drag.el (mouse-drag-throw): Fix typo in docstring. --- lisp/ChangeLog | 4 ++++ lisp/mouse-drag.el | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index cbfbd2b71f1..13561921b1f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2011-04-15 Juanma Barranquero + + * mouse-drag.el (mouse-drag-throw): Fix typo in docstring. + 2011-04-10 Chong Yidong * minibuffer.el (completion--do-completion): Avoid the "Next char diff --git a/lisp/mouse-drag.el b/lisp/mouse-drag.el index c892501fe53..84a680bfcde 100644 --- a/lisp/mouse-drag.el +++ b/lisp/mouse-drag.el @@ -195,7 +195,7 @@ from the original mouse click to the current mouse location. Try it; you'll like it. It's easier to observe than to explain. If the mouse is clicked and released in the same place of time we -assume that the user didn't want to scdebugroll but wanted to whatever +assume that the user didn't want to scroll but wanted to whatever mouse-2 used to do, so we pass it through. Throw scrolling was inspired (but is not identical to) the \"hand\" From 97a9309556465557781fb95b2bc5a44f7b4520b9 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Mon, 18 Apr 2011 11:33:58 +0300 Subject: [PATCH 12/16] Fix a bug in time functions when timezone is changed on Windows. src/s/ms-w32.h (localtime): Redirect to sys_localtime. src/w32.c: Include . (sys_localtime): New function. --- src/ChangeLog | 7 +++++++ src/s/ms-w32.h | 1 + src/w32.c | 22 ++++++++++++++++++++++ 3 files changed, 30 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index cfa9426c882..faf9564a835 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2011-04-18 Eli Zaretskii + + * s/ms-w32.h (localtime): Redirect to sys_localtime. + + * w32.c: Include . + (sys_localtime): New function. + 2011-04-13 Chong Yidong * xdisp.c (init_xdisp): Initialize echo_area_window (Bug#6451). diff --git a/src/s/ms-w32.h b/src/s/ms-w32.h index 2b0a60cfab9..b9e57687a09 100644 --- a/src/s/ms-w32.h +++ b/src/s/ms-w32.h @@ -236,6 +236,7 @@ along with GNU Emacs. If not, see . */ #define dup2 sys_dup2 #define fopen sys_fopen #define link sys_link +#define localtime sys_localtime #define mkdir sys_mkdir #undef mktemp #define mktemp sys_mktemp diff --git a/src/w32.c b/src/w32.c index 8dbf0cf8f19..804d6d0c4bc 100644 --- a/src/w32.c +++ b/src/w32.c @@ -35,6 +35,7 @@ along with GNU Emacs. If not, see . */ #include /* for _mbspbrk */ #include #include +#include /* must include CRT headers *before* config.h */ @@ -65,6 +66,8 @@ along with GNU Emacs. If not, see . */ #undef strerror +#undef localtime + #include "lisp.h" #include @@ -1961,6 +1964,12 @@ gettimeofday (struct timeval *tv, struct timezone *tz) tv->tv_sec = tb.time; tv->tv_usec = tb.millitm * 1000L; + /* Implementation note: _ftime sometimes doesn't update the dstflag + according to the new timezone when the system timezone is + changed. We could fix that by using GetSystemTime and + GetTimeZoneInformation, but that doesn't seem necessary, since + Emacs always calls gettimeofday with the 2nd argument NULL (see + EMACS_GET_TIME). */ if (tz) { tz->tz_minuteswest = tb.timezone; /* minutes west of Greenwich */ @@ -5676,6 +5685,19 @@ sys_write (int fd, const void * buffer, unsigned int count) return nchars; } +/* The Windows CRT functions are "optimized for speed", so they don't + check for timezone and DST changes if they were last called less + than 1 minute ago (see http://support.microsoft.com/kb/821231). So + all Emacs features that repeatedly call time functions (e.g., + display-time) are in real danger of missing timezone and DST + changes. Calling tzset before each localtime call fixes that. */ +struct tm * +sys_localtime (const time_t *t) +{ + tzset (); + return localtime (t); +} + static void check_windows_init_file () { From 40c9205d587f0b0ae88c683cd523b125eeb2c39e Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 19 Apr 2011 19:11:41 -0700 Subject: [PATCH 13/16] ChangeLog whitespace fix (no need to merge to trunk). --- ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index b45615d4317..e305cb7faa1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,6 @@ 2011-03-13 Glenn Morris - * configure.in (FREETYPE_LIBS): Actually set it to something. + * configure.in (FREETYPE_LIBS): Actually set it to something. 2011-03-13 Miles Bader From 58d468b44d8e8b639e8dd13f9895516d30bcbba5 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 21 Apr 2011 04:45:31 +0200 Subject: [PATCH 14/16] lisp/play/doctor.el: Fix typos in docstrings. --- lisp/ChangeLog | 5 +++++ lisp/play/doctor.el | 16 ++++++++-------- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 13561921b1f..77c586c47fb 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2011-04-21 Juanma Barranquero + + * play/doctor.el (doc$, doctor-$, doctor-read-print, doctor-read-token) + (doctor-nounp, doctor-pronounp): Fix typos in docstrings. + 2011-04-15 Juanma Barranquero * mouse-drag.el (mouse-drag-throw): Fix typo in docstring. diff --git a/lisp/play/doctor.el b/lisp/play/doctor.el index 6a21f035cd2..fd69497dc42 100644 --- a/lisp/play/doctor.el +++ b/lisp/play/doctor.el @@ -61,11 +61,11 @@ (defun doc// (x) x) (defmacro doc$ (what) - "quoted arg form of doctor-$" + "Quoted arg form of doctor-$." (list 'doctor-$ (list 'quote what))) (defun doctor-$ (what) - "Return the car of a list, rotating the list each time" + "Return the car of a list, rotating the list each time." (let* ((vv (symbol-value what)) (first (car vv)) (ww (append (cdr vv) (list first)))) @@ -562,8 +562,8 @@ reads the sentence before point, and prints the Doctor's answer." (defun doctor-meaning (x) (get x 'doctor-meaning)) (defmacro doctor-put-meaning (symb val) - "Store the base meaning of a word on the property list." - (list 'put (list 'quote symb) ''doctor-meaning val)) + "Store the base meaning of a word on the property list." + (list 'put (list 'quote symb) ''doctor-meaning val)) (doctor-put-meaning howdy 'howdy) (doctor-put-meaning hi 'howdy) @@ -851,7 +851,7 @@ Otherwise call the Doctor to parse preceding sentence." (newline arg))) (defun doctor-read-print nil - "top level loop" + "Top level loop." (interactive) (let ((sent (doctor-readin))) (insert "\n") @@ -869,7 +869,7 @@ Otherwise call the Doctor to parse preceding sentence." sentence)) (defun doctor-read-token () - "read one word from buffer" + "Read one word from buffer." (prog1 (intern (downcase (buffer-substring (point) (progn (forward-word 1) @@ -1039,7 +1039,7 @@ the subject noun, and return the portion of the sentence following it." nil)))) (defun doctor-nounp (x) - "Returns t if the symbol argument is a noun." + "Return t if the symbol argument is a noun." (or (doctor-pronounp x) (not (or (doctor-verbp x) (equal x 'not) @@ -1047,7 +1047,7 @@ the subject noun, and return the portion of the sentence following it." (doctor-modifierp x) )) )) (defun doctor-pronounp (x) - "Returns t if the symbol argument is a pronoun." + "Return t if the symbol argument is a pronoun." (memq x '( i me mine myself we us ours ourselves ourself From c6c3212525649764708af281de3deb2d96225686 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 21 Apr 2011 14:06:01 +0200 Subject: [PATCH 15/16] lisp/play/mpuz.el: Small fixes. * play/mpuz (mpuz-silent): Doc fix. (mpuz-mode-map): Move initialization into declaration. (mpuz-put-number-on-board): Rename parameter L to COLUMNS. (mpuz-letter-to-digit, mpuz-check-all-solved, mpuz-create-buffer): Fix typos in docstrings. --- lisp/ChangeLog | 6 ++++++ lisp/play/mpuz.el | 51 +++++++++++++++-------------------------------- 2 files changed, 22 insertions(+), 35 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 77c586c47fb..7cfe6d842d9 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,11 @@ 2011-04-21 Juanma Barranquero + * play/mpuz.el (mpuz-silent): Doc fix. + (mpuz-mode-map): Move initialization into declaration. + (mpuz-put-number-on-board): Rename parameter L to COLUMNS. + (mpuz-letter-to-digit, mpuz-check-all-solved, mpuz-create-buffer): + Fix typos in docstrings. + * play/doctor.el (doc$, doctor-$, doctor-read-print, doctor-read-token) (doctor-nounp, doctor-pronounp): Fix typos in docstrings. diff --git a/lisp/play/mpuz.el b/lisp/play/mpuz.el index 32678650ab3..4c6d66b27ae 100644 --- a/lisp/play/mpuz.el +++ b/lisp/play/mpuz.el @@ -40,7 +40,7 @@ (defcustom mpuz-silent 'error "Set this to nil if you want dings on inputs. -t means never ding, and `error' means only ding on wrong input." +The value t means never ding, and `error' means only ding on wrong input." :type '(choice (const :tag "No" nil) (const :tag "Yes" t) (const :tag "If correct" error)) @@ -87,34 +87,16 @@ t means never ding, and `error' means only ding on wrong input." :type 'hook :group 'mpuz) -(defvar mpuz-mode-map nil +(defvar mpuz-mode-map + (let ((map (make-sparse-keymap))) + (mapc (lambda (ch) + (define-key map (char-to-string ch) 'mpuz-try-letter)) + "abcdefghijABCDEFGHIJ") + (define-key map "\C-g" 'mpuz-offer-abort) + (define-key map "?" 'describe-mode) + map) "Local keymap to use in Mult Puzzle.") -(if mpuz-mode-map nil - (setq mpuz-mode-map (make-sparse-keymap)) - (define-key mpuz-mode-map "a" 'mpuz-try-letter) - (define-key mpuz-mode-map "b" 'mpuz-try-letter) - (define-key mpuz-mode-map "c" 'mpuz-try-letter) - (define-key mpuz-mode-map "d" 'mpuz-try-letter) - (define-key mpuz-mode-map "e" 'mpuz-try-letter) - (define-key mpuz-mode-map "f" 'mpuz-try-letter) - (define-key mpuz-mode-map "g" 'mpuz-try-letter) - (define-key mpuz-mode-map "h" 'mpuz-try-letter) - (define-key mpuz-mode-map "i" 'mpuz-try-letter) - (define-key mpuz-mode-map "j" 'mpuz-try-letter) - (define-key mpuz-mode-map "A" 'mpuz-try-letter) - (define-key mpuz-mode-map "B" 'mpuz-try-letter) - (define-key mpuz-mode-map "C" 'mpuz-try-letter) - (define-key mpuz-mode-map "D" 'mpuz-try-letter) - (define-key mpuz-mode-map "E" 'mpuz-try-letter) - (define-key mpuz-mode-map "F" 'mpuz-try-letter) - (define-key mpuz-mode-map "G" 'mpuz-try-letter) - (define-key mpuz-mode-map "H" 'mpuz-try-letter) - (define-key mpuz-mode-map "I" 'mpuz-try-letter) - (define-key mpuz-mode-map "J" 'mpuz-try-letter) - (define-key mpuz-mode-map "\C-g" 'mpuz-offer-abort) - (define-key mpuz-mode-map "?" 'describe-mode)) - (defun mpuz-mode () "Multiplication puzzle mode. @@ -171,7 +153,7 @@ You may abort a game by typing \\\\[mpuz-offer-abort]." "A permutation from [0..9] to [0..9].") (defvar mpuz-letter-to-digit (make-vector 10 0) - "The inverse of mpuz-digit-to-letter.") + "The inverse of `mpuz-digit-to-letter'.") (defmacro mpuz-to-digit (letter) (list 'aref 'mpuz-letter-to-digit letter)) @@ -198,17 +180,16 @@ You may abort a game by typing \\\\[mpuz-offer-abort]." (defvar mpuz-board (make-vector 10 nil) "The board associates to any digit the list of squares where it appears.") -(defun mpuz-put-number-on-board (number row &rest l) +(defun mpuz-put-number-on-board (number row &rest columns) "Put (last digit of) NUMBER on ROW and COLUMNS of the puzzle board." (let (digit) - (while l + (dolist (column columns) (setq digit (% number 10) - number (/ number 10)) - (aset mpuz-board digit `((,row . ,(car l)) ,@(aref mpuz-board digit))) - (setq l (cdr l))))) + number (/ number 10)) + (aset mpuz-board digit `((,row . ,column) ,@(aref mpuz-board digit)))))) (defun mpuz-check-all-solved (&optional row col) - "Check whether all digits have been solved. Return t if yes." + "Check whether all digits have been solved. Return t if yes." (catch 'solved (let (A B1 B2 C D E squares) (and mpuz-solve-when-trivial @@ -294,7 +275,7 @@ You may abort a game by typing \\\\[mpuz-offer-abort]." "The general picture of the puzzle screen, as a string.") (defun mpuz-create-buffer () - "Create (or recreate) the puzzle buffer. Return it." + "Create (or recreate) the puzzle buffer. Return it." (let ((buf (get-buffer-create "*Mult Puzzle*")) (face '(face mpuz-text)) buffer-read-only) From be71f8100a71a5b896ef05c32f51a09a3d9e3993 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 22 Apr 2011 20:49:58 +0200 Subject: [PATCH 16/16] lisp/buff-menu.el (Buffer-menu--buffers): Fix typo in docstring. Fixes: debbugs:8535 --- lisp/ChangeLog | 4 ++++ lisp/buff-menu.el | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7cfe6d842d9..8ff0625068d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2011-04-22 Juanma Barranquero + + * buff-menu.el (Buffer-menu--buffers): Fix typo in docstring (bug#8535). + 2011-04-21 Juanma Barranquero * play/mpuz.el (mpuz-silent): Doc fix. diff --git a/lisp/buff-menu.el b/lisp/buff-menu.el index 19cc01c5144..3454f416314 100644 --- a/lisp/buff-menu.el +++ b/lisp/buff-menu.el @@ -116,7 +116,7 @@ Auto Revert Mode.") (defvar Buffer-menu--buffers nil "If non-nil, list of buffers shown in the current buffer-menu. This variable determines whether reverting the buffer lists only -this buffers. It affects both manual reverting and reverting by +these buffers. It affects both manual reverting and reverting by Auto Revert Mode.") (make-variable-buffer-local 'Buffer-menu--buffers)