message.el (message-indent-citation): Fix empty line removal at the end of the citation.
auth-source.el (auth-source-netrc-create): Use default value for password if specified. Evaluate default.
(auth-source-plstore-create): Ditto.
(auth-source-plstore-create, auth-source-netrc-create): Fix default value evaluation.
(auth-source-netrc-create): Typo fix.
(auth-source-plstore-create): Ditto.
Juri Linkov [Tue, 20 Sep 2011 20:16:42 +0000 (23:16 +0300)]
* lisp/info.el (Info-history-skip-intermediate-nodes): New defcustom.
(Info-forward-node, Info-backward-node, Info-next-preorder)
(Info-last-preorder): Use it.
Eli Zaretskii [Tue, 20 Sep 2011 17:42:16 +0000 (20:42 +0300)]
Fix bidi-aware cursor motion inside indentation.
src/xdisp.c (Fcurrent_bidi_paragraph_direction): Fix search for previous
non-empty line. Fixes confusing cursor motion with arrow keys at
the beginning of a line that starts with whitespace.
Eli Zaretskii [Tue, 20 Sep 2011 17:13:45 +0000 (20:13 +0300)]
Fix bug #9549 with longlines-show-hard-newlines.
src/xdisp.c (set_cursor_from_row): If the row ends in a newline from
a display string, extend search for cursor position to end of row.
(find_row_edges): If the row ends in a newline from a display
string, increment its MATRIX_ROW_END_CHARPOS by one.
Handle the case of a display string with multiple newlines.
password-cache.el (password-cache-remove): Remove entries even if the value is nil, so that password with a nil value (negative caching) is possible to invalidate.
auth-source.el (auth-source-format-cache-entry): New function.
* lisp/progmodes/f90.el (f90-break-line): If breaking inside comment delete
all whitespace around breakpoint.
(f90-find-breakpoint): Only break at whitespace inside a comment.
Stefan Monnier [Tue, 20 Sep 2011 01:06:29 +0000 (21:06 -0400)]
* lisp/minibuffer.el (completion-file-name-table): Keep track of errors.
(completion-table-with-predicate): Handle the case where pred1 is nil.
* lisp/pcomplete.el (pcomplete-completions-at-point): Simplify.
mm-decode.el (mm-inline-media-tests): Fix typo in regexp.
auth-source.el (auth-source-netrc-parse): Use an obfuscation method which work with things that are not ASCII.
Stefan Monnier [Mon, 19 Sep 2011 21:14:23 +0000 (17:14 -0400)]
* lisp/emacs-lisp/debug.el (debugger-args): Give it a docstring.
(debugger-return-value): Signal an error if the debugging context does
not await any return value.
Juri Linkov [Sun, 18 Sep 2011 20:28:45 +0000 (23:28 +0300)]
Preserve current isearch case-fold value in `isearch-edit-string'.
* lisp/isearch.el (isearch-edit-string): Bind `isearch-new-case-fold'
to `isearch-case-fold-search' and restore its original value
after the `isearch-mode' call.
Juri Linkov [Sun, 18 Sep 2011 20:14:16 +0000 (23:14 +0300)]
* lisp/info.el (Info-extract-menu-node-name): Check the second match
for empty string (second test-case of bug#9528).
(Info-last-preorder): Let-bind `Info-history' to nil to not add
intermediate nodes to the history (first test-case of bug#9528).
Juri Linkov [Sun, 18 Sep 2011 19:49:13 +0000 (22:49 +0300)]
* lisp/info.el (Info-file-supports-index-cookies): Increment
line-beginning-position's arg from 3 to 4 because makeinfo outputs
one more line for long file names.
Eli Zaretskii [Sun, 18 Sep 2011 19:02:17 +0000 (22:02 +0300)]
Fix bug #9545 with crash in Dired when $ is pressed.
src/xdisp.c (reseat_at_next_visible_line_start): Undo the change made on
2011-09-17 that saved paragraph information and restored it after
the call to `reseat'.
Johan Bockgård [Sun, 18 Sep 2011 16:13:01 +0000 (12:13 -0400)]
Fix previous fix of Bug#5849.
* icomplete.el (icomplete-mode): Don't set completion-show-inline-help.
(icomplete-minibuffer-setup): Set completion-show-inline-help
locally during icompletion.
Eli Zaretskii [Sun, 18 Sep 2011 15:48:12 +0000 (18:48 +0300)]
Fix bug #9530 on a TTY.
src/xdisp.c (display_line): Record maximum and minimum buffer
positions even if no glyphs were produced (e.g., by a zero-width
stretch). Fixes bug#9530 on a TTY. Under word-wrap, don't record
buffer positions that will be removed from the glyph row because
they don't fit.
Michael Albinus [Sun, 18 Sep 2011 11:26:15 +0000 (13:26 +0200)]
* net/tramp.el (top): Don't require 'shell.
(tramp-methods): Fix docstring.
(tramp-get-remote-tmpdir): New defun, moved from tramp-sh.el.
Return complete remote file name. Handle "smb" case. Use
`tramp-tmpdir', if defined for the respective method.
(tramp-make-tramp-temp-file): Adapt call of `tramp-get-remote-tmpdir'.
* net/tramp-compat.el (top): Require 'shell.
* net/tramp-sh.el (tramp-do-copy-or-rename-file-out-of-band)
(tramp-maybe-open-connection): Use `tramp-file-name-real-host' for
`tramp-current-host'.
(tramp-get-remote-tmpdir): Remove.
* net/tramp-smb.el (tramp-methods): Add `tramp-remote-shell' and
`tramp-tmpdir' entries.
(tramp-smb-errors): Add "NT_STATUS_IMAGE_ALREADY_LOADED".
(tramp-smb-handle-file-attributes): Ignore errors.
(tramp-smb-wait-for-output): Check also for process end.
Paul Eggert [Sun, 18 Sep 2011 08:34:09 +0000 (01:34 -0700)]
* fileio.c: Report proper errno when syscall falls.
(Finsert_file_contents): Save and restore errno,
so that report_file_error outputs the correct diagnostic.
(Fwrite_region) [CLASH_DETECTION]: Likewise.
* lisp/replace.el (occur-mode-map): Rebind occur-edit-mode to "e".
(occur-edit-mode-map): Bind C-c C-c to occur-cease-edit and C-o to
occur-mode-display-occurrence.
(occur-edit-mode): Add usage message.
(occur-cease-edit): New command.
(occur-after-change-function): Use text properties to find the
position of the prefix text.
(occur-engine): Set stickiness of prefix text properties.
Eli Zaretskii [Sat, 17 Sep 2011 15:18:56 +0000 (18:18 +0300)]
Fix bug #9470 with slow redisplay in huge single-paragraph buffers.
src/bidi.c (MAX_PARAGRAPH_SEARCH): New macro.
(bidi_find_paragraph_start): Search back for paragraph beginning
at most MAX_PARAGRAPH_SEARCH lines; if not found, return BEGV_BYTE.
(bidi_move_to_visually_next): Only trigger paragraph-related
computations when the last character is a newline or at EOB, not
just any NEUTRAL_B.
src/xdisp.c (reseat_at_next_visible_line_start): Keep information
about the current paragraph and restore it after the call to
reseat.
Juri Linkov [Sat, 17 Sep 2011 12:07:50 +0000 (15:07 +0300)]
* lisp/textmodes/ispell.el (ispell-word): Add to the error message
the word, ispell program name and current dictionary.
(ispell-tex-arg-end): Capitalize "error" in the error message.
Paul Eggert [Fri, 16 Sep 2011 17:49:29 +0000 (10:49 -0700)]
* xselect.c: Relax test for outgoing X longs (Bug#9498).
(cons_to_x_long): New function.
(lisp_data_to_selection_data): Use it. Correct the test for
short-versus-long data; it was negated. Break out of vector
loop, for efficiency, when a long datum is discovered.
Eli Zaretskii [Fri, 16 Sep 2011 17:15:16 +0000 (20:15 +0300)]
Fix bug #971 with next/previous-line when goal-column is set.
lisp/simple.el (line-move): If goal-column is set, move by logical
lines, not by display lines.
(next-line, previous-line, goal-column, line-move-visual): Doc fix
to reflect the above change.
Eli Zaretskii [Thu, 15 Sep 2011 16:22:58 +0000 (19:22 +0300)]
Add comments about special meaning of TAB characters in compositions.
src/xterm.c (x_draw_composite_glyph_string_foreground):
src/w32term.c (x_draw_composite_glyph_string_foreground):
src/term.c (encode_terminal_code):
src/composite.c (composition_update_it, get_composition_id):
src/xdisp.c (get_next_display_element)
(fill_composite_glyph_string): Add comments about special meaning
of TAB characters in a composition.
Make the user customizable display-buffer variable empty by default.
* lisp/window.el (display-buffer-base-action): Rename from
display-buffer-default-action. Make default value empty.
(display-buffer-overriding-action): Convert to defvar.
(display-buffer-fallback-action): New var.
Add an "mark upgradable packages" command to Package Menu mode.
* lisp/emacs-lisp/package.el (package-alist): Fix risky-local-variable
declaration.
(package--add-to-archive-contents): If there is a duplicate entry
with an older version, remove it.
(package-menu-mark-delete, package-menu-mark-install)
(package-menu-mark-unmark): Make unused args optional.
(package-menu-mark-obsolete-for-deletion): Use
package-menu-get-status instead of a regexp search.
(package-menu-get-status): Use tabulated-list-entry.
(package-menu-mark-upgrades): New command.
(package-menu-mode-map): Bind it to U.
(package-menu-execute): Do installation before deletion.
(package-menu-refresh, package-menu-execute): Use derived-mode-p
instead of checking major-mode.
(package-menu--find-upgrades): New function.
Stefan Monnier [Wed, 14 Sep 2011 21:43:36 +0000 (17:43 -0400)]
* textmodes/bibtex.el (bibtex-complete-string-cleanup)
(bibtex-complete-crossref-cleanup): Adjust to accommodate needs of
bibtex-completion-at-point-function.
(bibtex-completion-at-point-function): Use them.
Stefan Monnier [Wed, 14 Sep 2011 21:20:24 +0000 (17:20 -0400)]
* mpc.el (mpc-constraints-tag-lookup): New function.
(mpc-constraints-restore): Use it to make jumping to "album=Foo" apply
also to browser "album|playlist".
Juri Linkov [Wed, 14 Sep 2011 16:07:42 +0000 (19:07 +0300)]
Share code between `isearch-message' and `isearch-string' in `isearch-fail-pos'.
http://lists.gnu.org/archive/html/emacs-devel/2011-09/msg00169.html
* lisp/isearch.el (isearch-fail-pos): Add new arg `msg'. Doc fix.
(isearch-edit-string): Use length of `isearch-string' when
`isearch-fail-pos' returns nil.
(isearch-message): Remove duplicate code and call
`isearch-fail-pos' with arg `t'.
Paul Eggert [Wed, 14 Sep 2011 15:47:21 +0000 (08:47 -0700)]
* xselect.c: Use signed conversions more consistently (Bug#9498).
(selection_data_to_lisp_data): Assume incoming selection data are
signed integers, not unsigned. This is to be consistent with
outgoing selection data, which was modified to use signed integers
in as part of the fix to Bug#9196 in response to Jan Djärv's comment
in <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9196#32> that X11
expects long, not unsigned long.
Martin Rudalics [Wed, 14 Sep 2011 09:17:30 +0000 (11:17 +0200)]
Replace display-buffer-window by help-setup window parameter.
* window.el (display-buffer-window): Remove.
(display-buffer-record-window): Use help-setup window parameter
instead of variable display-buffer-window.
(display-buffer-function, special-display-buffer-names)
(special-display-function): Mention help-setup parameter instead
of display-buffer-window in doc-string.
* help.el (help-window-setup): New argument help-window. Use
help-window-setup parameter instead of display-buffer-window.
Reword some messages.
(with-help-window): Pass window used for displaying the buffer
to help-window-setup. Don't set display-buffer-window.