Eli Zaretskii [Tue, 22 Dec 2015 16:57:51 +0000 (18:57 +0200)]
Fix decoding of text in URLs retrieved by EWW
* lisp/net/eww.el (eww-render): Pass 'charset' to
'eww-display-raw'. Use the value of 'last-coding-system-used', if
non-nil, to set 'buffer-file-coding-system' of the buffer where we
show the URL.
(eww-display-html, eww-display-raw): Decode the text correctly,
using the charset found in the headers, and defaulting to UTF-8.
If the user told us to use a specific encoding, override the
charset from the headers. (Bug#22222)
Alan Mackenzie [Tue, 22 Dec 2015 16:10:35 +0000 (16:10 +0000)]
Fix a coding error in c-forward-<>-arglist-recur. Fixes bug#22156
* lisp/progmodes/cc-engine.el (c-forward-<>-arglist-recur): Remove unused
variable `tmp'.
After a failed search for a matching ">", restore point before continuing.
Paul Eggert [Mon, 21 Dec 2015 01:27:28 +0000 (17:27 -0800)]
Port undo fixes to -fno-common
Port recent fix for Bug#21968 to platforms like 'gcc -fno-common'.
* src/keyboard.c, src/keyboard.h (point_before_last_command_or_undo)
(buffer_before_last_command_or_undo):
Declare in keyboard.h, and define in keyboard.c,
instead of assuming the traditional Unix relaxed ref-def linkage.
Philipp Stephani [Sun, 20 Dec 2015 19:10:03 +0000 (21:10 +0200)]
Improve commentary for emacs-module.c
* src/lisp.h: Document emacs-module.c assumptions about EQ and NILP.
* src/emacs-module.c (module_non_local_exit_get): Document that we
cannot use the current implementation.
(module_is_not_nil, module_eq): Document assumptions about EQ and
NILP.
Eli Zaretskii [Sat, 19 Dec 2015 15:43:11 +0000 (17:43 +0200)]
Document new features of Rmail
* doc/emacs/rmail.texi (Rmail Summary Edit, Rmail Deletion):
Document new behavior of 'd' and 'C-d' with numeric argument.
(Rmail Display): Document the rendering of HTML MIME parts.
Eli Zaretskii [Sat, 19 Dec 2015 14:14:11 +0000 (16:14 +0200)]
Document new features of Font Lock
* doc/lispref/modes.texi (Other Font Lock Variables): Document
'font-lock-flush-function' and 'font-lock-ensure-function'.
(Font Lock Basics): Document the basic fontification functions
referenced in "Other Font Lock Variables".
Eli Zaretskii [Sat, 19 Dec 2015 10:37:49 +0000 (12:37 +0200)]
Document how to avoid file-local variables that aren't
* doc/emacs/custom.texi (Specifying File Variables): Describe how
to prevent Emacs from interpreting unrelated text as file-local
variables. (Bug#22166)
Eli Zaretskii [Sat, 19 Dec 2015 09:54:18 +0000 (11:54 +0200)]
Allow 'browse-url-emacs' visit non-existent URLs
* lisp/url/url-handlers.el (url-insert-file-contents): Don't
signal an error if VISIT is non-nil, to more faithfully emulate
the behavior of 'insert-file-contents'. (Bug#22160)
Paul Eggert [Sat, 19 Dec 2015 01:10:50 +0000 (17:10 -0800)]
Remove SunOS 4.x cruft
Support for SunOS 4.x was removed in Emacs 23 but some cruft was left behind.
* lib-src/pop.c [sun]: Remove no-longer-needed include.
* lwlib/xlwmenu.c (SUNSO41): Remove.
Eli Zaretskii [Fri, 18 Dec 2015 10:26:17 +0000 (12:26 +0200)]
Fix vertical-motion in tabulated-list mode
* src/indent.c (Fvertical_motion): When moving from line beginning
to point under line truncation, assume overshoot by one line only
if point actually lies beyond the window's right margin.
(Bug#22194)
* doc/emacs/programs.texi (Matching): Add descriptions of some pertinent user
options, including the new show-paren-when-point-inside-paren and
show-paren-when-point-in-periphery.
* etc/NEWS (.. Specialized Modes ...): Add an entry for Show Paren mode.
Move an entry on pcase to the Lisp Changes section.
Eli Zaretskii [Wed, 16 Dec 2015 10:40:33 +0000 (12:40 +0200)]
Fix invocation of Python and Guile interpreters from gdb-mi
* lisp/progmodes/gdb-mi.el (gdb-control-commands-regexp): Add
commands for interactive Python and Guile interpreters.
(gdb-send): Recognize various ways of exiting from Python and
Guile interpreters and returning to GDB. For details, see
http://lists.gnu.org/archive/html/emacs-devel/2015-12/msg00693.html
and http://stackoverflow.com/questions/31514741.
Paul Eggert [Wed, 16 Dec 2015 07:10:12 +0000 (23:10 -0800)]
Remove attempt to use C11 threads
C11 threads are not needed for Emacs now, and their use is causing
hassles on FreeBSD 10.x. Problem reported by Ashish SHUKLA in:
http://lists.gnu.org/archive/html/emacs-devel/2015-12/msg00648.html
* configure.ac: Do not check for C11 threads. Remove unnecessary
fiddling with CPPFLAGS when configuring pthreads.
* src/emacs-module.c (main_thread, check_main_thread)
(module_init): Do not worry about C11 threads.
Michael Albinus [Tue, 15 Dec 2015 22:54:11 +0000 (23:54 +0100)]
Set utf8 encoding with stty in Tramp
* lisp/net/tramp-sh.el (tramp-open-connection-setup-interactive-shell):
Move up uname check. Handle Mac OS X eol encoding. Set utf8
encoding with stty.
Alan Mackenzie [Tue, 15 Dec 2015 11:41:54 +0000 (11:41 +0000)]
Tidy up documentation associated with window groups.
* doc/lispref/windows.texi (Basic Windows): Add an @anchor for "Window
Groups". Correct example function to `window-group-start'.
(Window Start and End, Textual scrolling): Point to the new anchor. State
that (most of) the args in window group functions have the same meaning as for
the corresponding window primitives.
* doc/lispref/positions.texi (Screen Lines). Same as above.
Alan Mackenzie [Mon, 14 Dec 2015 17:29:45 +0000 (17:29 +0000)]
Ispell: Bind isearch-regexp-function to nil around call to isearch..-new-loop
* lisp/textmodes/ispell.el (ispell-highlight-spelling-error-overlay): bind
isearch-regexp-function to nil around call to isearch-lazy-highligh-new-loop.
Alan Mackenzie [Mon, 14 Dec 2015 17:17:31 +0000 (17:17 +0000)]
Enhance ispell-skip-region-alist by generating part of it at runtime.
* lisp/textmodes/ispell.el (ispell--\\w-filter, ispell--make-\\w-expression)
(ispell--make-filename-or-URL-re): New functions which generate a regexp.
(ispell-skip-region-alist): Remove the bit that matches a filename/URL, etc.
(ispell-begin-skip-region-regexp, ispell-skip-region-list, ispell-message):
Include the result of ispell--make-filename-or-URL-re in regexps.
Alan Mackenzie [Mon, 14 Dec 2015 16:38:07 +0000 (16:38 +0000)]
Replace GROUP argument in six window primitives by new functions.
* doc/lispref/windows.texi (Window Start and End, Textual Scrolling)
* doc/lispref/positions.texi (Screen Lines): Remove optional GROUP argument
from description of six window functions. Add in description of new functions
window-group-start, window-group-end, set-window-group-start,
pos-visible-in-window-group-p, recenter-group and move-to-window-group-line,
together with the six variables indirecting to the pertinent group
functions.
* src/window.c
* src/keyboard.c: Revert the commit from 2015-11-11 12:02:48, in so far as it
applies to these two files, which added the GROUP argument to six window
primitives.
* lisp/follow.el (follow-mode): Use updated variable names for the indirected
functions.
* lisp/isearch.el (isearch-update, isearch-done, isearch-string-out-of-window)
(isearch-back-into-window, isearch-lazy-highlight-new-loop)
(isearch-lazy-highlight-search, isearch-lazy-highlight-update): Replace calls
to window primitives (e.g. window-start) with a GROUP argument by calls to
new functions (e.g. window-group-start).
* lisp/ispell.el (ispell-command-loop): Replace call to
pos-visible-in-window-p with pos-visible-in-window-group-p.
* lisp/window.el (window-group-start, window-group-end)
(set-window-group-start, recenter-group, pos-visible-in-window-group-p)
(selected-window-group, move-to-window-group-line): New functions.
(window-group-start-function, window-group-end-function)
(set-window-group-start-function, recenter-group-function)
(pos-visible-in-window-group-p-function, selected-window-group-function)
(move-to-window-group-line-function): New variables.
Tassilo Horn [Sun, 13 Dec 2015 18:41:58 +0000 (19:41 +0100)]
Improve regex to not trigger stack overflow
* lisp/textmodes/reftex-vars.el (reftex-label-regexps): Improve regex in
order not to trigger a stack overflow in regex matcher with unbalanced
brackets (bug#22146).
Paul Eggert [Sun, 13 Dec 2015 03:27:51 +0000 (19:27 -0800)]
Fix performance regression with gcc -O0
This fixes the smaller performance hit that I noted in:
https://lists.gnu.org/archive/html/emacs-devel/2015-12/msg00357.html
* src/alloc.c (macro_XPNTR_OR_SYMBOL_OFFSET, macro_XPNTR):
* src/puresize.h (puresize_h_PURE_P)
(puresize_h_CHECK_IMPURE):
New macros, with the old contents of the functions.
* src/alloc.c (XPNTR_OR_SYMBOL_OFFSET, XPNTR):
* src/puresize.h (PURE_P, CHECK_IMPURE):
Use the new macros. Also macros, if DEFINE_KEY_OPS_AS_MACROS.
* src/conf_post.h (ATTRIBUTE_UNUSED):
* src/lisp.h (DEFINE_KEY_OPS_AS_MACROS): New macros.
Martin Rudalics [Sat, 12 Dec 2015 13:38:11 +0000 (14:38 +0100)]
Fix frame height calculations with added menu bar on Windows (Bug#22105)
* doc/lispref/frames.texi (Parameter Access): Mention pitfalls
when simultaneously specifying multiple parameters for
`modify-frame-parameters' that all may change the frame's size.
* src/w32fns.c (x_set_menu_bar_lines): Don't set
windows_or_buffers_changed here.
(my_create_tip_window, Fx_show_tip): Call AdjustWindowRect
with third argument false.
* src/w32menu.c (set_frame_menubar): Set
windows_or_buffers_changed here.
* src/w32term.c (x_set_window_size): Determine third argument of
AdjustWindowRect from whether the frame has a menu bar and not
from whether it wants one.
Eli Zaretskii [Sat, 12 Dec 2015 13:17:14 +0000 (15:17 +0200)]
Document new features of package.el
* doc/emacs/package.texi (Package Menu): Document the 'external'
status and the new menu commands.
(Package Installation): Document archive priorities.
Eli Zaretskii [Fri, 11 Dec 2015 10:50:53 +0000 (12:50 +0200)]
Avoid errors when creating files under SVN in new directory
* lisp/vc/vc-svn.el (vc-svn-registered): Use
file-accessible-directory-p, to avoid cd'ing to a non-existing
directory, which signals an error on some systems. (Bug#21984)
(vc-svn-checkin): Call log-edit-extract-headers with 2 arguments.
Use declare-function to avoid byte-compiler warnings.
Anders Lindgren [Fri, 11 Dec 2015 05:46:19 +0000 (06:46 +0100)]
; Restore selector `member' accidentally drooped in ert rewrite.
; `test/automated/ert.el' and `test/automated/ert-x.el' now run
; without errors.
* lisp/emacs-lisp/ert.el (ert--insert-human-readable-selector): Add
the `member' selector. This was accidentally dropped when code was
converted from `cl-typecase' (where `member' has a special meaning)
and `cl-ecase' (where it doesn't) to `pcase'.