Now on revision 111357. ------------------------------------------------------------ revno: 111357 committer: Daiki Ueno branch nick: trunk timestamp: Fri 2012-12-28 12:51:20 +0900 message: epg: Support pinentry-curses diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-12-27 20:42:02 +0000 +++ lisp/ChangeLog 2012-12-28 03:51:20 +0000 @@ -1,3 +1,13 @@ +2012-12-28 Daiki Ueno + + * epg.el: Support pinentry-curses. + Suggested by Werner Koch in + . + (epg-agent-file, epg-agent-mtime): New variable. + (epg--start): Record the modified time of gpg-agent socket file, + to restore Emacs frame after pinentry-curses termination. + (epg-wait-for-completion): Restore Emacs frame here. + 2012-12-27 Juri Linkov * info.el (Info-file-completions): New variable. === modified file 'lisp/epg.el' --- lisp/epg.el 2012-12-26 04:20:21 +0000 +++ lisp/epg.el 2012-12-28 03:51:20 +0000 @@ -37,6 +37,8 @@ (defvar epg-key-id nil) (defvar epg-context nil) (defvar epg-debug-buffer nil) +(defvar epg-agent-file nil) +(defvar epg-agent-mtime nil) ;; from gnupg/include/cipher.h (defconst epg-cipher-algorithm-alist @@ -1156,7 +1158,28 @@ process-connection-type (orig-mode (default-file-modes)) (buffer (generate-new-buffer " *epg*")) - process) + process + terminal-name + agent-file + (agent-mtime '(0 0 0 0))) + ;; Set GPG_TTY and TERM for pinentry-curses. Note that we can't + ;; use `terminal-name' here to get the real pty name for the child + ;; process, though /dev/fd/0" is not portable. + (with-temp-buffer + (when (= (call-process "tty" "/dev/fd/0" t) 0) + (delete-backward-char 1) + (setq terminal-name (buffer-string)))) + (when terminal-name + (setenv "GPG_TTY" terminal-name) + (setenv "TERM" "xterm")) + ;; Record modified time of gpg-agent socket to restore the Emacs + ;; frame on text terminal in `epg-wait-for-completion'. + ;; See + ;; + ;; for more details. + (when (and agent-info (string-match "\\(.*\\):[0-9]+:[0-9]+" agent-info)) + (setq agent-file (match-string 1 agent-info) + agent-mtime (or (nth 5 (file-attributes agent-file)) '(0 0 0 0)))) (if epg-debug (save-excursion (unless epg-debug-buffer @@ -1185,7 +1208,11 @@ (make-local-variable 'epg-key-id) (setq epg-key-id nil) (make-local-variable 'epg-context) - (setq epg-context context)) + (setq epg-context context) + (make-local-variable 'epg-agent-file) + (setq epg-agent-file agent-file) + (make-local-variable 'epg-agent-mtime) + (setq epg-agent-mtime agent-mtime)) (unwind-protect (progn (set-default-file-modes 448) @@ -1262,6 +1289,13 @@ (accept-process-output (epg-context-process context) 1)) ;; This line is needed to run the process-filter right now. (sleep-for 0.1) + ;; Restore Emacs frame on text terminal, when pinentry-curses has terminated. + (if (with-current-buffer (process-buffer (epg-context-process context)) + (and epg-agent-file + (> (float-time (or (nth 5 (file-attributes epg-agent-file)) + '(0 0 0 0))) + (float-time epg-agent-mtime)))) + (redraw-frame)) (epg-context-set-result-for context 'error (nreverse (epg-context-result-for context 'error)))) ------------------------------------------------------------ revno: 111356 committer: Paul Eggert branch nick: trunk timestamp: Thu 2012-12-27 19:13:47 -0800 message: Port EXTERNALLY_VISIBLE to Clang 3.2. * conf_post.h (__has_attribute): New macro. (EXTERNALLY_VISIBLE): Use it. This ports to Clang 3.2. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2012-12-27 08:21:08 +0000 +++ src/ChangeLog 2012-12-28 03:13:47 +0000 @@ -1,3 +1,9 @@ +2012-12-28 Paul Eggert + + Port EXTERNALLY_VISIBLE to Clang 3.2. + * conf_post.h (__has_attribute): New macro. + (EXTERNALLY_VISIBLE): Use it. This ports to Clang 3.2. + 2012-12-27 Glenn Morris * cygw32.c (Fcygwin_convert_file_name_to_windows) === modified file 'src/conf_post.h' --- src/conf_post.h 2012-11-14 04:55:41 +0000 +++ src/conf_post.h 2012-12-28 03:13:47 +0000 @@ -40,6 +40,10 @@ #endif #endif +#ifndef __has_attribute +# define __has_attribute(a) 0 /* non-clang */ +#endif + /* This silences a few compilation warnings on FreeBSD. */ #ifdef BSD_SYSTEM_AHB #undef BSD_SYSTEM_AHB @@ -191,7 +195,9 @@ #define NO_INLINE #endif -#if (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 1)) +#if (__clang__ \ + ? __has_attribute (externally_visible) \ + : (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 1))) #define EXTERNALLY_VISIBLE __attribute__((externally_visible)) #else #define EXTERNALLY_VISIBLE ------------------------------------------------------------ revno: 111355 author: Wolfgang Jenkner committer: Katsumi Yamaoka branch nick: trunk timestamp: Thu 2012-12-27 22:51:46 +0000 message: Gnus: Avoid `Invalid face reference: nil' messages diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2012-12-27 14:58:36 +0000 +++ lisp/gnus/ChangeLog 2012-12-27 22:51:46 +0000 @@ -1,3 +1,13 @@ +2012-12-27 Wolfgang Jenkner + + * gnus-spec.el (gnus-face-face-function): Don't use nil as no-op face + place holder since this gives `Invalid face reference: nil' messages. + Use the `default' face instead. It has the same effect here, even + though it is not no-op. + + * gnus-util.el + (gnus-put-text-property-excluding-characters-with-faces): Similarly. + 2012-12-27 Lars Ingebrigtsen * gnus-msg.el (gnus-summary-resend-message): Don't bug out on === modified file 'lisp/gnus/gnus-spec.el' --- lisp/gnus/gnus-spec.el 2012-12-25 22:12:59 +0000 +++ lisp/gnus/gnus-spec.el 2012-12-27 22:51:46 +0000 @@ -270,7 +270,7 @@ ;; Delay consing the value of the `face' property until ;; `gnus-add-text-properties' runs, since it will be modified ;; by `gnus-put-text-property-excluding-characters-with-faces'. - (list ',(symbol-value (intern (format "gnus-face-%d" type))) nil) + (list ',(symbol-value (intern (format "gnus-face-%d" type))) 'default) ;; Redundant now, but still convenient. '(gnus-face t))))) === modified file 'lisp/gnus/gnus-util.el' --- lisp/gnus/gnus-util.el 2012-12-26 13:58:54 +0000 +++ lisp/gnus/gnus-util.el 2012-12-27 22:51:46 +0000 @@ -875,7 +875,7 @@ (let ((stop (next-single-property-change beg 'face nil end))) (if (get-text-property beg 'gnus-face) (when (eq prop 'face) - (setcar (cdr (get-text-property beg 'face)) val)) + (setcar (cdr (get-text-property beg 'face)) (or val 'default))) (inline (gnus-put-text-property beg stop prop val))) (setq beg stop)))) ------------------------------------------------------------ revno: 111354 fixes bug: http://debbugs.gnu.org/12456 committer: Juri Linkov branch nick: trunk timestamp: Thu 2012-12-27 22:42:02 +0200 message: * lisp/info.el (Info-file-completions): New variable. (Info-read-node-name-1): Complete node names in the Info file when a file name is given. Call `Info-build-node-completions' with a file name. (Info-build-node-completions): Add new arg `file'. When it is non-nil, visit it in a temporary buffer and cache its completions in `Info-current-file-completions'. Move most of the function body to `Info-build-node-completions-1'. (Info-build-node-completions-1): New function with the body from `Info-build-node-completions'. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-12-27 20:09:45 +0000 +++ lisp/ChangeLog 2012-12-27 20:42:02 +0000 @@ -1,5 +1,18 @@ 2012-12-27 Juri Linkov + * info.el (Info-file-completions): New variable. + (Info-read-node-name-1): Complete node names in the Info file + when a file name is given. Call `Info-build-node-completions' + with a file name. + (Info-build-node-completions): Add new arg `file'. When it is + non-nil, visit it in a temporary buffer and cache its completions in + `Info-current-file-completions'. Move most of the function body to + `Info-build-node-completions-1'. + (Info-build-node-completions-1): New function with the body from + `Info-build-node-completions'. (Bug#12456) + +2012-12-27 Juri Linkov + * frame.el (frame-maximization-style): Remove user option. (cycle-frame-maximized): Remove function. (toggle-frame-maximized): Rewrite and bind to M-. === modified file 'lisp/info.el' --- lisp/info.el 2012-12-08 23:12:08 +0000 +++ lisp/info.el 2012-12-27 20:42:02 +0000 @@ -397,6 +397,10 @@ (defvar Info-current-file-completions nil "Cached completion list for current Info file.") +(defvar Info-file-completions nil + "Cached completion alist of visited Info files. +Each element of the alist is (FILE . COMPLETIONS)") + (defvar Info-file-supports-index-cookies nil "Non-nil if current Info file supports index cookies.") @@ -1771,12 +1775,20 @@ (substring string 1) predicate code)) - ;; If a file name was given, then any node is fair game. - ((string-match "\\`(" string) - (cond - ((eq code nil) string) - ((eq code t) nil) - (t t))) + ;; If a file name was given, complete nodes in the file. + ((string-match "\\`(\\([^)]+\\))" string) + (let ((file0 (match-string 0 string)) + (file1 (match-string 1 string)) + (node (substring string (match-end 0)))) + (completion-table-with-context + file0 + (apply-partially + (lambda (string pred action) + (complete-with-action + action + (Info-build-node-completions (Info-find-file file1)) + string pred))) + node predicate code))) ;; Otherwise use Info-read-node-completion-table. (t (complete-with-action code Info-read-node-completion-table string predicate)))) @@ -1793,41 +1805,54 @@ (Info-read-node-name prompt) nodename))) -(defun Info-build-node-completions () - (or Info-current-file-completions - (let ((compl nil) - ;; Bind this in case the user sets it to nil. - (case-fold-search t) - (node-regexp "Node: *\\([^,\n]*\\) *[,\n\t]")) - (save-excursion - (save-restriction - (or Info-tag-table-marker - (error "No Info tags found")) - (if (marker-buffer Info-tag-table-marker) - (let ((marker Info-tag-table-marker)) - (set-buffer (marker-buffer marker)) - (widen) - (goto-char marker) - (while (re-search-forward "\n\\(Node\\|Ref\\): \\(.*\\)\177" nil t) - (setq compl - (cons (list (match-string-no-properties 2)) - compl)))) +(defun Info-build-node-completions (&optional file) + (if file + (or (cdr (assoc file Info-file-completions)) + (with-temp-buffer + (Info-mode) + (Info-goto-node (format "(%s)Top" file)) + (Info-build-node-completions-1) + (push (cons file Info-current-file-completions) Info-file-completions) + Info-current-file-completions)) + (or Info-current-file-completions + (Info-build-node-completions-1)))) + +(defun Info-build-node-completions-1 () + (let ((compl nil) + ;; Bind this in case the user sets it to nil. + (case-fold-search t) + (node-regexp "Node: *\\([^,\n]*\\) *[,\n\t]")) + (save-excursion + (save-restriction + (or Info-tag-table-marker + (error "No Info tags found")) + (if (marker-buffer Info-tag-table-marker) + (let ((marker Info-tag-table-marker)) + (set-buffer (marker-buffer marker)) (widen) - (goto-char (point-min)) - ;; If the buffer begins with a node header, process that first. - (if (Info-node-at-bob-matching node-regexp) - (setq compl (list (match-string-no-properties 1)))) - ;; Now for the rest of the nodes. - (while (search-forward "\n\^_" nil t) - (forward-line 1) - (let ((beg (point))) - (forward-line 1) - (if (re-search-backward node-regexp beg t) - (setq compl - (cons (list (match-string-no-properties 1)) - compl)))))))) - (setq compl (cons '("*") compl)) - (set (make-local-variable 'Info-current-file-completions) compl)))) + (goto-char marker) + (while (re-search-forward "\n\\(Node\\|Ref\\): \\(.*\\)\177" nil t) + (setq compl + (cons (list (match-string-no-properties 2)) + compl)))) + (widen) + (goto-char (point-min)) + ;; If the buffer begins with a node header, process that first. + (if (Info-node-at-bob-matching node-regexp) + (setq compl (list (match-string-no-properties 1)))) + ;; Now for the rest of the nodes. + (while (search-forward "\n\^_" nil t) + (forward-line 1) + (let ((beg (point))) + (forward-line 1) + (if (re-search-backward node-regexp beg t) + (setq compl + (cons (list (match-string-no-properties 1)) + compl)))))))) + (setq compl (cons '("*") (nreverse compl))) + (set (make-local-variable 'Info-current-file-completions) compl) + compl)) + (defun Info-restore-point (hl) "If this node has been visited, restore the point value when we left." ------------------------------------------------------------ revno: 111353 committer: Juri Linkov branch nick: trunk timestamp: Thu 2012-12-27 22:09:45 +0200 message: * lisp/frame.el (frame-maximization-style): Remove user option. (cycle-frame-maximized): Remove function. (toggle-frame-maximized): Rewrite and bind to M-. (toggle-frame-fullscreen): New command bound to instead of `toggle-frame-maximized'. http://lists.gnu.org/archive/html/emacs-devel/2012-12/msg00703.html diff: === modified file 'etc/NEWS' --- etc/NEWS 2012-12-27 08:21:08 +0000 +++ etc/NEWS 2012-12-27 20:09:45 +0000 @@ -53,8 +53,8 @@ * Editing Changes in Emacs 24.4 -** New commands `toggle-frame-maximized' and `cycle-frame-maximized', -bound to and S-, respectively. +** New commands `toggle-frame-fullscreen' and `toggle-frame-maximized', +bound to and M-, respectively. * Changes in Specialized Modes and Packages in Emacs 24.4 === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-12-27 19:58:04 +0000 +++ lisp/ChangeLog 2012-12-27 20:09:45 +0000 @@ -1,3 +1,12 @@ +2012-12-27 Juri Linkov + + * frame.el (frame-maximization-style): Remove user option. + (cycle-frame-maximized): Remove function. + (toggle-frame-maximized): Rewrite and bind to M-. + (toggle-frame-fullscreen): New command bound to instead of + `toggle-frame-maximized'. + http://lists.gnu.org/archive/html/emacs-devel/2012-12/msg00703.html + 2012-12-27 Michael Albinus * net/tramp.el (tramp-handle-file-accessible-directory-p): New defun. === modified file 'lisp/frame.el' --- lisp/frame.el 2012-12-12 14:43:45 +0000 +++ lisp/frame.el 2012-12-27 20:09:45 +0000 @@ -1654,32 +1654,49 @@ 'blink-cursor-start)))) -;; Frame maximization -(defcustom frame-maximization-style 'maximized - "The maximization style of \\[toggle-frame-maximized]." - :version "24.4" - :type '(choice - (const :tab "Respect window manager screen decorations." maximized) - (const :tab "Ignore window manager screen decorations." fullscreen)) - :group 'frames) +;; Frame maximization/fullscreen (defun toggle-frame-maximized () - "Maximize/un-maximize Emacs frame according to `frame-maximization-style'. -See also `cycle-frame-maximized'." + "Toggle maximization state of the selected frame. +Maximize the selected frame or un-maximize if it is already maximized. +Respect window manager screen decorations. +If the frame is in fullscreen mode, don't change its mode, +just toggle the temporary frame parameter `maximized', +so the frame will go to the right maximization state +after disabling fullscreen mode. +See also `toggle-frame-fullscreen'." (interactive) - (modify-frame-parameters - nil `((fullscreen . ,(if (frame-parameter nil 'fullscreen) - nil frame-maximization-style))))) + (if (eq (frame-parameter nil 'fullscreen) 'fullscreen) + (modify-frame-parameters + nil + `((maximized + . ,(unless (eq (frame-parameter nil 'maximized) 'maximized) + 'maximized)))) + (modify-frame-parameters + nil + `((fullscreen + . ,(unless (eq (frame-parameter nil 'fullscreen) 'maximized) + 'maximized)))))) -(defun cycle-frame-maximized () - "Cycle Emacs frame between normal, maximized, and fullscreen. +(defun toggle-frame-fullscreen () + "Toggle fullscreen mode of the selected frame. +Enable fullscreen mode of the selected frame or disable if it is +already fullscreen. Ignore window manager screen decorations. +When turning on fullscreen mode, remember the previous value of the +maximization state in the temporary frame parameter `maximized'. +Restore the maximization state when turning off fullscreen mode. See also `toggle-frame-maximized'." (interactive) (modify-frame-parameters - nil `((fullscreen . ,(cl-case (frame-parameter nil 'fullscreen) - ((nil) 'maximized) - ((maximized) 'fullscreen) - ((fullscreen) nil)))))) + nil + `((maximized + . ,(unless (eq (frame-parameter nil 'fullscreen) 'fullscreen) + (frame-parameter nil 'fullscreen))) + (fullscreen + . ,(if (eq (frame-parameter nil 'fullscreen) 'fullscreen) + (if (eq (frame-parameter nil 'maximized) 'maximized) + 'maximized) + 'fullscreen))))) ;;;; Key bindings @@ -1688,8 +1705,8 @@ (define-key ctl-x-5-map "1" 'delete-other-frames) (define-key ctl-x-5-map "0" 'delete-frame) (define-key ctl-x-5-map "o" 'other-frame) -(define-key global-map [f11] 'toggle-frame-maximized) -(define-key global-map [(shift f11)] 'cycle-frame-maximized) +(define-key global-map [f11] 'toggle-frame-fullscreen) +(define-key global-map [(meta f10)] 'toggle-frame-maximized) ;; Misc. ------------------------------------------------------------ revno: 111352 committer: Sam Steingold branch nick: trunk timestamp: Thu 2012-12-27 14:58:04 -0500 message: fix last patch diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-12-27 19:00:57 +0000 +++ lisp/ChangeLog 2012-12-27 19:58:04 +0000 @@ -16,7 +16,7 @@ * progmodes/ruby-mode.el (ruby-indent-beg-re): Only allow "class", "module" and "def" to have indentation before them. Regression - from Bug#109911 (see the new test). + from revno:109911 (see the new test). * progmodes/ruby-mode.el: Bump the version to 1.2 (Bug#13200). ------------------------------------------------------------ revno: 111351 committer: Michael Albinus branch nick: trunk timestamp: Thu 2012-12-27 20:00:57 +0100 message: * net/tramp.el (tramp-handle-file-accessible-directory-p): New defun. * net/tramp-adb.el (tramp-adb-file-name-handler-alist): * net/tramp-gvfs.el (tramp-gvfs-file-name-handler-alist): * net/tramp-sh.el (tramp-sh-file-name-handler-alist): Add handler for `file-accessible-directory-p'. (Bug#13275) diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-12-27 16:33:06 +0000 +++ lisp/ChangeLog 2012-12-27 19:00:57 +0000 @@ -1,3 +1,12 @@ +2012-12-27 Michael Albinus + + * net/tramp.el (tramp-handle-file-accessible-directory-p): New defun. + + * net/tramp-adb.el (tramp-adb-file-name-handler-alist): + * net/tramp-gvfs.el (tramp-gvfs-file-name-handler-alist): + * net/tramp-sh.el (tramp-sh-file-name-handler-alist): Add handler + for `file-accessible-directory-p'. (Bug#13275) + 2012-12-27 Sam Steingold * progmodes/cperl-mode.el (cperl-calculate-indent): Do not stagger === modified file 'lisp/net/tramp-adb.el' --- lisp/net/tramp-adb.el 2012-12-26 16:22:18 +0000 +++ lisp/net/tramp-adb.el 2012-12-27 19:00:57 +0000 @@ -82,6 +82,7 @@ (file-name-as-directory . tramp-handle-file-name-as-directory) (file-regular-p . tramp-handle-file-regular-p) (file-remote-p . tramp-handle-file-remote-p) + (file-accessible-directory-p . tramp-handle-file-accessible-directory-p) (file-directory-p . tramp-adb-handle-file-directory-p) (file-symlink-p . tramp-handle-file-symlink-p) ;; FIXME: This is too sloppy. === modified file 'lisp/net/tramp-gvfs.el' --- lisp/net/tramp-gvfs.el 2012-12-17 14:38:07 +0000 +++ lisp/net/tramp-gvfs.el 2012-12-27 19:00:57 +0000 @@ -384,7 +384,7 @@ (dired-uncache . tramp-handle-dired-uncache) ;; `executable-find' is not official yet. performed by default handler. (expand-file-name . tramp-gvfs-handle-expand-file-name) - ;; `file-accessible-directory-p' performed by default handler. + (file-accessible-directory-p . tramp-handle-file-accessible-directory-p) (file-acl . tramp-gvfs-handle-file-acl) (file-attributes . tramp-gvfs-handle-file-attributes) (file-directory-p . tramp-gvfs-handle-file-directory-p) === modified file 'lisp/net/tramp-sh.el' --- lisp/net/tramp-sh.el 2012-12-19 13:01:16 +0000 +++ lisp/net/tramp-sh.el 2012-12-27 19:00:57 +0000 @@ -935,6 +935,7 @@ (file-name-nondirectory . tramp-handle-file-name-nondirectory) (file-truename . tramp-sh-handle-file-truename) (file-exists-p . tramp-sh-handle-file-exists-p) + (file-accessible-directory-p . tramp-handle-file-accessible-directory-p) (file-directory-p . tramp-sh-handle-file-directory-p) (file-executable-p . tramp-sh-handle-file-executable-p) (file-readable-p . tramp-sh-handle-file-readable-p) === modified file 'lisp/net/tramp.el' --- lisp/net/tramp.el 2012-12-18 13:37:06 +0000 +++ lisp/net/tramp.el 2012-12-27 19:00:57 +0000 @@ -2757,6 +2757,11 @@ (if (or dir-p (file-directory-p dir)) dir (file-name-directory dir)) nil (tramp-flush-directory-property v localname))) +(defun tramp-handle-file-accessible-directory-p (filename) + "Like `file-accessible-directory-p' for Tramp files." + (and (file-directory-p filename) + (file-executable-p filename))) + (defun tramp-handle-file-exists-p (filename) "Like `file-exists-p' for Tramp files." (not (null (file-attributes filename)))) ------------------------------------------------------------ revno: 111350 fixes bug: http://debbugs.gnu.org/13274 committer: Glenn Morris branch nick: trunk timestamp: Thu 2012-12-27 09:59:21 -0800 message: configure.ac fix for double quotes in configure command-line * configure.ac (emacs_config_options): New. Use $@ rather than undocumented $ac_configure_args. Replace any embedded double quotes. diff: === modified file 'ChangeLog' --- ChangeLog 2012-12-27 08:21:08 +0000 +++ ChangeLog 2012-12-27 17:59:21 +0000 @@ -1,3 +1,9 @@ +2012-12-27 Glenn Morris + + * configure.ac (emacs_config_options): New. + Use $@ rather than undocumented $ac_configure_args. + Replace any embedded double quotes. (Bug#13274) + 2012-12-27 Andreas Schwab * configure.ac (SIGNALS_VIA_CHARACTERS): Also define for darwin. === modified file 'configure.ac' --- configure.ac 2012-12-27 08:21:08 +0000 +++ configure.ac 2012-12-27 17:59:21 +0000 @@ -23,6 +23,9 @@ AC_PREREQ(2.65) AC_INIT(emacs, 24.3.50) +dnl This is the documented way to record the args passed to configure, +dnl rather than $ac_configure_args. +emacs_config_options="$@" AC_CONFIG_HEADER(src/config.h:src/config.in) AC_CONFIG_SRCDIR(src/lisp.h) AC_CONFIG_AUX_DIR(build-aux) @@ -4068,7 +4071,9 @@ AC_DEFINE_UNQUOTED(EMACS_CONFIGURATION, "${canonical}", [Define to the canonical Emacs configuration name.]) -AC_DEFINE_UNQUOTED(EMACS_CONFIG_OPTIONS, "${ac_configure_args}", +dnl Replace any embedded " characters (bug#13274). +emacs_config_options=`echo "$emacs_config_options" | sed -e "s/\"/'/g"` +AC_DEFINE_UNQUOTED(EMACS_CONFIG_OPTIONS, "${emacs_config_options}", [Define to the options passed to configure.]) AH_TEMPLATE(config_opsysfile, [Some platforms that do not use configure define this to include extra configuration information.]) ------------------------------------------------------------ revno: 111349 committer: Sam Steingold branch nick: trunk timestamp: Thu 2012-12-27 11:33:06 -0500 message: * lisp/progmodes/cperl-mode.el (cperl-calculate-indent): Do not stagger continuations, see . diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-12-27 08:21:08 +0000 +++ lisp/ChangeLog 2012-12-27 16:33:06 +0000 @@ -1,8 +1,13 @@ +2012-12-27 Sam Steingold + + * progmodes/cperl-mode.el (cperl-calculate-indent): Do not stagger + continuations, see . + 2012-12-27 Dmitry Gutov * progmodes/ruby-mode.el (ruby-indent-beg-re): Only allow "class", "module" and "def" to have indentation before them. Regression - from 109911 (see the new test). + from Bug#109911 (see the new test). * progmodes/ruby-mode.el: Bump the version to 1.2 (Bug#13200). === modified file 'lisp/progmodes/cperl-mode.el' --- lisp/progmodes/cperl-mode.el 2012-12-01 05:09:12 +0000 +++ lisp/progmodes/cperl-mode.el 2012-12-27 16:33:06 +0000 @@ -3120,8 +3120,10 @@ ((eq 'continuation (elt i 0)) ;; [continuation statement-start char-after is-block is-brace] (goto-char (elt i 1)) ; statement-start - (+ (if (memq (elt i 2) (append "}])" nil)) ; char-after - 0 ; Closing parenth + (+ (if (or (memq (elt i 2) (append "}])" nil)) ; char-after + (eq 'continuation ; do not stagger continuations + (elt (cperl-sniff-for-indent parse-data) 0))) + 0 ; Closing parenth or continuation of a continuation cperl-continued-statement-offset) (if (or (elt i 3) ; is-block (not (elt i 4)) ; is-brace ------------------------------------------------------------ revno: 111348 author: Lars Ingebrigtsen committer: Katsumi Yamaoka branch nick: trunk timestamp: Thu 2012-12-27 14:58:36 +0000 message: lisp/gnus/gnus-msg.el (gnus-summary-resend-message): Don't bug out on non-string posting styles (bug#13285) diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2012-12-27 14:44:01 +0000 +++ lisp/gnus/ChangeLog 2012-12-27 14:58:36 +0000 @@ -1,3 +1,8 @@ +2012-12-27 Lars Ingebrigtsen + + * gnus-msg.el (gnus-summary-resend-message): Don't bug out on + non-string posting styles (bug#13285). + 2012-12-27 Glenn Morris * plstore.el (plstore-passphrase-callback-function): === modified file 'lisp/gnus/gnus-msg.el' --- lisp/gnus/gnus-msg.el 2012-10-06 20:30:26 +0000 +++ lisp/gnus/gnus-msg.el 2012-12-27 14:58:36 +0000 @@ -1384,7 +1384,8 @@ (dolist (style (if styles (append gnus-posting-styles (list (cons ".*" styles))) gnus-posting-styles)) - (when (string-match (pop style) gnus-newsgroup-name) + (when (and (stringp (car style)) + (string-match (pop style) gnus-newsgroup-name)) (when (setq tem (cadr (assq 'name style))) (setq user-full-name tem)) (when (setq tem (cadr (assq 'address style))) ------------------------------------------------------------ revno: 111347 author: Andreas Schwab committer: Katsumi Yamaoka branch nick: trunk timestamp: Thu 2012-12-27 14:44:01 +0000 message: lisp/gnus/mml2015.el (mml2015-epg-key-image): separate attribute stream from stderr diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2012-12-27 08:21:08 +0000 +++ lisp/gnus/ChangeLog 2012-12-27 14:44:01 +0000 @@ -5,6 +5,9 @@ 2012-12-27 Andreas Schwab + * mml2015.el (mml2015-epg-key-image): separate attribute stream from + stderr. + * nnimap.el (nnimap-find-article-by-message-id): Don't error out if group is nil. === modified file 'lisp/gnus/mml2015.el' --- lisp/gnus/mml2015.el 2012-12-26 22:30:58 +0000 +++ lisp/gnus/mml2015.el 2012-12-27 14:44:01 +0000 @@ -827,7 +827,7 @@ (let* ((coding-system-for-write 'binary) (coding-system-for-read 'binary) (data (shell-command-to-string - (format "%s --list-options no-show-photos --attribute-fd 2 --list-keys %s > /dev/null" + (format "%s --list-options no-show-photos --attribute-fd 3 --list-keys %s 3>&1 >/dev/null 2>&1" epg-gpg-program key-id)))) (when (> (length data) 0) (insert (substring data 16)) ------------------------------------------------------------ revno: 111346 committer: Glenn Morris branch nick: trunk timestamp: Thu 2012-12-27 06:17:38 -0500 message: Auto-commit of generated files. diff: === modified file 'autogen/configure' --- autogen/configure 2012-12-27 08:21:08 +0000 +++ autogen/configure 2012-12-27 11:17:38 +0000 @@ -15534,7 +15534,7 @@ case $opsys in - aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd ) + aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd | darwin ) $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h ;; ------------------------------------------------------------ revno: 111345 [merge] committer: Glenn Morris branch nick: trunk timestamp: Thu 2012-12-27 00:21:08 -0800 message: Merge from emacs-24; up to r111080 diff: === modified file 'ChangeLog' --- ChangeLog 2012-12-26 05:41:42 +0000 +++ ChangeLog 2012-12-27 08:21:08 +0000 @@ -1,3 +1,8 @@ +2012-12-27 Andreas Schwab + + * configure.ac (SIGNALS_VIA_CHARACTERS): Also define for darwin. + (Bug#13222) + 2012-12-26 Paul Eggert Revert static checking of stack smashing. === modified file 'configure.ac' --- configure.ac 2012-12-26 05:41:42 +0000 +++ configure.ac 2012-12-27 08:21:08 +0000 @@ -3673,7 +3673,7 @@ case $opsys in dnl Perry Smith says this is correct for AIX. dnl thomas@mathematik.uni-bremen.de says this is needed for IRIX. - aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd ) + aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd | darwin ) AC_DEFINE(SIGNALS_VIA_CHARACTERS, 1) ;; === modified file 'doc/emacs/maintaining.texi' --- doc/emacs/maintaining.texi 2012-12-06 06:17:10 +0000 +++ doc/emacs/maintaining.texi 2012-12-27 08:21:08 +0000 @@ -1065,7 +1065,7 @@ @cindex CVS directory mode In addition to the VC Directory buffer, Emacs has a similar facility called PCL-CVS which is specialized for CVS@. @xref{Top, , About -PCL-CVS, pcl-cvs, PCL-CVS --- The Emacs Front-End to CVS}. +PCL-CVS, pcl-cvs, PCL-CVS---The Emacs Front-End to CVS}. @end ifnottex @menu === modified file 'doc/lispref/ChangeLog' --- doc/lispref/ChangeLog 2012-12-22 19:09:52 +0000 +++ doc/lispref/ChangeLog 2012-12-27 08:21:08 +0000 @@ -1,3 +1,7 @@ +2012-12-27 Glenn Morris + + * files.texi (File Names): Mention Cygwin conversion functions. + 2012-12-22 Martin Rudalics * windows.texi (Selecting Windows): Reword description of === modified file 'doc/lispref/files.texi' --- doc/lispref/files.texi 2012-12-22 14:18:11 +0000 +++ doc/lispref/files.texi 2012-12-27 08:21:08 +0000 @@ -1733,12 +1733,20 @@ can operate on file names that do not refer to an existing file or directory. +@findex cygwin-convert-file-name-from-windows +@findex cygwin-convert-file-name-to-windows +@cindex MS-Windows file-name syntax +@cindex converting file names from/to MS-Windows syntax On MS-DOS and MS-Windows, these functions (like the function that actually operate on files) accept MS-DOS or MS-Windows file-name syntax, where backslashes separate the components, as well as Unix syntax; but they always return Unix syntax. This enables Lisp programs to specify file names in Unix syntax and work properly on all systems without -change. +change.@footnote{In MS-Windows versions of Emacs compiled for the Cygwin +environment, you can use the functions +@code{cygwin-convert-file-name-to-windows} and +@code{cygwin-convert-file-name-from-windows} to convert between the +two file-name syntaxes.} @menu * File Name Components:: The directory part of a file name, and the rest. === modified file 'doc/misc/ChangeLog' --- doc/misc/ChangeLog 2012-12-25 12:00:26 +0000 +++ doc/misc/ChangeLog 2012-12-27 08:21:08 +0000 @@ -1,3 +1,28 @@ +2012-12-27 Glenn Morris + + * viper.texi (Rudimentary Changes, Key Bindings, Key Bindings): + Avoid some overfull lines. + + * widget.texi (Programming Example): Break some long lines. + + * wisent.texi (Wisent Overview): Fix xref. + (Grammar format, Understanding the automaton): Avoid overfill. + + * bovine.texi (Optional Lambda Expression): Allow line break. + + * auth.texi (Help for users): Break long lines. + + * ada-mode.texi (Project file variables): + Reword to reduce underfull hbox. + (No project files, Use GNAT project file): + Use smallexample to make some overfull lines less terrible. + + * autotype.texi, bovine.texi, ede.texi, eieio.texi, pcl-cvs.texi: + Fix cross-references to separate manuals. + + * Makefile.in (gfdl): New variable. Use throughout where + appropriate so that targets depend on doclicense.texi. + 2012-12-25 Lars Ingebrigtsen * gnus.texi (Customizing the IMAP Connection): Mention the other === modified file 'doc/misc/ada-mode.texi' --- doc/misc/ada-mode.texi 2012-12-22 19:49:54 +0000 +++ doc/misc/ada-mode.texi 2012-12-27 08:21:08 +0000 @@ -521,8 +521,8 @@ ada_project_path=$GDS_ROOT/makerules ada_project_path=../opentoken @end example -the environment variable @code{ADA_PROJECT_PATH} will be set to -@code{"/home/shared/makerules:/home/opentoken/"}. +then as a result the environment variable @code{ADA_PROJECT_PATH} will +be set to @code{"/home/shared/makerules:/home/opentoken/"}. The default value is not the current value of this environment variable, because that will typically have been set by another @@ -730,7 +730,7 @@ get a @code{*compilation*} buffer containing something like (the directory paths will be different): -@example +@smallexample cd c:/Examples/Example_1/ gnatmake -u -c -gnatc -g c:/Examples/Example_1/hello.adb -cargs -gnatq -gnatQ gcc -c -Ic:/Examples/Example_1/ -gnatc -g -gnatq -gnatQ -I- c:/Examples/Example_1/hello.adb @@ -738,7 +738,7 @@ hello.adb:4:04: non-visible declaration at a-textio.ads:264 hello.adb:4:04: non-visible declaration at a-textio.ads:260 gnatmake: "c:/Examples/Example_1/hello.adb" compilation error -@end example +@end smallexample If you have enabled font-lock, the lines with actual errors (starting with @file{hello.adb}) are highlighted, with the file name in red. @@ -1045,14 +1045,14 @@ Build}. You should get a @code{*compilation*} buffer containing something like (the directory paths will be different): -@example +@smallexample cd c:/Examples/Example_4/Gnat_Project/ gnatmake -o hello_4 hello_4 -Phello_4.gpr -cargs -gnatq -gnatQ -bargs -largs gcc -c -g -gnatyt -gnatq -gnatQ -I- -gnatA c:\Examples\Example_4\Gnat_Project\hello_4.adb gcc -c -g -gnatyt -gnatq -gnatQ -I- -gnatA c:\Examples\Example_4\hello_pkg.adb hello_pkg.adb:2:08: keyword "body" expected here [see file name] gnatmake: "c:\examples\example_4\hello_pkg.adb" compilation error -@end example +@end smallexample Compare the @code{gcc} options to the compiler output in @ref{Set compiler options}; this shows that @file{hello_4.gpr} is being used to @@ -1112,14 +1112,14 @@ Build}. You should get a @code{*compilation*} buffer containing something like (the directory paths will be different): -@example +@smallexample cd c:/Examples/Example_5/ gnatmake -o hello_5 hello_5 -Phello_5.gpr -g -cargs -gnatq -gnatQ -bargs -largs gcc -c -g -gnatyt -g -gnatq -gnatQ -I- -gnatA c:\Examples\Example_5\hello_5.adb gcc -c -g -gnatyt -g -gnatq -gnatQ -I- -gnatA c:\Examples\Example_4\hello_pkg.adb hello_pkg.adb:2:08: keyword "body" expected here [see file name] gnatmake: "c:\examples\example_4\hello_pkg.adb" compilation error -@end example +@end smallexample Now type @kbd{C-x `}. @file{Example_4/hello_pkg.adb} is shown, demonstrating that @file{hello_5.gpr} and @file{hello_4.gpr} are being === modified file 'doc/misc/auth.texi' --- doc/misc/auth.texi 2012-12-22 16:25:40 +0000 +++ doc/misc/auth.texi 2012-12-22 21:12:07 +0000 @@ -154,7 +154,8 @@ (setq auth-sources '((:source "~/.authinfo.gpg"))) ;;; even shorter and the @emph{default}: (setq auth-sources '("~/.authinfo.gpg" "~/.authinfo" "~/.netrc")) -;;; use the Secrets API @var{Login} collection (@pxref{Secret Service API}) +;;; use the Secrets API @var{Login} collection +;;; (@pxref{Secret Service API}) (setq auth-sources '("secrets:Login")) @end lisp @@ -167,7 +168,8 @@ Here's a mixed example using two sources: @lisp -(setq auth-sources '((:source (:secrets default) :host "myserver" :user "joe") +(setq auth-sources '((:source (:secrets default) + :host "myserver" :user "joe") "~/.authinfo.gpg")) @end lisp === modified file 'doc/misc/autotype.texi' --- doc/misc/autotype.texi 2012-12-22 16:25:40 +0000 +++ doc/misc/autotype.texi 2012-12-22 21:01:50 +0000 @@ -58,7 +58,7 @@ language constructs. Project-specific header comments, flow-control constructs or magic numbers are essentially the same every time. Emacs has various features for doing tedious and repetitive typing chores for you -in addition to the Abbrev features (@pxref{(emacs)Abbrevs}). +in addition to the Abbrev features (@pxref{Abbrevs,,, emacs, The GNU Emacs Manual}). One solution is using skeletons, flexible rules that say what to insert, and how to do it. Various programming language modes offer some @@ -113,7 +113,7 @@ programming language you are using, skeletons are a means of accomplishing this. Normally skeletons each have a command of their own, that, when called, will insert the skeleton. These commands can be issued in the usual ways -(@pxref{(emacs)Commands}). Modes that offer various skeletons will often +(@pxref{Commands,,, emacs, The GNU Emacs Manual}). Modes that offer various skeletons will often bind these to key-sequences on the @kbd{C-c} prefix, as well as having an @cite{Insert} menu and maybe even predefined abbrevs for them (@pxref{Skeletons as Abbrevs}). @@ -146,18 +146,18 @@ reindent the wrapped code for you. Skeleton commands take an optional numeric prefix argument -(@pxref{(emacs)Arguments}). This is interpreted in two different ways depending +(@pxref{Arguments,,, emacs, The GNU Emacs Manual}). This is interpreted in two different ways depending on whether the prefix is positive, i.e., forwards oriented, or negative, i.e., backwards oriented. A positive prefix means to wrap the skeleton around that many following words. This is accomplished by putting the words there where the point is normally left after that skeleton is inserted (@pxref{Using -Skeletons}). The point (@pxref{(emacs)Point}) is left at the next +Skeletons}). The point (@pxref{Point,,, emacs, The GNU Emacs Manual}) is left at the next interesting spot in the skeleton instead. A negative prefix means to do something similar with that many previously -marked interregions (@pxref{(emacs)Mark}). In the simplest case, if you type +marked interregions (@pxref{Mark,,, emacs, The GNU Emacs Manual}). In the simplest case, if you type @kbd{M--} just before issuing the skeleton command, that will wrap the skeleton around the current region, just like a positive argument would have wrapped it around a number of words. @@ -189,8 +189,8 @@ @cindex skeletons as abbrevs Rather than use a key binding for every skeleton command, you can also -define an abbreviation (@pxref{(emacs)Defining Abbrevs}) that will expand -(@pxref{(emacs)Expanding Abbrevs}) into the skeleton. +define an abbreviation (@pxref{Defining Abbrevs,,, emacs, The GNU Emacs Manual}) that will expand +(@pxref{Expanding Abbrevs,,, emacs, The GNU Emacs Manual}) into the skeleton. Say you want @samp{ifst} to be an abbreviation for the C language if statement. You will tell Emacs that @samp{ifst} expands to the empty string @@ -290,7 +290,7 @@ documentation string, and the rest is an interactor and any number of skeleton elements together forming a skeleton. This skeleton is assigned to a variable of the same name as the command and can thus be overridden from your -@file{~/.emacs} file (@pxref{(emacs)Init File}). +@file{~/.emacs} file (@pxref{Init File,,, emacs, The GNU Emacs Manual}). @@ -309,14 +309,14 @@ @findex skeleton-pair-insert-maybe @vindex skeleton-pair - This is done by binding the first key (@pxref{(emacs)Rebinding}) of + This is done by binding the first key (@pxref{Rebinding,,, emacs, The GNU Emacs Manual}) of the pair to @code{skeleton-pair-insert-maybe} instead of @code{self-insert-command}. The ``maybe'' comes from the fact that this at-first surprising behavior is initially turned off. To enable it, you must set @code{skeleton-pair} to some non-@code{nil} value. -And even then, a positive argument (@pxref{(emacs)Arguments}) will +And even then, a positive argument (@pxref{Arguments,,, emacs, The GNU Emacs Manual}) will make this key behave like a self-inserting key -(@pxref{(emacs)Inserting Text}). +(@pxref{Inserting Text,,, emacs, The GNU Emacs Manual}). @vindex skeleton-pair-on-word While this breaks with the stated intention of always balancing pairs, it @@ -354,7 +354,7 @@ is to have it be called automatically every time an empty, and only an empty file is visited. This is accomplished by putting @code{(add-hook 'find-file-hook 'auto-insert)} into your @file{~/.emacs} file -(@pxref{(emacs)Init File}). +(@pxref{Init File,,, emacs, The GNU Emacs Manual}). @vindex auto-insert-alist What gets inserted, if anything, is determined by the variable @@ -392,10 +392,10 @@ environment variable @env{$ORGANIZATION} or else the FSF, and prompt for valid keywords describing the contents. Files in a @file{bin} directory for which Emacs could determine no specialized mode -(@pxref{(emacs)Choosing Modes}) are set to Shell script mode. +(@pxref{Choosing Modes,,, emacs, The GNU Emacs Manual}) are set to Shell script mode. @findex define-auto-insert - In Lisp (@pxref{(emacs)Init File}) you can use the function + In Lisp (@pxref{Init File,,, emacs, The GNU Emacs Manual}) you can use the function @code{define-auto-insert} to add to or modify @code{auto-insert-alist}. See its documentation with @kbd{C-h f define-auto-insert}. @@ -438,7 +438,7 @@ @kbd{M-x copyright} is a skeleton inserting command, that adds a copyright notice at the point. The ``by'' part is taken from your environment variable @env{$ORGANIZATION} or if that isn't set you are prompted for it. If the -buffer has a comment syntax (@pxref{(emacs)Comments}), this is inserted as a comment. +buffer has a comment syntax (@pxref{Comments,,, emacs, The GNU Emacs Manual}), this is inserted as a comment. @findex copyright-update @vindex copyright-limit @@ -450,13 +450,13 @@ If a dash-separated year list up to last year is found, that is extended to current year, else the year is added separated by a comma. Or it replaces them when this is called with a prefix argument. If a header referring to a -wrong version of the GNU General Public License (@pxref{(emacs)Copying}) is found, +wrong version of the GNU General Public License (@pxref{Copying,,, emacs, The GNU Emacs Manual}) is found, that is updated too. An interesting application for this function is to have it be called automatically every time a file is saved. This is accomplished by putting @code{(add-hook 'before-save-hook 'copyright-update)} into -your @file{~/.emacs} file (@pxref{(emacs)Init File}). Alternative, +your @file{~/.emacs} file (@pxref{Init File,,, emacs, The GNU Emacs Manual}). Alternative, you can do @kbd{M-x customize-variable @key{RET} before-save-hook @key{RET}}. @code{copyright-update} is conveniently listed as an option in the customization buffer. === modified file 'doc/misc/bovine.texi' --- doc/misc/bovine.texi 2012-12-22 16:25:40 +0000 +++ doc/misc/bovine.texi 2012-12-22 21:15:44 +0000 @@ -138,7 +138,7 @@ In bison, each time an element of @var{components} is found, it is @dfn{shifted} onto the parser stack. (The stack of matched elements.) When all @var{components}' elements have been matched, it is -@dfn{reduced} to @var{result}. @xref{(bison)Algorithm}. +@dfn{reduced} to @var{result}. @xref{Algorithm,,, bison, The GNU Bison Manual}. A particular @var{result} written into your grammar becomes the parser's goal. It is designated by a @code{%start} statement @@ -368,8 +368,8 @@ @code{variable}, though any symbol will work. @item attributes -Is an optional set of labeled values such as @w{@code{:constant-flag t :parent -"parenttype"}}. +Is an optional set of labeled values such as @code{:constant-flag t :parent +"parenttype"}. @end table @item (TAG-VARIABLE @var{name} @var{type} @var{default-value} [@var{attributes}]) === modified file 'doc/misc/ede.texi' --- doc/misc/ede.texi 2012-12-22 16:25:40 +0000 +++ doc/misc/ede.texi 2012-12-22 21:01:50 +0000 @@ -1110,7 +1110,7 @@ is saved, or how a target is compiled can be customized by a project author in detail. @ede{} communicates to these project objects via an API using methods. The commands you use in @ede{} mode are high-level -functional wrappers over these methods. @xref{(eieio)Top}. For +functional wrappers over these methods. @xref{Top,,, eieio, EIEIO manual}. For details on using @eieio{} to extending classes, and writing methods. If you intend to extend @ede{}, it is most likely that a new target type is @@ -1361,7 +1361,8 @@ override this unless you keep auxiliary files. @end table -These methods are used by the semantic package extensions @xref{(semantic)Top}. +These methods are used by the semantic package extensions. +@xref{Top,,, semantic, Semantic manual}. @table @code @item ede-buffer-header-file === modified file 'doc/misc/eieio.texi' --- doc/misc/eieio.texi 2012-12-22 16:25:40 +0000 +++ doc/misc/eieio.texi 2012-12-22 21:01:50 +0000 @@ -446,7 +446,7 @@ @item :type An unquoted type specifier used to validate data set into this slot. -@xref{(cl)Type Predicates}. +@xref{Type Predicates,,,cl,Common Lisp Extensions}. Here are some examples: @table @code @item symbol @@ -1571,7 +1571,7 @@ Each class will be indexed using the texinfo labeled index @var{indexstring} which is a two letter description. -@xref{(texinfo) New Indices}. +@xref{New Indices,,,texinfo,Texinfo manual}. To use this command, the texinfo macro @@ -1874,8 +1874,9 @@ @item :type Specifier uses the @code{typep} function from the @file{cl} -package. @xref{(cl)Type Predicates}. It therefore has the same issues as -that package. Extensions include the ability to provide object names. +package. @xref{Type Predicates,,,cl,Common Lisp Extensions}. +It therefore has the same issues as that package. Extensions include +the ability to provide object names. @end table Defclass also supports class options, but does not currently use values === modified file 'doc/misc/idlwave.texi' --- doc/misc/idlwave.texi 2012-12-22 19:49:54 +0000 +++ doc/misc/idlwave.texi 2012-12-27 08:21:08 +0000 @@ -4067,7 +4067,7 @@ @itemize @bullet @item When you download the IDLWAVE distribution, make sure you save the file under the names @file{idlwave.tar.gz}. -@item M-TAB switches among running programs --- use Esc-TAB +@item M-TAB switches among running programs---use Esc-TAB instead. @item Other issues as yet unnamed... @end itemize === modified file 'doc/misc/pcl-cvs.texi' --- doc/misc/pcl-cvs.texi 2012-12-22 20:11:36 +0000 +++ doc/misc/pcl-cvs.texi 2012-12-27 08:21:08 +0000 @@ -1169,13 +1169,13 @@ @findex log-edit-insert-changelog If you work by writing entries in the @file{ChangeLog} -(@pxref{(emacs)Change Log}) and then commit the change under revision +(@pxref{Change Log,,, emacs, The GNU Emacs Manual}) and then commit the change under revision control, you can generate the Log Edit text from the ChangeLog using @kbd{C-c C-a} (@kbd{log-edit-insert-changelog}). This looks for entries for the file(s) concerned in the top entry in the ChangeLog and uses those paragraphs as the log text. This text is only inserted if the top entry was made under your user name on the current date. -@xref{(emacs)Change Logs and VC}, for the opposite way of +@xref{Change Logs and VC,,, emacs, The GNU Emacs Manual}, for the opposite way of working---generating ChangeLog entries from the revision control log. In the Log Edit buffer, @kbd{C-c C-f} (@kbd{M-x log-edit-show-files}) === modified file 'doc/misc/viper.texi' --- doc/misc/viper.texi 2012-12-22 20:06:25 +0000 +++ doc/misc/viper.texi 2012-12-27 08:21:08 +0000 @@ -1833,10 +1833,10 @@ specifying a new face. (Emacs faces are described in the Emacs Lisp reference.) On a color display, the following customization method is usually most effective: -@example +@smallexample (set-face-foreground viper-replace-overlay-face "DarkSlateBlue") (set-face-background viper-replace-overlay-face "yellow") -@end example +@end smallexample For a complete list of colors available to you, evaluate the expression @code{(x-defined-colors)}. (Type it in the buffer @code{*scratch*} and then hit the @kbd{C-j} key. @@ -2039,7 +2039,8 @@ @noindent To customize the binding for @kbd{C-h} in Insert state: @example -(define-key viper-insert-global-user-map "\C-h" 'my-del-backwards-function) +(define-key viper-insert-global-user-map "\C-h" + 'my-del-backwards-function) @end example @noindent @@ -2088,7 +2089,8 @@ (setq my-dired-vi-purist-map (make-sparse-keymap)) (define-key my-dired-vi-purist-map "k" 'viper-previous-line) (define-key my-dired-vi-purist-map "l" 'viper-forward-char) -(viper-modify-major-mode 'dired-mode 'emacs-state my-dired-vi-purist-map) +(viper-modify-major-mode 'dired-mode + 'emacs-state my-dired-vi-purist-map) @end example Yet another way to customize key bindings in a major mode is to edit the === modified file 'doc/misc/widget.texi' --- doc/misc/widget.texi 2012-12-22 19:57:35 +0000 +++ doc/misc/widget.texi 2012-12-27 08:21:08 +0000 @@ -360,13 +360,14 @@ (setq widget-example-repeat (widget-create 'editable-list :entry-format "%i %d %v" - :notify (lambda (widget &rest ignore) - (let ((old (widget-get widget - ':example-length)) - (new (length (widget-value widget)))) - (unless (eq old new) - (widget-put widget ':example-length new) - (message "You can count to %d." new)))) + :notify + (lambda (widget &rest ignore) + (let ((old (widget-get widget + ':example-length)) + (new (length (widget-value widget)))) + (unless (eq old new) + (widget-put widget ':example-length new) + (message "You can count to %d." new)))) :value '("One" "Eh, two?" "Five!") '(editable-field :value "three"))) (widget-insert "\n\nSelect multiple:\n\n") @@ -383,11 +384,13 @@ :notify (lambda (widget &rest ignore) (message "You selected %s" (widget-value widget))) - '(item "One") '(item "Another One.") '(item "A Final One.")) + '(item "One") '(item "Another One.") + '(item "A Final One.")) (widget-insert "\n") (widget-create 'push-button :notify (lambda (&rest ignore) - (if (= (length (widget-value widget-example-repeat)) + (if (= (length + (widget-value widget-example-repeat)) 3) (message "Congratulation!") (error "Three was the count!"))) === modified file 'doc/misc/wisent.texi' --- doc/misc/wisent.texi 2012-12-22 20:19:41 +0000 +++ doc/misc/wisent.texi 2012-12-27 08:21:08 +0000 @@ -112,7 +112,7 @@ of GNU Bison 1.28 & 1.31. For more details on the basic concepts for understanding Wisent, it is -worthwhile to read the @ref{Top, Bison Manual, bison}. +worthwhile to read the @ref{Top, Bison Manual, , bison}. @ifhtml @uref{http://www.gnu.org/manual/bison/html_node/index.html}. @end ifhtml @@ -302,7 +302,7 @@ can match the empty string. For example, here is how to define a comma-separated sequence of zero or more @samp{exp} groupings: -@example +@smallexample @group (expseq (nil) ;; expseq: ;; empty ((expseq1)) ;; | expseq1 @@ -312,7 +312,7 @@ ((expseq1 ?, exp)) ;; | expseq1 ',' exp ) ;; ; @end group -@end example +@end smallexample @cindex precedence level @item precedence @@ -339,7 +339,7 @@ Now the precedence of @code{UMINUS} can be used in specific rules: -@example +@smallexample @group (exp @dots{} ;; exp: @dots{} ((exp ?- exp)) ;; | exp '-' exp @@ -348,7 +348,7 @@ @dots{} ;; @dots{} ) ;; ; @end group -@end example +@end smallexample If you forget to append @code{[UMINUS]} to the rule for unary minus, Wisent silently assumes that minus has its usual precedence. This @@ -1029,7 +1029,6 @@ $default reduce using rule 2 (exp) - state 9 exp -> exp . '+' exp (rule 1) @@ -1044,7 +1043,6 @@ $default reduce using rule 3 (exp) - state 10 exp -> exp . '+' exp (rule 1) === modified file 'etc/NEWS' --- etc/NEWS 2012-12-24 17:49:19 +0000 +++ etc/NEWS 2012-12-27 08:21:08 +0000 @@ -1205,14 +1205,16 @@ ** Cygwin builds can use the native MS Windows user interface. Pass --with-w32 to configure. The default remains the X11 interface. ++++ ** Two new functions are available in Cygwin builds: `cygwin-convert-file-name-from-windows' and `cygwin-convert-file-name-to-windows'. These functions allow Lisp code to access the Cygwin file-name mapping machinery to convert between Cygwin and Windows-native file and directory names. +--- ** When invoked with the -nw switch to run on the Windows text-mode terminal, -Emacs now supports mouse highlight, help-echo (in the echo area), and +Emacs now supports `mouse-highlight', help-echo (in the echo area), and `mouse-autoselect-window'. +++ === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-12-27 07:33:47 +0000 +++ lisp/ChangeLog 2012-12-27 08:21:08 +0000 @@ -1,3 +1,17 @@ +2012-12-27 Dmitry Gutov + + * progmodes/ruby-mode.el (ruby-indent-beg-re): Only allow "class", + "module" and "def" to have indentation before them. Regression + from 109911 (see the new test). + + * progmodes/ruby-mode.el: Bump the version to 1.2 (Bug#13200). + +2012-12-27 Alan Mackenzie + + Speed up fontification where there's large brace blocks. + * progmodes/cc-fonts.el (c-font-lock-enclosing-decls): Add a limit + to a call of c-beginning-of-decl-1. + 2012-12-27 Vitalie Spinu (tiny change) * comint.el (comint-adjust-window-point): New function. === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2012-12-26 22:30:58 +0000 +++ lisp/gnus/ChangeLog 2012-12-27 08:21:08 +0000 @@ -1,3 +1,15 @@ +2012-12-27 Glenn Morris + + * plstore.el (plstore-passphrase-callback-function): + Use plstore-get-file. + +2012-12-27 Andreas Schwab + + * nnimap.el (nnimap-find-article-by-message-id): + Don't error out if group is nil. + + * shr.el (shr-tag-em): Render as italic, not bold. + 2012-12-26 Katsumi Yamaoka * mml2015.el (mml2015-epg-key-image): Use mm-set-buffer-multibyte. === modified file 'lisp/gnus/nnimap.el' --- lisp/gnus/nnimap.el 2012-12-25 12:00:26 +0000 +++ lisp/gnus/nnimap.el 2012-12-27 08:21:08 +0000 @@ -980,7 +980,7 @@ (defun nnimap-find-article-by-message-id (group message-id) (with-current-buffer (nnimap-buffer) (erase-buffer) - (unless (equal group (nnimap-group nnimap-object)) + (unless (or (not group) (equal group (nnimap-group nnimap-object))) (setf (nnimap-group nnimap-object) nil) (setf (nnimap-examined nnimap-object) group) (nnimap-send-command "EXAMINE %S" (utf7-encode group t))) === modified file 'lisp/gnus/plstore.el' --- lisp/gnus/plstore.el 2012-12-25 22:23:10 +0000 +++ lisp/gnus/plstore.el 2012-12-27 08:21:08 +0000 @@ -126,8 +126,7 @@ (defun plstore-passphrase-callback-function (_context _key-id plstore) (if plstore-cache-passphrase-for-symmetric-encryption - (let* ((file (file-truename (buffer-file-name - (plstore--get-buffer plstore)))) + (let* ((file (file-truename (plstore-get-file plstore))) (entry (assoc file plstore-passphrase-alist)) passphrase) (or (copy-sequence (cdr entry)) === modified file 'lisp/progmodes/cc-fonts.el' --- lisp/progmodes/cc-fonts.el 2012-01-19 07:21:25 +0000 +++ lisp/progmodes/cc-fonts.el 2012-12-23 11:36:15 +0000 @@ -1591,6 +1591,7 @@ ;; prevent a repeat invocation. See elisp/lispref page "Search-based ;; Fontification". (let* ((paren-state (c-parse-state)) + (decl-search-lim (c-determine-limit 1000)) decl-context in-typedef ps-elt) ;; Are we in any nested struct/union/class/etc. braces? (while paren-state @@ -1599,7 +1600,7 @@ (when (and (atom ps-elt) (eq (char-after ps-elt) ?\{)) (goto-char ps-elt) - (setq decl-context (c-beginning-of-decl-1) + (setq decl-context (c-beginning-of-decl-1 decl-search-lim) in-typedef (looking-at c-typedef-key)) (if in-typedef (c-forward-token-2)) (when (and c-opt-block-decls-with-vars-key === modified file 'lisp/progmodes/ruby-mode.el' --- lisp/progmodes/ruby-mode.el 2012-12-26 19:52:56 +0000 +++ lisp/progmodes/ruby-mode.el 2012-12-27 08:21:08 +0000 @@ -7,7 +7,7 @@ ;; URL: http://www.emacswiki.org/cgi-bin/wiki/RubyMode ;; Created: Fri Feb 4 14:49:13 JST 1994 ;; Keywords: languages ruby -;; Version: 1.0 +;; Version: 1.2 ;; This file is part of GNU Emacs. @@ -64,8 +64,9 @@ "Regexp to match keywords that nest without blocks.") (defconst ruby-indent-beg-re - (concat "^\\s *" (regexp-opt '("class" "module" "def" "if" "unless" "case" - "while" "until" "for" "begin")) "\\_>") + (concat "^\\(\\s *" (regexp-opt '("class" "module" "def")) "\\|" + (regexp-opt '("if" "unless" "case" "while" "until" "for" "begin")) + "\\)\\_>") "Regexp to match where the indentation gets deeper.") (defconst ruby-modifier-beg-keywords === modified file 'src/ChangeLog' --- src/ChangeLog 2012-12-26 15:40:19 +0000 +++ src/ChangeLog 2012-12-27 08:21:08 +0000 @@ -1,3 +1,23 @@ +2012-12-27 Glenn Morris + + * cygw32.c (Fcygwin_convert_file_name_to_windows) + (Fcygwin_convert_file_name_from_windows): Doc fixes. + +2012-12-27 Eli Zaretskii + + * fileio.c (file_name_as_directory, directory_file_name): Accept + an additional argument MULTIBYTE to indicate whether the input C + came from a multibyte or a unibyte Lisp string; all callers + adjusted. Don't assume the input string is always multibyte. + (Bug#13262) + (Ffile_name_directory) [DOS_NT]: Handle unibyte strings correctly: + don't ENCODE_FILE them, and return a unibyte string if the input + was unibyte. + (Fexpand_file_name): Don't mix unibyte with multibyte strings, and + don't assume the input strings will always be multibyte. If the + input strings are multibyte, decode strings obtained from C + library functions. + 2012-12-26 Dmitry Antipov * lisp.h (toplevel): Add two notices to the comment about === modified file 'src/cygw32.c' --- src/cygw32.c 2012-11-21 04:47:55 +0000 +++ src/cygw32.c 2012-12-27 08:21:08 +0000 @@ -110,23 +110,25 @@ Fcygwin_convert_file_name_to_windows, Scygwin_convert_file_name_to_windows, 1, 2, 0, - doc: /* Convert PATH to a Windows path. If ABSOLUTE-P is -non-nil, return an absolute path.*/) - (Lisp_Object path, Lisp_Object absolute_p) + doc: /* Convert a Cygwin file name FILE to a Windows-style file name. +If ABSOLUTE-P is non-nil, return an absolute file name. +For the reverse operation, see `cygwin-convert-file-name-from-windows'. */) + (Lisp_Object file, Lisp_Object absolute_p) { return from_unicode ( - conv_filename_to_w32_unicode (path, EQ (absolute_p, Qnil) ? 0 : 1)); + conv_filename_to_w32_unicode (file, EQ (absolute_p, Qnil) ? 0 : 1)); } DEFUN ("cygwin-convert-file-name-from-windows", Fcygwin_convert_file_name_from_windows, Scygwin_convert_file_name_from_windows, 1, 2, 0, - doc: /* Convert a Windows path to a Cygwin path. If ABSOLUTE-P -is non-nil, return an absolute path.*/) - (Lisp_Object path, Lisp_Object absolute_p) + doc: /* Convert a Windows-style file name FILE to a Cygwin file name. +If ABSOLUTE-P is non-nil, return an absolute file name. +For the reverse operation, see `cygwin-convert-file-name-to-windows'. */) + (Lisp_Object file, Lisp_Object absolute_p) { - return conv_filename_from_w32_unicode (to_unicode (path, &path), + return conv_filename_from_w32_unicode (to_unicode (file, &file), EQ (absolute_p, Qnil) ? 0 : 1); } === modified file 'src/fileio.c' --- src/fileio.c 2012-12-21 19:32:43 +0000 +++ src/fileio.c 2012-12-27 08:21:08 +0000 @@ -379,12 +379,26 @@ strcat (res, "/"); beg = res; p = beg + strlen (beg); + dostounix_filename (beg); + tem_fn = make_specified_string (beg, -1, p - beg, + STRING_MULTIBYTE (filename)); } - } - tem_fn = ENCODE_FILE (make_specified_string (beg, -1, p - beg, - STRING_MULTIBYTE (filename))); - dostounix_filename (SSDATA (tem_fn)); - return DECODE_FILE (tem_fn); + else + tem_fn = make_specified_string (beg - 2, -1, p - beg + 2, + STRING_MULTIBYTE (filename)); + } + else if (STRING_MULTIBYTE (filename)) + { + tem_fn = ENCODE_FILE (make_specified_string (beg, -1, p - beg, 1)); + dostounix_filename (SSDATA (tem_fn)); + tem_fn = DECODE_FILE (tem_fn); + } + else + { + dostounix_filename (beg); + tem_fn = make_specified_string (beg, -1, p - beg, 0); + } + return tem_fn; #else /* DOS_NT */ return make_specified_string (beg, -1, p - beg, STRING_MULTIBYTE (filename)); #endif /* DOS_NT */ @@ -459,12 +473,14 @@ return Ffile_name_directory (filename); } -/* Convert from file name SRC of length SRCLEN to directory name - in DST. On UNIX, just make sure there is a terminating /. - Return the length of DST in bytes. */ +/* Convert from file name SRC of length SRCLEN to directory name in + DST. MULTIBYTE non-zero means the file name in SRC is a multibyte + string. On UNIX, just make sure there is a terminating /. Return + the length of DST in bytes. */ static ptrdiff_t -file_name_as_directory (char *dst, const char *src, ptrdiff_t srclen) +file_name_as_directory (char *dst, const char *src, ptrdiff_t srclen, + bool multibyte) { if (srclen == 0) { @@ -483,14 +499,17 @@ srclen++; } #ifdef DOS_NT - { - Lisp_Object tem_fn = make_specified_string (dst, -1, srclen, 1); + if (multibyte) + { + Lisp_Object tem_fn = make_specified_string (dst, -1, srclen, 1); - tem_fn = ENCODE_FILE (tem_fn); - dostounix_filename (SSDATA (tem_fn)); - tem_fn = DECODE_FILE (tem_fn); - memcpy (dst, SSDATA (tem_fn), (srclen = SBYTES (tem_fn)) + 1); - } + tem_fn = ENCODE_FILE (tem_fn); + dostounix_filename (SSDATA (tem_fn)); + tem_fn = DECODE_FILE (tem_fn); + memcpy (dst, SSDATA (tem_fn), (srclen = SBYTES (tem_fn)) + 1); + } + else + dostounix_filename (dst); #endif return srclen; } @@ -526,16 +545,18 @@ } buf = alloca (SBYTES (file) + 10); - length = file_name_as_directory (buf, SSDATA (file), SBYTES (file)); + length = file_name_as_directory (buf, SSDATA (file), SBYTES (file), + STRING_MULTIBYTE (file)); return make_specified_string (buf, -1, length, STRING_MULTIBYTE (file)); } -/* Convert from directory name SRC of length SRCLEN to - file name in DST. On UNIX, just make sure there isn't - a terminating /. Return the length of DST in bytes. */ +/* Convert from directory name SRC of length SRCLEN to file name in + DST. MULTIBYTE non-zero means the file name in SRC is a multibyte + string. On UNIX, just make sure there isn't a terminating /. + Return the length of DST in bytes. */ static ptrdiff_t -directory_file_name (char *dst, char *src, ptrdiff_t srclen) +directory_file_name (char *dst, char *src, ptrdiff_t srclen, bool multibyte) { /* Process as Unix format: just remove any final slash. But leave "/" unchanged; do not change it to "". */ @@ -551,14 +572,17 @@ srclen--; } #ifdef DOS_NT - { - Lisp_Object tem_fn = make_specified_string (dst, -1, srclen, 1); + if (multibyte) + { + Lisp_Object tem_fn = make_specified_string (dst, -1, srclen, 1); - tem_fn = ENCODE_FILE (tem_fn); - dostounix_filename (SSDATA (tem_fn)); - tem_fn = DECODE_FILE (tem_fn); - memcpy (dst, SSDATA (tem_fn), (srclen = SBYTES (tem_fn)) + 1); - } + tem_fn = ENCODE_FILE (tem_fn); + dostounix_filename (SSDATA (tem_fn)); + tem_fn = DECODE_FILE (tem_fn); + memcpy (dst, SSDATA (tem_fn), (srclen = SBYTES (tem_fn)) + 1); + } + else + dostounix_filename (dst); #endif return srclen; } @@ -594,7 +618,8 @@ } buf = alloca (SBYTES (directory) + 20); - length = directory_file_name (buf, SSDATA (directory), SBYTES (directory)); + length = directory_file_name (buf, SSDATA (directory), SBYTES (directory), + STRING_MULTIBYTE (directory)); return make_specified_string (buf, -1, length, STRING_MULTIBYTE (directory)); } @@ -1044,7 +1069,7 @@ /* `egetenv' may return a unibyte string, which will bite us since we expect the directory to be multibyte. */ tem = build_string (newdir); - if (!STRING_MULTIBYTE (tem)) + if (multibyte && !STRING_MULTIBYTE (tem)) { hdir = DECODE_FILE (tem); newdir = SSDATA (hdir); @@ -1066,7 +1091,18 @@ unblock_input (); if (pw) { + Lisp_Object tem; + newdir = pw->pw_dir; + /* `getpwnam' may return a unibyte string, which will + bite us since we expect the directory to be + multibyte. */ + tem = build_string (newdir); + if (multibyte && !STRING_MULTIBYTE (tem)) + { + hdir = DECODE_FILE (tem); + newdir = SSDATA (hdir); + } nm = p; #ifdef DOS_NT collapse_newdir = 0; @@ -1090,6 +1126,13 @@ adir = alloca (MAXPATHLEN + 1); if (!getdefdir (c_toupper (drive) - 'A' + 1, adir)) adir = NULL; + else if (multibyte) + { + Lisp_Object tem = build_string (adir); + + tem = DECODE_FILE (tem); + memcpy (adir, SSDATA (tem), SBYTES (tem) + 1); + } } if (!adir) { @@ -1148,6 +1191,7 @@ indirectly by prepending newdir to nm if necessary, and using cwd (or the wd of newdir's drive) as the new newdir. */ char *adir; + if (IS_DRIVE (newdir[0]) && IS_DEVICE_SEP (newdir[1])) { drive = (unsigned char) newdir[0]; @@ -1157,7 +1201,7 @@ { ptrdiff_t newlen = strlen (newdir); char *tmp = alloca (newlen + strlen (nm) + 2); - file_name_as_directory (tmp, newdir, newlen); + file_name_as_directory (tmp, newdir, newlen, multibyte); strcat (tmp, nm); nm = tmp; } @@ -1165,10 +1209,17 @@ if (drive) { if (!getdefdir (c_toupper (drive) - 'A' + 1, adir)) - newdir = "/"; + strcpy (adir, "/"); } else getcwd (adir, MAXPATHLEN + 1); + if (multibyte) + { + Lisp_Object tem = build_string (adir); + + tem = DECODE_FILE (tem); + memcpy (adir, SSDATA (tem), SBYTES (tem) + 1); + } newdir = adir; } @@ -1255,7 +1306,7 @@ strcpy (target, newdir); } else - file_name_as_directory (target, newdir, length); + file_name_as_directory (target, newdir, length, multibyte); } strcat (target, nm); @@ -1341,9 +1392,14 @@ target[1] = ':'; } result = make_specified_string (target, -1, o - target, multibyte); - result = ENCODE_FILE (result); - dostounix_filename (SSDATA (result)); - result = DECODE_FILE (result); + if (multibyte) + { + result = ENCODE_FILE (result); + dostounix_filename (SSDATA (result)); + result = DECODE_FILE (result); + } + else + dostounix_filename (SSDATA (result)); #else /* !DOS_NT */ result = make_specified_string (target, -1, o - target, multibyte); #endif /* !DOS_NT */ @@ -1625,18 +1681,24 @@ memcpy (nm, SDATA (filename), SBYTES (filename) + 1); #ifdef DOS_NT - { - Lisp_Object encoded_filename = ENCODE_FILE (filename); - Lisp_Object tem_fn; + if (multibyte) + { + Lisp_Object encoded_filename = ENCODE_FILE (filename); + Lisp_Object tem_fn; - dostounix_filename (SDATA (encoded_filename)); - tem_fn = DECODE_FILE (encoded_filename); - nm = alloca (SBYTES (tem_fn) + 1); - memcpy (nm, SDATA (tem_fn), SBYTES (tem_fn) + 1); - substituted = (memcmp (nm, SDATA (filename), SBYTES (filename)) != 0); - if (substituted) - filename = tem_fn; - } + dostounix_filename (SDATA (encoded_filename)); + tem_fn = DECODE_FILE (encoded_filename); + nm = alloca (SBYTES (tem_fn) + 1); + memcpy (nm, SDATA (tem_fn), SBYTES (tem_fn) + 1); + substituted = (memcmp (nm, SDATA (filename), SBYTES (filename)) != 0); + if (substituted) + filename = tem_fn; + } + else + { + dostounix_filename (nm); + substituted = (memcmp (nm, SDATA (filename), SBYTES (filename)) != 0); + } #endif endp = nm + SBYTES (filename); === modified file 'test/ChangeLog' --- test/ChangeLog 2012-12-14 06:58:15 +0000 +++ test/ChangeLog 2012-12-27 08:21:08 +0000 @@ -1,3 +1,8 @@ +2012-12-27 Dmitry Gutov + + * automated/ruby-mode-tests.el + (ruby-indent-after-block-in-continued-expression): New test. + 2012-12-14 Dmitry Gutov * automated/ruby-mode-tests.el === modified file 'test/automated/ruby-mode-tests.el' --- test/automated/ruby-mode-tests.el 2012-12-14 06:58:15 +0000 +++ test/automated/ruby-mode-tests.el 2012-12-27 08:21:08 +0000 @@ -224,6 +224,19 @@ | end |")) +(ert-deftest ruby-indent-after-block-in-continued-expression () + (ruby-should-indent-buffer + "var = + | begin + | val + | end + |statement" + "var = + |begin + |val + |end + |statement")) + (ert-deftest ruby-move-to-block-stops-at-indentation () (ruby-with-temp-buffer "def f\nend" (beginning-of-line) ------------------------------------------------------------ revno: 111344 author: Vitalie Spinu committer: martin rudalics branch nick: trunk timestamp: Thu 2012-12-27 08:33:47 +0100 message: Cleanup comint-postoutput-scroll-to-bottom (Bug#13248). * comint.el (comint-adjust-window-point): New function. (comint-postoutput-scroll-to-bottom): Call comint-adjust-window-point (Bug#13248). diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2012-12-26 19:52:56 +0000 +++ lisp/ChangeLog 2012-12-27 07:33:47 +0000 @@ -1,3 +1,9 @@ +2012-12-27 Vitalie Spinu (tiny change) + + * comint.el (comint-adjust-window-point): New function. + (comint-postoutput-scroll-to-bottom): Call + comint-adjust-window-point (Bug#13248). + 2012-12-26 Dmitry Gutov * progmodes/ruby-mode.el (auto-mode-alist): `purecopy' the === modified file 'lisp/comint.el' --- lisp/comint.el 2012-12-21 02:08:29 +0000 +++ lisp/comint.el 2012-12-27 07:33:47 +0000 @@ -2120,19 +2120,31 @@ ((bound-and-true-p follow-mode) (follow-comint-scroll-to-bottom)) (t - (let ((selected (selected-window))) - (dolist (w (get-buffer-window-list current nil t)) - (select-window w) - (unwind-protect - (progn - (comint-adjust-point selected) - ;; Optionally scroll to the bottom of the window. - (and comint-scroll-show-maximum-output - (eobp) - (recenter (- -1 scroll-margin)))) - (select-window selected)))))) + (dolist (w (get-buffer-window-list current nil t)) + (comint-adjust-window-point w process) + ;; Optionally scroll to the bottom of the window. + (and comint-scroll-show-maximum-output + (eq (window-point w) (point-max)) + (with-selected-window w + (recenter (- -1 scroll-margin))))))) (set-buffer current)))) + +(defun comint-adjust-window-point (window process) + "Move point in WINDOW based on Comint settings. +For point adjustment use the process-mark of PROCESS." + (and (< (window-point window) (process-mark process)) + (or (memq comint-move-point-for-output '(t all)) + ;; Maybe user wants point to jump to end. + (eq comint-move-point-for-output + (if (eq (selected-window) window) 'this 'others)) + ;; If point was at the end, keep it at end. + (and (marker-position comint-last-output-start) + (>= (window-point window) comint-last-output-start))) + (set-window-point window (process-mark process)))) + + +;; this function is nowhere used (defun comint-adjust-point (selected) "Move point in the selected window based on Comint settings. SELECTED is the window that was originally selected." ------------------------------------------------------------ Use --include-merged or -n0 to see merged revisions.