Now on revision 112185. ------------------------------------------------------------ revno: 112185 committer: Eli Zaretskii branch nick: trunk timestamp: Sat 2013-03-30 09:23:47 +0300 message: Add leim/stamp-subdir to .bzrignore. diff: === modified file '.bzrignore' --- .bzrignore 2013-03-18 04:30:20 +0000 +++ .bzrignore 2013-03-30 06:23:47 +0000 @@ -85,6 +85,7 @@ leim/quail/*.el leim/changed.misc leim/changed.tit +leim/stamp-subdir lib/.deps/ lib/Makefile.in lib/deps/ ------------------------------------------------------------ revno: 112184 committer: Eli Zaretskii branch nick: trunk timestamp: Sat 2013-03-30 09:12:49 +0300 message: Enable the 'copysign' primitive on MS-Windows. nt/inc/ms-w32.h (copysign) [_MSC_VER]: Redirect to _copysign. nt/config.nt (HAVE_COPYSIGN): Define. diff: === modified file 'nt/ChangeLog' --- nt/ChangeLog 2013-03-29 03:02:22 +0000 +++ nt/ChangeLog 2013-03-30 06:12:49 +0000 @@ -1,3 +1,9 @@ +2013-03-29 Eli Zaretskii + + * inc/ms-w32.h (copysign) [_MSC_VER]: Redirect to _copysign. + + * config.nt (HAVE_COPYSIGN): Define. + 2013-03-29 Juanma Barranquero * config.nt: Sync with autogen/config.in. === modified file 'nt/config.nt' --- nt/config.nt 2013-03-29 03:02:22 +0000 +++ nt/config.nt 2013-03-30 06:12:49 +0000 @@ -251,7 +251,7 @@ #undef HAVE_COM_ERR_H /* Define to 1 if you have the `copysign' function. */ -#undef HAVE_COPYSIGN +#define HAVE_COPYSIGN 1 /* Define to 1 if data_start is the address of the start of the main data segment. */ === modified file 'nt/inc/ms-w32.h' --- nt/inc/ms-w32.h 2013-03-27 08:40:24 +0000 +++ nt/inc/ms-w32.h 2013-03-30 06:12:49 +0000 @@ -258,6 +258,7 @@ typedef int pid_t; #define snprintf _snprintf #define strtoll _strtoi64 +#define copysign _copysign #endif #define isatty _isatty #define _longjmp longjmp ------------------------------------------------------------ revno: 112183 committer: Ted Zlatanov branch nick: quickfixes timestamp: Fri 2013-03-29 21:32:12 -0400 message: Move forward-whitespace, forward-symbol, forward-same-syntax commands to subr.el. Use forward-symbol in supermode.el again. * subr.el (forward-whitespace, forward-symbol) (forward-same-syntax): Move from thingatpt.el. * progmodes/subword.el: Back to using `forward-symbol'. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-03-29 14:53:27 +0000 +++ lisp/ChangeLog 2013-03-30 01:32:12 +0000 @@ -1,3 +1,10 @@ +2013-03-30 Teodor Zlatanov + + * progmodes/subword.el: Back to using `forward-symbol'. + + * subr.el (forward-whitespace, forward-symbol) + (forward-same-syntax): Move from thingatpt.el. + 2013-03-29 Leo Liu * kmacro.el (kmacro-to-register): New command. === modified file 'lisp/progmodes/subword.el' --- lisp/progmodes/subword.el 2013-03-29 13:24:19 +0000 +++ lisp/progmodes/subword.el 2013-03-30 01:32:12 +0000 @@ -309,7 +309,7 @@ ;; (defun subword-forward-internal () (if superword-mode - (forward-sexp 1) + (forward-symbol 1) (if (and (save-excursion (let ((case-fold-search nil)) @@ -325,7 +325,7 @@ (defun subword-backward-internal () (if superword-mode - (forward-sexp -1) + (forward-symbol -1) (if (save-excursion (let ((case-fold-search nil)) (re-search-backward subword-backward-regexp nil t))) === modified file 'lisp/subr.el' --- lisp/subr.el 2013-03-20 18:13:00 +0000 +++ lisp/subr.el 2013-03-30 01:32:12 +0000 @@ -3839,6 +3839,58 @@ If SYNTAX is nil, return nil." (and syntax (logand (car syntax) 65535))) +;; Utility motion commands + +;; Whitespace + +(defun forward-whitespace (arg) + "Move point to the end of the next sequence of whitespace chars. +Each such sequence may be a single newline, or a sequence of +consecutive space and/or tab characters. +With prefix argument ARG, do it ARG times if positive, or move +backwards ARG times if negative." + (interactive "^p") + (if (natnump arg) + (re-search-forward "[ \t]+\\|\n" nil 'move arg) + (while (< arg 0) + (if (re-search-backward "[ \t]+\\|\n" nil 'move) + (or (eq (char-after (match-beginning 0)) ?\n) + (skip-chars-backward " \t"))) + (setq arg (1+ arg))))) + +;; Symbols + +(defun forward-symbol (arg) + "Move point to the next position that is the end of a symbol. +A symbol is any sequence of characters that are in either the +word constituent or symbol constituent syntax class. +With prefix argument ARG, do it ARG times if positive, or move +backwards ARG times if negative." + (interactive "^p") + (if (natnump arg) + (re-search-forward "\\(\\sw\\|\\s_\\)+" nil 'move arg) + (while (< arg 0) + (if (re-search-backward "\\(\\sw\\|\\s_\\)+" nil 'move) + (skip-syntax-backward "w_")) + (setq arg (1+ arg))))) + +;; Syntax blocks + +(defun forward-same-syntax (&optional arg) + "Move point past all characters with the same syntax class. +With prefix argument ARG, do it ARG times if positive, or move +backwards ARG times if negative." + (interactive "^p") + (or arg (setq arg 1)) + (while (< arg 0) + (skip-syntax-backward + (char-to-string (char-syntax (char-before)))) + (setq arg (1+ arg))) + (while (> arg 0) + (skip-syntax-forward (char-to-string (char-syntax (char-after)))) + (setq arg (1- arg)))) + + ;;;; Text clones (defun text-clone-maintain (ol1 after beg end &optional _len) === modified file 'lisp/thingatpt.el' --- lisp/thingatpt.el 2013-03-16 22:08:22 +0000 +++ lisp/thingatpt.el 2013-03-30 01:32:12 +0000 @@ -529,60 +529,11 @@ (buffer-substring-no-properties (car boundary-pair) (cdr boundary-pair)))))) -;; Whitespace - -(defun forward-whitespace (arg) - "Move point to the end of the next sequence of whitespace chars. -Each such sequence may be a single newline, or a sequence of -consecutive space and/or tab characters. -With prefix argument ARG, do it ARG times if positive, or move -backwards ARG times if negative." - (interactive "p") - (if (natnump arg) - (re-search-forward "[ \t]+\\|\n" nil 'move arg) - (while (< arg 0) - (if (re-search-backward "[ \t]+\\|\n" nil 'move) - (or (eq (char-after (match-beginning 0)) ?\n) - (skip-chars-backward " \t"))) - (setq arg (1+ arg))))) - ;; Buffer (put 'buffer 'end-op (lambda () (goto-char (point-max)))) (put 'buffer 'beginning-op (lambda () (goto-char (point-min)))) -;; Symbols - -(defun forward-symbol (arg) - "Move point to the next position that is the end of a symbol. -A symbol is any sequence of characters that are in either the -word constituent or symbol constituent syntax class. -With prefix argument ARG, do it ARG times if positive, or move -backwards ARG times if negative." - (interactive "p") - (if (natnump arg) - (re-search-forward "\\(\\sw\\|\\s_\\)+" nil 'move arg) - (while (< arg 0) - (if (re-search-backward "\\(\\sw\\|\\s_\\)+" nil 'move) - (skip-syntax-backward "w_")) - (setq arg (1+ arg))))) - -;; Syntax blocks - -(defun forward-same-syntax (&optional arg) - "Move point past all characters with the same syntax class. -With prefix argument ARG, do it ARG times if positive, or move -backwards ARG times if negative." - (interactive "p") - (or arg (setq arg 1)) - (while (< arg 0) - (skip-syntax-backward - (char-to-string (char-syntax (char-before)))) - (setq arg (1+ arg))) - (while (> arg 0) - (skip-syntax-forward (char-to-string (char-syntax (char-after)))) - (setq arg (1- arg)))) - ;; Aliases (defun word-at-point () ------------------------------------------------------------ revno: 112182 committer: Dmitry Antipov branch nick: trunk timestamp: Fri 2013-03-29 19:50:21 +0400 message: * indent.c (current_column_bol_cache): Remove leftover which is not used in Fmove_to_column any more. (current_column, scan_for_column): Adjust users. * keyboard.c (last_point_position_buffer, last_point_position_window): Remove leftovers which are not used for recording undo any more. (command_loop_1, syms_of_keyboard): Adjust users. * xdisp.c (last_max_ascent): Remove leftover which is not used in redisplay_window any more. (move_it_to): Adjust user. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2013-03-29 03:03:19 +0000 +++ src/ChangeLog 2013-03-29 15:50:21 +0000 @@ -1,3 +1,15 @@ +2013-03-29 Dmitry Antipov + + * indent.c (current_column_bol_cache): Remove leftover which is not + used in Fmove_to_column any more. + (current_column, scan_for_column): Adjust users. + * keyboard.c (last_point_position_buffer, last_point_position_window): + Remove leftovers which are not used for recording undo any more. + (command_loop_1, syms_of_keyboard): Adjust users. + * xdisp.c (last_max_ascent): Remove leftover which is not used in + redisplay_window any more. + (move_it_to): Adjust user. + 2013-03-29 Juanma Barranquero * makefile.w32-in ($(BLD)/filelock.$(O), $(BLD)/filelock.$(O)): === modified file 'src/indent.c' --- src/indent.c 2013-03-28 14:04:49 +0000 +++ src/indent.c 2013-03-29 15:50:21 +0000 @@ -56,11 +56,6 @@ static ptrdiff_t current_column_1 (void); static ptrdiff_t position_indentation (ptrdiff_t); -/* Cache of beginning of line found by the last call of - current_column. */ - -static ptrdiff_t current_column_bol_cache; - /* Get the display table to use for the current buffer. */ struct Lisp_Char_Table * @@ -439,11 +434,6 @@ col += post_tab; } - if (ptr == BEGV_ADDR) - current_column_bol_cache = BEGV; - else - current_column_bol_cache = BYTE_TO_CHAR (PTR_BYTE_POS (ptr)); - last_known_column = col; last_known_column_point = PT; last_known_column_modified = MODIFF; @@ -525,7 +515,6 @@ { ptrdiff_t opoint = PT, opoint_byte = PT_BYTE; scan_newline (PT, PT_BYTE, BEGV, BEGV_BYTE, -1, 1); - current_column_bol_cache = PT; scan = PT, scan_byte = PT_BYTE; SET_PT_BOTH (opoint, opoint_byte); next_boundary = scan; === modified file 'src/keyboard.c' --- src/keyboard.c 2013-03-28 14:04:49 +0000 +++ src/keyboard.c 2013-03-29 15:50:21 +0000 @@ -210,12 +210,6 @@ /* The value of point when the last command was started. */ static ptrdiff_t last_point_position; -/* The buffer that was current when the last command was started. */ -static Lisp_Object last_point_position_buffer; - -/* The window that was selected when the last command was started. */ -static Lisp_Object last_point_position_window; - /* The frame in which the last input event occurred, or Qmacro if the last event came from a macro. We use this to determine when to generate switch-frame events. This may be cleared by functions @@ -1512,8 +1506,6 @@ prev_buffer = current_buffer; prev_modiff = MODIFF; last_point_position = PT; - last_point_position_window = selected_window; - XSETBUFFER (last_point_position_buffer, prev_buffer); /* By default, we adjust point to a boundary of a region that has such a property that should be treated intangible @@ -11047,9 +11039,6 @@ Fset (Qinput_method_exit_on_first_char, Qnil); Fset (Qinput_method_use_echo_area, Qnil); - last_point_position_buffer = Qnil; - last_point_position_window = Qnil; - { int i; int len = sizeof (head_table) / sizeof (head_table[0]); === modified file 'src/xdisp.c' --- src/xdisp.c 2013-03-28 14:04:49 +0000 +++ src/xdisp.c 2013-03-29 15:50:21 +0000 @@ -580,7 +580,7 @@ /* Ascent and height of the last line processed by move_it_to. */ -static int last_max_ascent, last_height; +static int last_height; /* Non-zero if there's a help-echo in the echo area. */ @@ -8925,7 +8925,6 @@ it->current_y += it->max_ascent + it->max_descent; ++it->vpos; last_height = it->max_ascent + it->max_descent; - last_max_ascent = it->max_ascent; it->max_ascent = it->max_descent = 0; } @@ -8952,7 +8951,6 @@ it->current_y += it->max_ascent + it->max_descent; ++it->vpos; last_height = it->max_ascent + it->max_descent; - last_max_ascent = it->max_ascent; } if (backup_data) ------------------------------------------------------------ revno: 112181 fixes bug: http://debbugs.gnu.org/14071 committer: Leo Liu branch nick: trunk timestamp: Fri 2013-03-29 22:53:27 +0800 message: * kmacro.el (kmacro-to-register): New command. (kmacro-execute-from-register): New function. (kmacro-keymap): Bind to 'x'. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-03-29 14:23:24 +0000 +++ lisp/ChangeLog 2013-03-29 14:53:27 +0000 @@ -1,3 +1,9 @@ +2013-03-29 Leo Liu + + * kmacro.el (kmacro-to-register): New command. + (kmacro-execute-from-register): New function. + (kmacro-keymap): Bind to 'x'. (Bug#14071) + 2013-03-29 Stefan Monnier * mpc.el: Use defvar-local and setq-local. === modified file 'lisp/kmacro.el' --- lisp/kmacro.el 2013-01-01 09:11:05 +0000 +++ lisp/kmacro.el 2013-03-29 14:53:27 +0000 @@ -202,6 +202,7 @@ ;; naming and binding (define-key map "b" 'kmacro-bind-to-key) (define-key map "n" 'kmacro-name-last-macro) + (define-key map "x" 'kmacro-to-register) map) "Keymap for keyboard macro commands.") (defalias 'kmacro-keymap kmacro-keymap) @@ -836,6 +837,26 @@ (put symbol 'kmacro t)) +(defun kmacro-execute-from-register (k) + (let ((last-kbd-macro k)) + (kmacro-call-macro current-prefix-arg))) + +(defun kmacro-to-register (r) + "Store the last keyboard macro in register R." + (interactive + (progn + (or last-kbd-macro (error "No keyboard macro defined")) + (list (read-char "Save to register: ")))) + (set-register r (registerv-make + last-kbd-macro + :jump-func 'kmacro-execute-from-register + :print-func (lambda (k) + (princ (format "a keyboard macro:\n %s" + (format-kbd-macro k)))) + :insert-func (lambda (k) + (insert (format-kbd-macro k)))))) + + (defun kmacro-view-macro (&optional _arg) "Display the last keyboard macro. If repeated, it shows previous elements in the macro ring." ------------------------------------------------------------ revno: 112180 committer: Stefan Monnier branch nick: trunk timestamp: Fri 2013-03-29 10:23:24 -0400 message: * lisp/mpc.el: Use defvar-local and setq-local. (mpc--proc-connect): Connection failures are not bugs. (mpc-mode-map): `follow-link' only applies to the buffer's content. (mpc-volume-map): Bind to the up-events. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-03-29 13:24:19 +0000 +++ lisp/ChangeLog 2013-03-29 14:23:24 +0000 @@ -1,3 +1,10 @@ +2013-03-29 Stefan Monnier + + * mpc.el: Use defvar-local and setq-local. + (mpc--proc-connect): Connection failures are not bugs. + (mpc-mode-map): `follow-link' only applies to the buffer's content. + (mpc-volume-map): Bind to the up-events. + 2013-03-29 Teodor Zlatanov * progmodes/subword.el (superword-mode): Use `forward-sexp' === modified file 'lisp/mpc.el' --- lisp/mpc.el 2013-01-02 16:13:04 +0000 +++ lisp/mpc.el 2013-03-29 14:23:24 +0000 @@ -192,7 +192,7 @@ ;; to the fact that MPD tends to disconnect fairly often, although our ;; constant polling often prevents disconnection. (defvar mpc--find-memoize (make-hash-table :test 'equal)) ;; :weakness t -(defvar mpc-tag nil) (make-variable-buffer-local 'mpc-tag) +(defvar-local mpc-tag nil) ;;; Support for the actual connection and MPD command execution ;;;;;;;;;;;; @@ -279,7 +279,9 @@ (erase-buffer) (let* ((coding-system-for-read 'utf-8-unix) (coding-system-for-write 'utf-8-unix) - (proc (open-network-stream "MPC" (current-buffer) host port))) + (proc (condition-case err + (open-network-stream "MPC" (current-buffer) host port) + (error (user-error (error-message-string err)))))) (when (processp mpc-proc) ;; Inherit the properties of the previous connection. (let ((plist (process-plist mpc-proc))) @@ -1079,7 +1081,11 @@ (define-key map [C-mouse-2] 'mpc-select-toggle) (define-key map [drag-mouse-2] 'mpc-drag-n-drop) ;; We use `always' because a binding to t is like a binding to nil. - (define-key map [follow-link] 'always) + (define-key map [follow-link] :always) + ;; But follow-link doesn't apply blindly to header-line and + ;; mode-line clicks. + (define-key map [header-line follow-link] 'ignore) + (define-key map [mode-line follow-link] 'ignore) ;; Doesn't work because the first click changes the buffer, so the second ;; is applied elsewhere :-( ;; (define-key map [(double mouse-2)] 'mpc-play-at-point) @@ -1136,17 +1142,18 @@ "Major mode for the features common to all buffers of MPC." (buffer-disable-undo) (setq buffer-read-only t) - (set (make-local-variable 'tool-bar-map) mpc-tool-bar-map) - (set (make-local-variable 'truncate-lines) t)) + (setq-local tool-bar-map mpc-tool-bar-map) + (setq-local truncate-lines t)) ;;; The mpc-status-mode buffer ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (define-derived-mode mpc-status-mode mpc-mode "MPC-Status" "Major mode to display MPC status info." - (set (make-local-variable 'mode-line-format) - '("%e" mode-line-frame-identification mode-line-buffer-identification)) - (set (make-local-variable 'window-area-factor) 3) - (set (make-local-variable 'header-line-format) '("MPC " mpc-volume))) + (setq-local mode-line-format + '("%e" mode-line-frame-identification + mode-line-buffer-identification)) + (setq-local window-area-factor 3) + (setq-local header-line-format '("MPC " mpc-volume))) (defvar mpc-status-buffer-format '("%-5{Time} / %{Duration} %2{Disc--}%4{Track}" "%{Title}" "%{Album}" "%{Artist}" "%128{Cover}")) @@ -1188,8 +1195,7 @@ (defvar mpc-separator-ol nil) -(defvar mpc-select nil) -(make-variable-buffer-local 'mpc-select) +(defvar-local mpc-select nil) (defmacro mpc-select-save (&rest body) "Execute BODY and restore the selection afterwards." @@ -1420,20 +1426,18 @@ ;;; The TagBrowser mode ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (defconst mpc-tagbrowser-all-name (propertize "*ALL*" 'face 'italic)) -(defvar mpc-tagbrowser-all-ol nil) -(make-variable-buffer-local 'mpc-tagbrowser-all-ol) -(defvar mpc-tag-name nil) (make-variable-buffer-local 'mpc-tag-name) +(defvar-local mpc-tagbrowser-all-ol nil) +(defvar-local mpc-tag-name nil) (defun mpc-tagbrowser-all-p () (and (eq (point-min) (line-beginning-position)) (equal mpc-tagbrowser-all-name (buffer-substring (point-min) (line-end-position))))) (define-derived-mode mpc-tagbrowser-mode mpc-mode '("MPC-" mpc-tag-name) - (set (make-local-variable 'mode-line-process) '("" mpc-tag-name)) - (set (make-local-variable 'mode-line-format) nil) - (set (make-local-variable 'header-line-format) '("" mpc-tag-name ;; "s" - )) - (set (make-local-variable 'buffer-undo-list) t) + (setq-local mode-line-process '("" mpc-tag-name)) + (setq-local mode-line-format nil) + (setq-local header-line-format '("" mpc-tag-name)) ;; "s" + (setq-local buffer-undo-list t) ) (defun mpc-tagbrowser-refresh () @@ -1539,14 +1543,14 @@ (let ((ol (make-overlay (point) (line-beginning-position 2)))) (overlay-put ol 'face 'region) (overlay-put ol 'evaporate t) - (set (make-local-variable 'mpc-tagbrowser-all-ol) ol)))))) + (setq-local mpc-tagbrowser-all-ol ol)))))) ;; (defvar mpc-constraints nil) (defun mpc-separator (active) ;; Place a separator mark. (unless mpc-separator-ol - (set (make-local-variable 'mpc-separator-ol) - (make-overlay (point) (point))) + (setq-local mpc-separator-ol + (make-overlay (point) (point))) (overlay-put mpc-separator-ol 'after-string (propertize "\n" 'face '(:height 0.05 :inverse-video t)))) @@ -1605,7 +1609,7 @@ (let ((constraints (mpc-constraints-get-current (current-buffer))) (active 'all)) ;; (unless (equal constraints mpc-constraints) - ;; (set (make-local-variable 'mpc-constraints) constraints) + ;; (setq-local mpc-constraints constraints) (dolist (cst constraints) (let ((vals (apply 'mpc-union (mapcar (lambda (val) @@ -1672,7 +1676,7 @@ ;; '(mpc-tagbrowser-dir-hide-prefix)) (define-derived-mode mpc-tagbrowser-dir-mode mpc-tagbrowser-mode '("MPC-" mpc-tag-name) - ;; (set (make-local-variable 'font-lock-defaults) + ;; (setq-local font-lock-defaults ;; '(mpc-tagbrowser-dir-keywords t)) ) @@ -1705,10 +1709,9 @@ ;;; Playlist management ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -(defvar mpc-songs-playlist nil +(defvar-local mpc-songs-playlist nil "Name of the currently selected playlist, if any. A value of t means the main playlist.") -(make-variable-buffer-local 'mpc-songs-playlist) (defun mpc-playlist-create (name) "Save current playlist under name NAME." @@ -1775,12 +1778,14 @@ (defvar mpc-volume-map (let ((map (make-sparse-keymap))) - (define-key map [down-mouse-1] 'mpc-volume-mouse-set) - (define-key map [mouse-1] 'ignore) - (define-key map [header-line down-mouse-1] 'mpc-volume-mouse-set) - (define-key map [header-line mouse-1] 'ignore) - (define-key map [mode-line down-mouse-1] 'mpc-volume-mouse-set) - (define-key map [mode-line mouse-1] 'ignore) + ;; Bind the up-events rather than the down-event, so the + ;; `message' isn't canceled by the subsequent up-event binding. + (define-key map [down-mouse-1] 'ignore) + (define-key map [mouse-1] 'mpc-volume-mouse-set) + (define-key map [header-line mouse-1] 'mpc-volume-mouse-set) + (define-key map [header-line down-mouse-1] 'ignore) + (define-key map [mode-line mouse-1] 'mpc-volume-mouse-set) + (define-key map [mode-line down-mouse-1] 'ignore) map)) (defvar mpc-volume nil) (put 'mpc-volume 'risky-local-variable t) @@ -1945,9 +1950,9 @@ (search-backward (cdr curline) nil t)) (beginning-of-line) (goto-char (point-min))) - (set (make-local-variable 'mpc-songs-totaltime) - (unless (zerop totaltime) - (list " " (mpc-secs-to-time totaltime)))) + (setq-local mpc-songs-totaltime + (unless (zerop totaltime) + (list " " (mpc-secs-to-time totaltime)))) )))) (let ((mpc-songpointer-set-visible t)) (mpc-songpointer-refresh))) @@ -2056,46 +2061,47 @@ (define-derived-mode mpc-songs-mode mpc-mode "MPC-song" (setq mpc-songs-format-description (with-temp-buffer (mpc-format mpc-songs-format 'self) (buffer-string))) - (set (make-local-variable 'header-line-format) - ;; '("MPC " mpc-volume " " mpc-current-song) - (list (propertize " " 'display '(space :align-to 0)) - ;; 'mpc-songs-format-description - '(:eval - (let ((hscroll (window-hscroll))) - (with-temp-buffer - (mpc-format mpc-songs-format 'self hscroll) - ;; That would be simpler than the hscroll handling in - ;; mpc-format, but currently move-to-column does not - ;; recognize :space display properties. - ;; (move-to-column hscroll) - ;; (delete-region (point-min) (point)) - (buffer-string)))))) - (set (make-local-variable 'mode-line-format) - '("%e" mode-line-frame-identification mode-line-buffer-identification - #(" " 0 3 - (help-echo "mouse-1: Select (drag to resize)\nmouse-2: Make current window occupy the whole frame\nmouse-3: Remove current window from display")) - mode-line-position - #(" " 0 2 - (help-echo "mouse-1: Select (drag to resize)\nmouse-2: Make current window occupy the whole frame\nmouse-3: Remove current window from display")) - mpc-songs-totaltime - mpc-current-updating - #(" " 0 2 - (help-echo "mouse-1: Select (drag to resize)\nmouse-2: Make current window occupy the whole frame\nmouse-3: Remove current window from display")) - (mpc--song-search - (:propertize - ("Search=\"" mpc--song-search "\"") - help-echo "mouse-2: kill this search" - follow-link t - mouse-face mode-line-highlight - keymap (keymap (mode-line keymap - (mouse-2 . mpc-songs-kill-search)))) - (:propertize "NoSearch" - help-echo "mouse-2: set a search restriction" - follow-link t - mouse-face mode-line-highlight - keymap (keymap (mode-line keymap (mouse-2 . mpc-songs-search))))))) + (setq-local header-line-format + ;; '("MPC " mpc-volume " " mpc-current-song) + (list (propertize " " 'display '(space :align-to 0)) + ;; 'mpc-songs-format-description + '(:eval + (let ((hscroll (window-hscroll))) + (with-temp-buffer + (mpc-format mpc-songs-format 'self hscroll) + ;; That would be simpler than the hscroll handling in + ;; mpc-format, but currently move-to-column does not + ;; recognize :space display properties. + ;; (move-to-column hscroll) + ;; (delete-region (point-min) (point)) + (buffer-string)))))) + (setq-local + mode-line-format + '("%e" mode-line-frame-identification mode-line-buffer-identification + #(" " 0 3 + (help-echo "mouse-1: Select (drag to resize)\nmouse-2: Make current window occupy the whole frame\nmouse-3: Remove current window from display")) + mode-line-position + #(" " 0 2 + (help-echo "mouse-1: Select (drag to resize)\nmouse-2: Make current window occupy the whole frame\nmouse-3: Remove current window from display")) + mpc-songs-totaltime + mpc-current-updating + #(" " 0 2 + (help-echo "mouse-1: Select (drag to resize)\nmouse-2: Make current window occupy the whole frame\nmouse-3: Remove current window from display")) + (mpc--song-search + (:propertize + ("Search=\"" mpc--song-search "\"") + help-echo "mouse-2: kill this search" + follow-link t + mouse-face mode-line-highlight + keymap (keymap (mode-line keymap + (mouse-2 . mpc-songs-kill-search)))) + (:propertize "NoSearch" + help-echo "mouse-2: set a search restriction" + follow-link t + mouse-face mode-line-highlight + keymap (keymap (mode-line keymap (mouse-2 . mpc-songs-search))))))) - ;; (set (make-local-variable 'mode-line-process) + ;; (setq-local mode-line-process ;; '("" ;; mpc-volume " " ;; mpc-songs-totaltime ;; mpc-current-updating)) @@ -2111,7 +2117,7 @@ (<= (window-start win) overlay-arrow-position) (< overlay-arrow-position (window-end win))))))) (unless (local-variable-p 'overlay-arrow-position) - (set (make-local-variable 'overlay-arrow-position) (make-marker))) + (setq-local overlay-arrow-position (make-marker))) (move-marker overlay-arrow-position pos) ;; If the arrow was visible, try to keep it that way. (if (and visible pos @@ -2613,8 +2619,8 @@ (window-minibuffer-p)) (ignore-errors (select-frame (make-frame mpc-frame-alist))) (with-current-buffer song-buf - (set (make-local-variable 'mpc-previous-window-config) - (current-window-configuration)))) + (setq-local mpc-previous-window-config + (current-window-configuration)))) (let* ((win1 (selected-window)) (win2 (split-window)) (tags mpc-browser-tags)) ------------------------------------------------------------ revno: 112179 author: Andrew Cohen committer: Katsumi Yamaoka branch nick: trunk timestamp: Fri 2013-03-29 14:12:58 +0000 message: lisp/gnus/nnir.el: Allow nnir group creation based on an existing query diff: === modified file 'lisp/gnus/ChangeLog' --- lisp/gnus/ChangeLog 2013-03-28 01:36:23 +0000 +++ lisp/gnus/ChangeLog 2013-03-29 14:12:58 +0000 @@ -1,3 +1,11 @@ +2013-03-29 Andrew Cohen + + * nnir.el: Define 'number-sequence for xemacs. + (gnus-summary-create-nnir-group): New function to create an nnir group + from an nnir summary buffer based on the current query. + (nnir-request-create-group): Update to allow nnir group creation based + on the current query. + 2013-03-28 Katsumi Yamaoka * nndraft.el (nndraft-request-expire-articles): === modified file 'lisp/gnus/nnir.el' --- lisp/gnus/nnir.el 2013-03-27 01:17:08 +0000 +++ lisp/gnus/nnir.el 2013-03-29 14:12:58 +0000 @@ -173,7 +173,15 @@ ;; For Emacs <22.2 and XEmacs. (eval-and-compile - (unless (fboundp 'declare-function) (defmacro declare-function (&rest r)))) + (unless (fboundp 'declare-function) (defmacro declare-function (&rest r))) + (unless (fboundp 'number-sequence) + (defun number-sequence (from to) + (let (seq (n 0) (next from)) + (while (<= next to) + (setq seq (cons next seq) + n (1+ n) + next (+ from n ))) + (nreverse seq))))) (require 'nnoo) (require 'gnus-group) @@ -1840,24 +1848,38 @@ (add-hook 'gnus-summary-article-expire-hook 'nnir-registry-action t t)))) +(defun gnus-summary-create-nnir-group () + (interactive) + (let ((name (gnus-read-group "Group name: ")) + (method "nnir") + (pgroup (if (gnus-group-prefixed-p gnus-newsgroup-name) + gnus-newsgroup-name + (gnus-group-prefixed-name + gnus-newsgroup-name '(nnir "nnir"))))) + (with-current-buffer gnus-group-buffer + (gnus-group-make-group + name method nil + (gnus-group-find-parameter pgroup))))) + (deffoo nnir-request-create-group (group &optional server args) (message "Creating nnir group %s" group) - (let ((group (gnus-group-prefixed-name group '(nnir "nnir"))) - (query-spec - (list (cons 'query - (read-string "Query: " nil 'nnir-search-history)))) - (group-spec (list (list (read-string "Server: " nil nil))))) - (gnus-group-set-parameter - group 'nnir-specs - (list (cons 'nnir-query-spec query-spec) - (cons 'nnir-group-spec group-spec))) + (let* ((group (gnus-group-prefixed-name group '(nnir "nnir"))) + (specs (assoc 'nnir-specs args)) + (query-spec + (or (cdr (assoc 'nnir-query-spec specs)) + (list (cons 'query + (read-string "Query: " nil 'nnir-search-history))))) + (group-spec + (or (cdr (assoc 'nnir-group-spec specs)) + (list (list (read-string "Server: " nil nil))))) + (nnir-specs (list (cons 'nnir-query-spec query-spec) + (cons 'nnir-group-spec group-spec)))) + (gnus-group-set-parameter group 'nnir-specs nnir-specs) (gnus-group-set-parameter group 'nnir-artlist - (setq nnir-artlist - (nnir-run-query - (list (cons 'nnir-query-spec query-spec) - (cons 'nnir-group-spec group-spec))))) + (or (cdr (assoc 'nnir-artlist args)) + (nnir-run-query nnir-specs))) (nnir-request-update-info group (gnus-get-info group))) t) ------------------------------------------------------------ revno: 112178 committer: Ted Zlatanov branch nick: quickfixes timestamp: Fri 2013-03-29 09:24:19 -0400 message: * progmodes/subword.el (superword-mode): Use `forward-sexp' instead of `forward-symbol'. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-03-28 16:33:06 +0000 +++ lisp/ChangeLog 2013-03-29 13:24:19 +0000 @@ -1,3 +1,8 @@ +2013-03-29 Teodor Zlatanov + + * progmodes/subword.el (superword-mode): Use `forward-sexp' + instead of `forward-symbol'. + 2013-03-28 Stefan Monnier * emacs-lisp/edebug.el (edebug-mode): Make it a minor mode. === modified file 'lisp/progmodes/subword.el' --- lisp/progmodes/subword.el 2013-03-27 14:04:34 +0000 +++ lisp/progmodes/subword.el 2013-03-29 13:24:19 +0000 @@ -154,7 +154,7 @@ "Do the same as `forward-word' but on subwords. See the command `subword-mode' for a description of subwords. Optional argument ARG is the same as for `forward-word'." - (interactive "p") + (interactive "^p") (unless arg (setq arg 1)) (cond ((< 0 arg) @@ -168,16 +168,26 @@ (put 'subword-forward 'CUA 'move) -(defalias 'subword-right 'subword-forward) - (defun subword-backward (&optional arg) "Do the same as `backward-word' but on subwords. See the command `subword-mode' for a description of subwords. Optional argument ARG is the same as for `backward-word'." - (interactive "p") + (interactive "^p") (subword-forward (- (or arg 1)))) -(defalias 'subword-left 'subword-backward) +(defun subword-right (&optional arg) + "Do the same as `right-word' but on subwords." + (interactive "^p") + (if (eq (current-bidi-paragraph-direction) 'left-to-right) + (subword-forward arg) + (subword-backward arg))) + +(defun subword-left (&optional arg) + "Do the same as `left-word' but on subwords." + (interactive "^p") + (if (eq (current-bidi-paragraph-direction) 'left-to-right) + (subword-backward arg) + (subword-forward arg))) (defun subword-mark (arg) "Do the same as `mark-word' but on subwords. @@ -299,7 +309,7 @@ ;; (defun subword-forward-internal () (if superword-mode - (forward-symbol 1) + (forward-sexp 1) (if (and (save-excursion (let ((case-fold-search nil)) @@ -315,7 +325,7 @@ (defun subword-backward-internal () (if superword-mode - (forward-symbol -1) + (forward-sexp -1) (if (save-excursion (let ((case-fold-search nil)) (re-search-backward subword-backward-regexp nil t))) ------------------------------------------------------------ revno: 112177 committer: Aidan Gauland branch nick: trunk timestamp: Fri 2013-03-29 20:12:11 +1300 message: Added entry to NEWS for em-tramp change in r112148 diff: === modified file 'ChangeLog' --- ChangeLog 2013-03-29 07:08:36 +0000 +++ ChangeLog 2013-03-29 07:12:11 +0000 @@ -1,3 +1,7 @@ +2013-03-29 Aidan Gauland + + * etc/NEWS: Added entry for em-tramp change in r112148 + 2013-03-27 Paul Eggert * configure.ac (HAVE_XKBGETKEYBOARD): Remove. === modified file 'etc/NEWS' --- etc/NEWS 2013-03-27 14:33:03 +0000 +++ etc/NEWS 2013-03-29 07:12:11 +0000 @@ -239,6 +239,13 @@ *** The commands `woman-default-faces' and `woman-monochrome-faces' are obsolete. Customize the `woman-* faces instead. +** Eshell + +*** Added Eshell-TRAMP module +External su and sudo commands are now the default; the internal, +TRAMP-using variants can still be used by enabling the eshell-tramp +module. + ** Obsolete packages: *** longlines.el is obsolete; use visual-line-mode instead. ------------------------------------------------------------ revno: 112176 committer: Aidan Gauland branch nick: trunk timestamp: Fri 2013-03-29 20:08:36 +1300 message: Corrected type in ChangeLog Missing > after email address. diff: === modified file 'ChangeLog' --- ChangeLog 2013-03-27 05:13:31 +0000 +++ ChangeLog 2013-03-29 07:08:36 +0000 @@ -3,7 +3,7 @@ * configure.ac (HAVE_XKBGETKEYBOARD): Remove. Subsumed by HAVE_XKB. All uses changed. -2013-03-27 Aidan Gauland * lisp/eshell/em-unix.el: Moved su and sudo to... * lisp/eshell/em-tramp.el: ...Eshell tramp module ------------------------------------------------------------ revno: 112175 committer: Juanma Barranquero branch nick: trunk timestamp: Fri 2013-03-29 04:03:19 +0100 message: src/makefile.w32-in: Update dependencies. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2013-03-28 16:21:38 +0000 +++ src/ChangeLog 2013-03-29 03:03:19 +0000 @@ -1,3 +1,8 @@ +2013-03-29 Juanma Barranquero + + * makefile.w32-in ($(BLD)/filelock.$(O), $(BLD)/filelock.$(O)): + Update dependencies. + 2013-03-28 Stefan Monnier * lisp.h (save_type, XSAVE_POINTER, set_save_pointer, XSAVE_INTEGER) === modified file 'src/makefile.w32-in' --- src/makefile.w32-in 2013-02-25 17:36:03 +0000 +++ src/makefile.w32-in 2013-03-29 03:03:19 +0000 @@ -873,6 +873,7 @@ $(CHARACTER_H) \ $(CODING_H) \ $(CONFIG_H) \ + $(C_CTYPE_H) \ $(LISP_H) \ $(SYSTIME_H) @@ -1398,6 +1399,7 @@ $(NT_INC)/netdb.h \ $(NT_INC)/pwd.h \ $(NT_INC)/sys/file.h \ + $(NT_INC)/sys/param.h \ $(NT_INC)/sys/stat.h \ $(NT_INC)/unistd.h \ $(GNU_LIB)/execinfo.h \