Katsumi Yamaoka [Thu, 6 May 2010 03:27:20 +0000 (03:27 +0000)]
Synch with Gnus trunk.
(mml-generate-mime-1,mml-compute-boundary-1): Update 'mml
handles on recursive mml-to-mime translation and check them for
boundary delimiter collisions. Reported by: Greg Troxel.
Stefan Monnier [Thu, 6 May 2010 02:59:07 +0000 (22:59 -0400)]
Extract common suffix for * in partial-completion.
* minibuffer.el (completion--sreverse, completion--common-suffix):
New functions.
(completion-pcm--merge-completions): Extract common suffix when safe.
Stefan Monnier [Thu, 6 May 2010 02:53:56 +0000 (22:53 -0400)]
Define auto-save-mode with define-minor-mode.
* emacs-lisp/easy-mmode.el (define-minor-mode):
Make :variable more flexible.
* files.el (auto-save-mode): Use it to define using define-minor-mode.
Juri Linkov [Wed, 5 May 2010 21:56:15 +0000 (00:56 +0300)]
Add `slow' and `history' tags to the desktop data.
* info.el (Info-virtual-nodes) [*Index*]: Add `slow' tag.
(Info-virtual-files) [*Apropos*]: Add `slow' tag.
(Info-finder-find-node): Require `finder.el' to be able
to restore node from the desktop.
(Info-desktop-buffer-misc-data): Save all nodes. Save additional
data `Info-history' and `slow' tag in the assoc list.
(Info-restore-desktop-buffer): Don't restore nodes with the
`slow' tag. Restore `Info-history'.
Michael Albinus [Wed, 5 May 2010 10:20:23 +0000 (12:20 +0200)]
Add FORCE argument to `delete-file'.
* net/ange-ftp.el (ange-ftp-del-tmp-name): Make it a defun,
forcing to delete the temporary file.
(ange-ftp-delete-file): Add FORCE arg.
(ange-ftp-rename-remote-to-remote)
(ange-ftp-rename-local-to-remote, ange-ftp-rename-remote-to-local)
(ange-ftp-load, ange-ftp-compress, ange-ftp-uncompress): Force
file deletion.
* net/tramp-compat.el (tramp-compat-delete-file): New defun.
* net/tramp.el (tramp-handle-delete-file): Add FORCE arg.
(tramp-handle-make-symbolic-link, tramp-handle-load)
(tramp-do-copy-or-rename-file-via-buffer)
(tramp-do-copy-or-rename-file-directly)
(tramp-do-copy-or-rename-file-out-of-band)
(tramp-handle-process-file, tramp-handle-call-process-region)
(tramp-handle-shell-command, tramp-handle-file-local-copy)
(tramp-handle-insert-file-contents, tramp-handle-write-region)
(tramp-delete-temp-file-function): Use `tramp-compat-delete-file'.
* net/tramp-fish.el (tramp-fish-handle-delete-file): Add FORCE arg.
(tramp-fish-handle-make-symbolic-link)
(tramp-fish-handle-process-file): Use `tramp-compat-delete-file'.
* net/tramp-ftp.el (tramp-ftp-file-name-handler): Use
`tramp-compat-delete-file'.
* net/tramp-gvfs.el (tramp-gvfs-handle-delete-file): Add FORCE arg.
(tramp-gvfs-handle-write-region): Use `tramp-compat-delete-file'.
* net/tramp-imap.el (tramp-imap-handle-delete-file): Add FORCE arg.
(tramp-imap-do-copy-or-rename-file): Use `tramp-compat-delete-file'.
* net/tramp-smb.el (tramp-smb-handle-delete-file): Add FORCE arg.
(tramp-smb-handle-copy-file, tramp-smb-handle-file-local-copy)
(tramp-smb-handle-rename-file, tramp-smb-handle-write-region): Use
`tramp-compat-delete-file'.
Stefan Monnier [Wed, 5 May 2010 03:45:21 +0000 (23:45 -0400)]
Use define-minor-mode in more cases.
* term/tvi970.el (tvi970-set-keypad-mode):
* simple.el (auto-fill-mode, overwrite-mode, binary-overwrite-mode)
(normal-erase-is-backspace-mode):
* scroll-bar.el (scroll-bar-mode): Use it and define-minor-mode.
(set-scroll-bar-mode-1): (Re)move to its sole caller.
(get-scroll-bar-mode): New function.
* emacs-lisp/cl-macs.el (eq): Handle a non-variable first arg.
Glenn Morris [Tue, 4 May 2010 03:26:38 +0000 (20:26 -0700)]
Yet another missing piece of C_SWITCH commit.
* Makefile.in (C_SWITCH_SYSTEM): Use @C_SWITCH_SYSTEM@ rather than
@c_switch_system@.
* oldXMenu/Makefile.in (C_SWITCH_SYSTEM, C_SWITCH_MACHINE): Use
@C_SWITCH_SYSTEM@, @C_SWITCH_MACHINE@ rather than
@c_switch_system@, @c_switch_machine@.
Glenn Morris [Tue, 4 May 2010 03:13:35 +0000 (20:13 -0700)]
Move LD_SWITCH_X_SITE_AUX from cpp to autoconf.
* configure.in (LD_SWITCH_X_SITE_AUX): Use AC_SUBST only, not AC_DEFINE as well.
(LD_SWITCH_X_SITE_AUX_RPATH): New output variable.
* nt/config.nt (LD_SWITCH_X_SITE_AUX): Remove.
* src/s/gnu-linux.h (LD_SWITCH_SYSTEM): Use LD_SWITCH_X_SITE_AUX as a shell
variable.
* src/s/netbsd.h (LD_SWITCH_SYSTEM_tmp): Remove.
(LD_SWITCH_SYSTEM): Use $LD_SWITCH_X_SITE_AUX_RPATH.
* src/s/openbsd.h (LD_SWITCH_SYSTEM_tmp): Remove.
(LD_SWITCH_SYSTEM): Use $LD_SWITCH_X_SITE_AUX_RPATH instead of
LD_SWITCH_SYSTEM_tmp.
* src/Makefile.in (LD_SWITCH_X_SITE_AUX, LD_SWITCH_X_SITE_AUX_RPATH):
New variables, set by configure.
Glenn Morris [Tue, 4 May 2010 03:06:27 +0000 (20:06 -0700)]
Move LD_SWITCH_SYSTEM_TEMACS from cpp to autoconf.
* configure.in (LD_SWITCH_SYSTEM_TEMACS): New output variable.
* src/s/aix4-2.h (LD_SWITCH_SYSTEM_TEMACS): Move to configure.in.
* src/s/darwin.h (HEADERPAD_EXTRA, LIBS_NSGUI): Remove.
(LD_SWITCH_SYSTEM_TEMACS): Move to configure.in.
* src/Makefile.in (LD_SWITCH_SYSTEM_TEMACS): New variable, set by configure.
(TEMACS_LDFLAGS): Use $LD_SWITCH_SYSTEM_TEMACS.
Glenn Morris [Tue, 4 May 2010 02:56:19 +0000 (19:56 -0700)]
Move C_SWITCH_MACHINE, C_SWITCH_SYSTEM from cpp to autoconf.
* configure.in (C_SWITCH_MACHINE, C_SWITCH_SYSTEM): New output
variables, replacing c_switch_machine, c_switch_system.
* src/s/aix4-2.h (C_SWITCH_SYSTEM):
* src/m/alpha.h (C_SWITCH_MACHINE):
Move to configure.in.
* src/Makefile.in (C_SWITCH_MACHINE, C_SWITCH_SYSTEM):
New variables, set by configure.
(ALL_CFLAGS): Use $C_SWITCH_MACHINE and $C_SWITCH_SYSTEM in place of
$c_switch_machine and $c_switch_system.
* lib-src/Makefile.in: Use @C_SWITCH_SYSTEM@, @C_SWITCH_MACHINE@
rather than @c_switch_system@, @c_switch_machine@.
Glenn Morris [Mon, 3 May 2010 02:10:43 +0000 (19:10 -0700)]
Replace some X-related cpp with autoconf.
* configure.in (LIBXT_OTHER, LIBX_OTHER): New output variables.
* src/Makefile.in (LIBX_EXTRA, LIBX_BASE): New variables.
(LIBXT_OTHER, LIBX_OTHER): New, set by configure.
(LIBXT): Set with configure, not cpp.
(LIBX): Remove.
(LIBES): Replace $LIBX with $LIBX_BASE and $LIBX_OTHER.
Stefan Monnier [Mon, 3 May 2010 00:41:45 +0000 (20:41 -0400)]
Use define-minor-mode in Gnus where applicable.
* mml.el (mml-mode): Use define-minor-mode.
* gnus-undo.el (gnus-undo-mode-map): Initialize in declaration.
(gnus-undo-mode): Use define-minor-mode.
* gnus-sum.el (gnus-dead-summary-mode-map): Initialize in declaration.
(gnus-dead-summary-mode): Use define-minor-mode.
* gnus-salt.el (gnus-pick-mode-map, gnus-binary-mode-map):
Initialize in declaration.
(gnus-pick-mode, gnus-binary-mode): Use define-minor-mode.
* gnus-ml.el (gnus-mailing-list-mode-map): Initialize in declaration.
(gnus-mailing-list-mode): Use define-minor-mode.
* gnus-draft.el (gnus-draft-mode-map): Initialize in declaration.
(gnus-draft-mode): Use define-minor-mode.
* gnus-dired.el (gnus-dired-mode-map): Initialize in declaration.
(gnus-dired-mode): Use define-minor-mode.
Dan Nicolaescu [Sun, 2 May 2010 19:32:18 +0000 (12:32 -0700)]
* m/amdx86-64.h (START_FILES, LIB_STANDARD): Remove.
The FreeBSD is not needed, the default works, Solaris version is
not needed, and the remaining case is not supported by configure.
Stefan Monnier [Sun, 2 May 2010 05:56:30 +0000 (01:56 -0400)]
New hook filter-buffer-substring-functions.
* simple.el (with-wrapper-hook): Move.
(buffer-substring-filters): Mark obsolete.
(filter-buffer-substring-functions): New variable.
(buffer-substring-filters): Use it. Remove unused arg `noprops'.
Stefan Monnier [Sun, 2 May 2010 05:06:53 +0000 (01:06 -0400)]
Use a mode-line spec rather than a static string in Semantic.
* cedet/semantic/util-modes.el:
(semantic-minor-modes-format): New var to replace...
(semantic-minor-modes-status): Remove.
(semantic-mode-line-update): Construct a mode-line spec rather than
a static string so that mouse buttons can be used on individual minor
modes and so that semantic-mode-line-update only needs to be called
when global settings are changed.
(semantic-add-minor-mode, semantic-toggle-minor-mode-globally):
Call semantic-mode-line-update.
(semantic-toggle-minor-mode-globally): Don't assume mode is on
minor-mode-alist, check semantic-minor-mode-alist as well.
(semantic-stickyfunc-mode, semantic-show-parser-state-auto-marker)
(semantic-show-parser-state-marker, semantic-show-parser-state-mode)
(semantic-show-unmatched-syntax-mode, semantic-highlight-edits-mode):
* cedet/semantic/mru-bookmark.el (semantic-mru-bookmark-mode):
* cedet/semantic/idle.el (semantic-idle-scheduler-mode)
(define-semantic-idle-service, semantic-idle-summary-mode):
* cedet/semantic/decorate/mode.el (semantic-decoration-mode):
Don't call semantic-mode-line-update any more.
Stefan Monnier [Sun, 2 May 2010 03:38:19 +0000 (23:38 -0400)]
Use define-minor-mode in CEDET where applicable.
* cedet/srecode/mode.el (srecode-minor-mode,global-srecode-minor-mode):
Use define-minor-mode.
* cedet/semantic/util-modes.el (semantic-add-minor-mode):
Remove unused arg `keymap' and code redundant with define-minor-mode.
(semantic-toggle-minor-mode-globally): Only handle arg -1 and 1.
(semantic-stickyfunc-mode, global-semantic-show-unmatched-syntax-mode)
(semantic-highlight-func-mode, global-semantic-show-parser-state-mode)
(global-semantic-highlight-edits-mode, semantic-highlight-edits-mode)
(semantic-show-unmatched-syntax-mode, semantic-show-parser-state-mode)
(global-semantic-stickyfunc-mode, global-semantic-highlight-func-mode):
Use define-minor-mode.
(semantic-stickyfunc-mode-setup, semantic-highlight-edits-mode-setup)
(semantic-show-unmatched-syntax-mode-setup)
(semantic-show-parser-state-mode-setup)
(semantic-highlight-func-mode-setup): Inline into sole caller.
* cedet/semantic/mru-bookmark.el (global-semantic-mru-bookmark-mode)
(semantic-mru-bookmark-mode): Use define-minor-mode.
(semantic-mru-bookmark-mode-setup): Inline into sole caller.
* cedet/semantic/idle.el (define-semantic-idle-service):
Use define-minor-mode and inline setup function into its sole caller.
(semantic-idle-scheduler-mode-setup)
(semantic-idle-summary-mode-setup): Inline into sole caller.
(global-semantic-idle-scheduler-mode, semantic-idle-scheduler-mode):
Use define-minor-mode.
* cedet/semantic/decorate/mode.el (global-semantic-decoration-mode)
(semantic-decoration-mode): Use define-minor-mode.
(semantic-decoration-mode-setup): Inline into sole caller.
* cedet/ede/dired.el (ede-dired-minor-mode): Initialize in declaration.
(ede-dired-minor-mode): Use define-minor-mode and derived-mode-p.
(ede-dired-add-to-target): Use dolist.
Eli Zaretskii [Sat, 1 May 2010 18:11:20 +0000 (21:11 +0300)]
Fix display of R2L lines and cursor motion in bidi buffers.
xdisp.c (find_row_end): New function, refactored from display_line.
(display_line): Use it.
(extend_face_to_end_of_line): In almost-filled rows, extend only
if the row is R2L and not continued.
(display_line): Fix prepending of truncation glyphs to R2L rows.
Preserve overlay and string info in row->end.
(insert_left_trunc_glyphs): Support addition of left truncation
glyphs to R2L rows.
(set_cursor_from_row): Don't place cursor on the vertical border
glyph between adjacent windows. Fix a crash when a display string
is continued to the next line. Don't return zero if cursor was
found by `cursor' property of a display string.
(try_cursor_movement): Don't assume that row->end == (row+1)->start,
test for that explicitly.
Eli Zaretskii [Sat, 1 May 2010 15:53:35 +0000 (18:53 +0300)]
Fix cursor positioning in partial width windows on TTY.
xdisp.c (set_cursor_from_row): Don't place cursor on the vertical border
glyph between adjacent windows.
(try_cursor_movement): Don't assume that row->end == (row+1)->start,
test for that explicitly.
Eli Zaretskii [Sat, 1 May 2010 13:39:44 +0000 (16:39 +0300)]
Fix display of truncated R2L lines on a TTY.
xdisp.c (display_line): Fix prepending of truncation glyphs to R2L rows.
(insert_left_trunc_glyphs): Support addition of left truncation glyphs
to R2L rows.
Michael Albinus [Sat, 1 May 2010 09:34:14 +0000 (11:34 +0200)]
Implement compression for inline methods.
* net/tramp.el (tramp-inline-compress-start-size): New defcustom.
(tramp-copy-size-limit): Allow also nil.
(tramp-inline-compress-commands): New defconst.
(tramp-find-inline-compress, tramp-get-inline-compress)
(tramp-get-inline-coding): New defuns.
(tramp-get-remote-coding, tramp-get-local-coding): Removed,
replaced by `tramp-get-inline-coding'.
(tramp-handle-file-local-copy, tramp-handle-write-region)
(tramp-method-out-of-band-p): Use `tramp-get-inline-coding'.
Glenn Morris [Sat, 1 May 2010 03:04:51 +0000 (20:04 -0700)]
Rework previous autoconf changes, hopefully to make clearer.
* configure.in (OTHER_OBJ): Remove.
(PRE_ALLOC_OBJ, POST_ALLOC_OBJ): New output variables.
* configure: Regenerate.
* src/Makefile.in (gmallocobj, rallocobj, vmlimitobj): Initialize to null,
for clarity.
(OTHER_OBJ): Remove.
(PRE_ALLOC_OBJ, POST_ALLOC_OBJ): New, set by configure.
(otherobj): Use PRE_ALLOC_OBJ, POST_ALLOC_OBJ rather than OTHER_OBJ.
Stefan Monnier [Sat, 1 May 2010 01:08:43 +0000 (21:08 -0400)]
* minibuffer.el (tags-completion-at-point-function): Move to etags.el.
* progmodes/etags.el (tags-completion-at-point-function):
Remove left over interactive spec. Add autoloading stub.
(complete-tag): Use tags-completion-at-point-function.
Hopefully fix bug#6065.
* configure.in (OTHER_OBJ): Always include vm-limit.o on Cygwin.
Elsewhere, maybe include it.
* src/Makefile.in (vmlimitobj) [!SYSTEM_MALLOC]: New variable.
(OTHER_OBJ): Define as a separate variable, for clarity.
* configure.in (TOOLKIT_LIBW) [HAVE_GTK]: Set to $GTK_LIBS.
(OLDXMENU, LIBXMENU): New output variables.
* src/Makefile.in (OLDXMENU, LIBXMENU) [HAVE_MENUS]:
Set with configure, not cpp.
(LIBW): Remove, replace with $TOOLKIT_LIBW.
Replace some cpp with autoconf.
* configure.in (OTHER_OBJ): New output variable.
* src/Makefile.in (mallocobj): Remove.
(otherobj): Simplify using @OTHER_OBJ@.
* minibuffer.el (tags-completion-at-point-function): New function.
(completion-at-point-functions): Use it.
* cedet/semantic.el (semantic-completion-at-point-function): New function.
(semantic-mode): Use semantic-completion-at-point-function for
completion-at-point-functions instead.
* progmodes/etags.el (complete-tag): Revert last change.
Stefan Monnier [Thu, 29 Apr 2010 14:29:09 +0000 (10:29 -0400)]
Don't burp if process sentinel/filter kills the current buffer.
* process.c (read_process_output, exec_sentinel): Don't burp if the
sentinel/filter kills the current buffer.
Stefan Monnier [Thu, 29 Apr 2010 12:42:01 +0000 (08:42 -0400)]
Fix wrong-docstring problem introduced with hash-consing.
* eval.c (Fautoload): Set doc to a unique number rather than to 0.
Remove unused var `args'.
* lisp.h (XSETCARFASTINT, XSETCDRFASTINT): Remove.
(LOADHIST_ATTACH): Wrap with do...while to avoid surprises for callers.
* doc.c (store_function_docstring): Use XSETCAR.
* bindings.el (complete-symbol): Move into minibuffer.el.
* minibuffer.el (complete-tag): Move from etags.el. If tags
completion cannot be performed, return nil instead of signalling
an error.
(completion-at-point): Make it an alias for complete-symbol.
(complete-symbol): Move from bindings.el, and replace with the
body of completion-at-point.
* progmodes/etags.el (complete-tag): Move to minibuffer.el.
* cedet/semantic.el (semantic-mode): When enabled, add
semantic-ia-complete-symbol to completion-at-point-functions.
* cedet/semantic/ia.el (semantic-ia-complete-symbol): Return nil
if Semantic is not active.
Stefan Monnier [Wed, 28 Apr 2010 15:18:37 +0000 (11:18 -0400)]
Make it possible to locally disable a globally enabled mode.
* simple.el (fundamental-mode): Run fundamental-mode-hook.
* emacs-lisp/derived.el (define-derived-mode): Use fundamental-mode
rather than kill-all-local-variables so it runs fundamental-mode-hook.
* emacs-lisp/easy-mmode.el (define-globalized-minor-mode):
Use fundamental-mode-hook to run MODE-enable-in-buffers earlier, so
that subsequent hooks get a chance to disable it.
src/Makefile.in minor simplification,
* src/Makefile.in (BASE_WINDOW_SUPPORT, X_WINDOW_SUPPORT): New variables.
(WINDOW_SUPPORT) [HAVE_WINDOW_SYSTEM]: Use them.