diff options
| author | Paul Eggert <eggert@cs.ucla.edu> | 2012-01-16 19:43:00 -0800 |
|---|---|---|
| committer | Paul Eggert <eggert@cs.ucla.edu> | 2012-01-16 19:43:00 -0800 |
| commit | 78df1fb1d46d556bfc2698ca1802972b13613ba8 (patch) | |
| tree | 114803047bb77b06e149d9218cd4540b9f287e65 /lisp | |
| parent | 807f82fcebc7d946baa23f1d29ff5b0cf336f08e (diff) | |
| parent | 1b0880d5f1b478fe097aef8b702a5c7c70bd9f18 (diff) | |
| download | emacs-78df1fb1d46d556bfc2698ca1802972b13613ba8.tar.gz | |
Merge from trunk.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/ChangeLog | 82 | ||||
| -rw-r--r-- | lisp/minibuffer.el | 4 | ||||
| -rw-r--r-- | lisp/net/tramp-sh.el | 1 | ||||
| -rw-r--r-- | lisp/window.el | 64 |
4 files changed, 92 insertions, 59 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 76728fdbc5b..2813d80d9ff 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,20 @@ +2012-01-16 Stefan Monnier <monnier@iro.umontreal.ca> + + * minibuffer.el (completion--replace): Strip properties (bug#10062). + +2012-01-16 Martin Rudalics <rudalics@gmx.at> + + * window.el (window-state-ignored-parameters): Remove variable. + (window--state-get-1): Rename argument MARKERS to IGNORE. + Handle persistent window parameters. Make copy of clone-of + parameter only if requested. (Bug#10348) + (window--state-put-2): Install a window parameter only if it has + a non-nil value or an existing parameter shall be overwritten. + +2012-01-15 Michael Albinus <michael.albinus@gmx.de> + + * net/tramp-sh.el (tramp-remote-path): Set tramp-autoload cookie. + 2012-01-14 Eli Zaretskii <eliz@gnu.org> * info.el (Info-toc-build): If the Info file has no "Up" pointer, @@ -34,7 +51,7 @@ Fix Emacs bug #10463 - put `widen's around the critical spots. - * progmodes/cc-engine.el (c-in-literal, c-literal-limits): put a + * progmodes/cc-engine.el (c-in-literal, c-literal-limits): Put a widen around each invocation of c-state-pp-to-literal. Remove an unused let variable. @@ -45,8 +62,8 @@ 2012-01-10 Chong Yidong <cyd@gnu.org> - * net/network-stream.el (network-stream-open-starttls): Avoid - emitting a confusing error message when the server gives a bad + * net/network-stream.el (network-stream-open-starttls): + Avoid emitting a confusing error message when the server gives a bad response to the capability command. 2012-01-10 Glenn Morris <rgm@gnu.org> @@ -139,8 +156,8 @@ * custom.el (enable-theme): Don't set custom-safe-themes. - * cus-theme.el (custom-theme-merge-theme): Ignore - custom-enabled-themes and custom-safe-themes. + * cus-theme.el (custom-theme-merge-theme): + Ignore custom-enabled-themes and custom-safe-themes. 2012-01-05 Michael R. Mauger <mmaug@yahoo.com> @@ -163,8 +180,8 @@ 2012-01-03 Chong Yidong <cyd@gnu.org> - * shell.el (shell-dynamic-complete-functions): Put - pcomplete-completions-at-point, so as to try + * shell.el (shell-dynamic-complete-functions): + Put pcomplete-completions-at-point, so as to try comint-filename-completion first (Bug#10417). 2012-01-02 Richard Stallman <rms@gnu.org> @@ -189,8 +206,8 @@ 2012-01-01 Eli Zaretskii <eliz@gnu.org> - * term/w32-win.el (dynamic-library-alist) <gnutls>: Load - libgnutls-28.dll, from GnuTLS version 3.x, in preference to + * term/w32-win.el (dynamic-library-alist) <gnutls>: + Load libgnutls-28.dll, from GnuTLS version 3.x, in preference to libgnutls-26.dll. 2011-12-31 Andreas Schwab <schwab@linux-m68k.org> @@ -242,11 +259,10 @@ 2011-12-24 Alan Mackenzie <acm@muc.de> Introduce a mechanism to widen the region used in context font - locking. Use this to protect declarations from losing their - contexts. + locking. Use this to protect declarations from losing their contexts. - * progmodes/cc-langs.el (c-before-font-lock-functions): Replace - c-set-fl-decl-start with c-change-set-fl-decl-start (Renaming). + * progmodes/cc-langs.el (c-before-font-lock-functions): + Replace c-set-fl-decl-start with c-change-set-fl-decl-start (Renaming). (c-before-context-fontification-functions): New defvar, a list of functions to be run just before context (etc.) font locking. @@ -398,22 +414,19 @@ * progmodes/cc-langs (c-label-kwds): Let AWK take the same expression as the rest. - (c-nonlabel-token-key): Allow string literals for AWK. Refactor - for the other modes. + (c-nonlabel-token-key): Allow string literals for AWK. + Refactor for the other modes. Large brace-block initialisation makes CC Mode slow: Fix. - Tidy up and accelerate c-in-literal, etc. by using the - c-parse-state + Tidy up and accelerate c-in-literal, etc. by using the c-parse-state routines. Limit backward searching in c-font-lock-enclosing.decl. * progmodes/cc-engine.el (c-state-pp-to-literal): Return the pp-state and literal type in addition to the limits. - (c-state-safe-place): New defun, extracted from - c-state-literal-at. + (c-state-safe-place): New defun, extracted from c-state-literal-at. (c-state-literal-at): Use the above new defun. - (c-slow-in-literal, c-fast-in-literal): Removed. - (c-in-literal, c-literal-limits): Amended to use - c-state-pp-to-literal. + (c-slow-in-literal, c-fast-in-literal): Remove. + (c-in-literal, c-literal-limits): Amend to use c-state-pp-to-literal. * progmodes/cc-fonts.el (c-font-lock-enclosing-decls): Check for being in a literal. Add a limit for backward searching. @@ -487,8 +500,8 @@ 2011-12-10 Eli Zaretskii <eliz@gnu.org> * mail/rmailsum.el (rmail-header-summary): RFC2047 decode the - `from' or `to' address before taking its substring. Fixes - incorrect display in Rmail summary buffer whereby an RFC2047 + `from' or `to' address before taking its substring. + Fixes incorrect display in Rmail summary buffer whereby an RFC2047 encoded name is chopped in the middle of the encoded string, and thus displayed encoded. @@ -707,8 +720,8 @@ (verilog-uvm-statement-re): Support UVM indentation and highlighting, with old OVM keywords only. (verilog-auto-tieoff, verilog-auto-tieoff-declaration): - Support AUTOTIEOFF creating non-wire data types. Suggested by Jonathan - Greenlaw. + Support AUTOTIEOFF creating non-wire data types. + Suggested by Jonathan Greenlaw. (verilog-auto-insert-lisp, verilog-delete-to-paren) (verilog-forward-sexp-cmt, verilog-forward-sexp-ign-cmt) (verilog-inject-sense, verilog-read-inst-pins) @@ -794,11 +807,11 @@ Andrew Drake. (verilog-auto-star-safe, verilog-delete-auto-star-implicit) (verilog-inst-comment-re): Fix not deleting Interfaced comment - when expanding .* in interfaces, bug320. Reported by Pierre-David - Pfister. + when expanding .* in interfaces, bug320. + Reported by Pierre-David Pfister. (verilog-read-module-name): Fix import statements between module - name and open parenthesis, bug317. Reported by Pierre-David - Pfister. + name and open parenthesis, bug317. + Reported by Pierre-David Pfister. (verilog-simplify-range-expression): Fix simplification of multiplications inside AUTOWIRE connections, bug303. (verilog-auto-inst-port): Support parameter expansion in @@ -1052,8 +1065,7 @@ 2011-11-19 Andreas Schwab <schwab@linux-m68k.org> - * progmodes/sh-script.el (sh-assignment-regexp): Add entry for - bash. + * progmodes/sh-script.el (sh-assignment-regexp): Add entry for bash. 2011-11-19 Juri Linkov <juri@jurta.org> @@ -1178,8 +1190,7 @@ * window.el (window-resize, delete-window, split-window): Replace window-splits by window-combination-resize. - * cus-start.el (window-splits): Replace by - window-combination-resize. + * cus-start.el (window-splits): Replace by window-combination-resize. 2011-11-17 Glenn Morris <rgm@gnu.org> @@ -1244,8 +1255,7 @@ * window.el (split-window, window-state-get-1) (window-state-put-1, window-state-put-2): Rename occurrences of window-nest to window-combination-limit. - * cus-start.el (window-nest): Rename to - window-combination-limit. + * cus-start.el (window-nest): Rename to window-combination-limit. 2011-11-16 Chong Yidong <cyd@gnu.org> diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el index 756010160d2..3d9b30bcbb3 100644 --- a/lisp/minibuffer.el +++ b/lisp/minibuffer.el @@ -571,6 +571,10 @@ in the last `cdr'." (defun completion--replace (beg end newtext) "Replace the buffer text between BEG and END with NEWTEXT. Moves point to the end of the new text." + ;; The properties on `newtext' include things like + ;; completions-first-difference, which we don't want to include + ;; upon insertion. + (set-text-properties 0 (length newtext) nil newtext) ;; Maybe this should be in subr.el. ;; You'd think this is trivial to do, but details matter if you want ;; to keep markers "at the right place" and be robust in the face of diff --git a/lisp/net/tramp-sh.el b/lisp/net/tramp-sh.el index 02f933be367..2478253841f 100644 --- a/lisp/net/tramp-sh.el +++ b/lisp/net/tramp-sh.el @@ -512,6 +512,7 @@ detected as prompt when being sent on echoing hosts, therefore.") ;; GNU/Linux (Debian, Suse): /bin:/usr/bin ;; FreeBSD: /usr/bin:/bin:/usr/sbin:/sbin: - beware trailing ":"! ;; IRIX64: /usr/bin +;;;###tramp-autoload (defcustom tramp-remote-path '(tramp-default-remote-path "/bin" "/usr/bin" "/usr/sbin" "/usr/local/bin" "/local/bin" "/local/freeware/bin" "/local/gnu/bin" diff --git a/lisp/window.el b/lisp/window.el index 8eb0ac3575b..54e5ec9c74c 100644 --- a/lisp/window.el +++ b/lisp/window.el @@ -3568,10 +3568,7 @@ specific buffers." )) ;;; Window states, how to get them and how to put them in a window. -(defvar window-state-ignored-parameters '(quit-restore) - "List of window parameters ignored by `window-state-get'.") - -(defun window--state-get-1 (window &optional markers) +(defun window--state-get-1 (window &optional ignore) "Helper function for `window-state-get'." (let* ((type (cond @@ -3589,12 +3586,27 @@ specific buffers." (normal-width . ,(window-normal-size window t)) (combination-limit . ,(window-combination-limit window)) ,@(let (list) - (dolist (parameter (window-parameters window)) - (unless (memq (car parameter) - window-state-ignored-parameters) - (setq list (cons parameter list)))) - (unless (window-parameter window 'clone-of) - ;; Make a clone-of parameter. + ;; Make copies of persistent window parameters whose cdr + ;; is either t or, when IGNORE is non-nil, is either nil + ;; or `state'. + (dolist (pers window-persistent-parameters) + (when (and (consp pers) + (or (eq (cdr pers) t) + (and (memq (cdr pers) '(state nil)) + (not ignore)))) + (let ((par (assq (car pers) (window-parameters window)))) + (setq list (cons (cons (car pers) (when par (cdr par))) + list))))) + ;; Save `clone-of' parameter unless IGNORE or + ;; `window-persistent-parameters' prevail. + (when (and (not (assq 'clone-of (window-parameters window))) + (let ((clone-of + (assq 'clone-of + window-persistent-parameters))) + (when clone-of + (if ignore + (eq (cdr clone-of) t) + (memq (cdr clone-of) '(state nil)))))) (setq list (cons (cons 'clone-of window) list))) (when list `((parameters . ,list)))) @@ -3616,30 +3628,31 @@ specific buffers." (scroll-bars . ,(window-scroll-bars window)) (vscroll . ,(window-vscroll window)) (dedicated . ,(window-dedicated-p window)) - (point . ,(if markers (copy-marker point) point)) - (start . ,(if markers (copy-marker start) start)) + (point . ,(if ignore point (copy-marker point))) + (start . ,(if ignore start (copy-marker start))) ,@(when mark - `((mark . ,(if markers - (copy-marker mark) mark))))))))))) + `((mark . ,(if ignore + mark (copy-marker mark)))))))))))) (tail (when (memq type '(vc hc)) (let (list) (setq window (window-child window)) (while window - (setq list (cons (window--state-get-1 window markers) list)) + (setq list (cons (window--state-get-1 window ignore) list)) (setq window (window-right window))) (nreverse list))))) (append head tail))) -(defun window-state-get (&optional window markers) +(defun window-state-get (&optional window ignore) "Return state of WINDOW as a Lisp object. WINDOW can be any window and defaults to the root window of the selected frame. -Optional argument MARKERS non-nil means use markers for sampling -positions like `window-point' or `window-start'. MARKERS should -be non-nil only if the value is used for putting the state back -in the same session (note that markers slow down processing). +Optional argument IGNORE non-nil means do not use markers for +sampling positions like `window-point' or `window-start' and do +not record parameters unless `window-persistent-parameters' +requests it. IGNORE should be non-nil when the return value +shall be written to a file and read back in another session. The return value can be used as argument for `window-state-put' to put the state recorded here into an arbitrary window. The @@ -3665,7 +3678,7 @@ value can be also stored on disk and read back in a new session." ;; These are probably not needed. ,@(when (window-size-fixed-p window) `((fixed-height . t))) ,@(when (window-size-fixed-p window t) `((fixed-width . t)))) - (window--state-get-1 window markers))) + (window--state-get-1 window ignore))) (defvar window-state-put-list nil "Helper variable for `window-state-put'.") @@ -3744,10 +3757,15 @@ value can be also stored on disk and read back in a new session." (state (cdr (assq 'buffer item)))) (when combination-limit (set-window-combination-limit window combination-limit)) - ;; Process parameters. + ;; Assign saved window parameters. If a parameter's value is nil, + ;; don't assign it unless the new window has it set already (which + ;; shouldn't happen unless some `window-configuration-change-hook' + ;; function installed it). (when parameters (dolist (parameter parameters) - (set-window-parameter window (car parameter) (cdr parameter)))) + (when (or (cdr parameter) + (window-parameter window (car parameter))) + (set-window-parameter window (car parameter) (cdr parameter))))) ;; Process buffer related state. (when state ;; We don't want to raise an error here so we create a buffer if |
