Eli Zaretskii [Thu, 31 Dec 2015 15:44:07 +0000 (17:44 +0200)]
Allow to invoke original M-TAB binding in 'flyspell-prog-mode'
* lisp/textmodes/flyspell.el (flyspell-prog-mode): Record the
original M-TAB binding in a buffer-local variable.
(flyspell-auto-correct-word): Invoke the original binding of M-TAB
if that is recorded, when point is in a place where flyspell
should not be active (e.g., because the user turned on
'flyspell-prog-mode'). (Bug#18533)
* src/gtkutil.c (xg_get_page_setup): Use listn.
* src/xfns.c (Fx_export_frames, Fx_print_frames_dialog): Doc fix. Use
decode_window_system_frame and FRAME_VISIBLE_P.
(Fx_print_frames_dialog): Use redisplay_preserve_echo_area instead
of Fdisplay.
* src/xterm.c (x_cr_export_frames): Use redisplay_preserve_echo_area
instead of Fdisplay. Temporarily unblock_input around QUIT.
Shakthi Kannan [Wed, 30 Dec 2015 17:46:55 +0000 (19:46 +0200)]
Document new features of TeX mode
* doc/emacs/text.texi (TeX Print): Document
'tex-print-file-extension'.
* doc/emacs/programs.texi (Misc for Programs): Document support
for Prettify Symbols mode in TeX mode.
Dmitry Gutov [Wed, 30 Dec 2015 04:25:39 +0000 (06:25 +0200)]
Undo ill-advised change
* lisp/progmodes/xref.el (xref-collect-matches): Undo
ill-advised change. The hits come in the order that `find'
produces them in, which isn't alphabetical.
Eli Zaretskii [Tue, 29 Dec 2015 16:49:57 +0000 (18:49 +0200)]
Fix filling text with bidirectional characters in shr.el
* lisp/net/shr.el (shr-insert-document): Bind
bidi-display-reordering to nil while filling lines. This is
required for when a line includes characters whose bidi
directionality is opposite to the base paragraph direction,
because columns are counted in the logical order. (Bug#22250)
Paul Eggert [Tue, 29 Dec 2015 02:43:09 +0000 (18:43 -0800)]
Port report-emacs-bug to deterministic builds
* lisp/mail/emacsbug.el (report-emacs-bug): Future-proof the
recent "built on" change to deterministic builds where
emacs-build-system will be nil. See:
http://lists.gnu.org/archive/html/emacs-devel/2015-12/msg01369.html
Martin Rudalics [Mon, 28 Dec 2015 18:11:22 +0000 (19:11 +0100)]
Fix Bug#10873 in `report-emacs-bug'
* lisp/mail/emacsbug.el (report-emacs-bug): If
`report-emacs-bug-no-explanations' is nil, make sure we can show
mail and warnings buffer on this frame (Bug#10873).
Alan Mackenzie [Mon, 28 Dec 2015 16:01:05 +0000 (16:01 +0000)]
Allow line comments ending with escaped NL to be continued to the next line.
Use this in C, C++, and Objective C Modes. Fixes bug#22246
* src/syntax.c (comment-end-can-be-escaped): New buffer local variable.
(forw-comment, back-comment): On encountering an end of comment character,
test whether it is escaped when `comment-end-can-be-escaped' is non-nil.
Dmitry Gutov [Mon, 28 Dec 2015 04:17:19 +0000 (06:17 +0200)]
Rename project-library-roots to project-external-roots
* lisp/progmodes/project.el (project-library-roots): Rename to
project-external-roots.
(project-library-roots-function): Rename to
project-vc-external-roots-function. Only use it in the VC
backend, for now. Update project-external-roots accordingly.
(project-vc-library-roots): Remove.
(project-or-libraries-find-regexp):
Rename to project-or-external-find-regexp.
* lisp/progmodes/elisp-mode.el (elisp-library-roots):
Rename to elisp-load-path-roots.
* lisp/progmodes/etags.el (etags-library-roots): Remove. Use
an anonymous function for the default value of
project-vc-external-roots-function.
Deniz Dogan [Sun, 27 Dec 2015 21:36:55 +0000 (22:36 +0100)]
Clear erc user list upon disconnection
* lisp/erc/erc-backend.el (erc-process-sentinel): Clear channel user
lists upon disconnection. This prevents invalid channel
user lists when reconnecting (bug#10947).
* erc-backend.el (erc-server-send-ping): If the server has
closed connection, this may already have been detected and
`erc-server-last-received-time' has been set to nil (bug#13608).
Dima Kogan [Sun, 27 Dec 2015 20:19:13 +0000 (21:19 +0100)]
Ensure that we don't have several timers in erc
* lisp/erc/erc-backend.el (erc-server-setup-periodical-ping): Checks
for existing timers in the alist before adding new ones. If a
timer already exists, it is cancelled and
overwritten. (bug#19292).
Paul Eggert [Sat, 26 Dec 2015 23:22:28 +0000 (15:22 -0800)]
Reword initial *scratch* for brevity, appearance
* lisp/startup.el (initial-scratch-message):
Reword to avoid apostrophes, and to make it shorter.
See the thread starting in:
http://lists.gnu.org/archive/html/emacs-devel/2015-12/msg01241.html
* lisp/net/imap.el (imap-ssl-program): Remove (bug#21134).
(imap-starttls-open): Use open-network-stream instead of starttls.el.
(imap-tls-open): Use open-network-stream instead of tls.el.
Eli Zaretskii [Sat, 26 Dec 2015 20:35:48 +0000 (22:35 +0200)]
Don't try using /bin/sh in artist.el on MS-Windows
* lisp/textmodes/artist.el (artist-figlet-get-font-list-windows):
New function.
(artist-figlet-choose-font): Use it on MS-Windows and MS-DOS.
(Bug#20167)
Wolfgang Jenkner [Sat, 26 Dec 2015 20:12:02 +0000 (12:12 -0800)]
Always define gmalloc etc. in src/gmalloc.c
This is a work-around to prevent the compiler from using semantic
knowledge about malloc for optimization purposes. E.g., gcc 5.2
with -O2 replaces most of calloc's definition by a call to calloc;
see Bug#22085.
* src/gmalloc.c [!HYBRID_MALLOC] (malloc, realloc, calloc)
(aligned_alloc, free): Do not undef. Instead, define these as
functions (perhaps renamed to gmalloc etc.) in terms of gmalloc etc.
Eli Zaretskii [Sat, 26 Dec 2015 18:47:42 +0000 (20:47 +0200)]
Fix documentation of browse-url browser-related functions
* lisp/net/browse-url.el (browse-url)
(browse-url-default-browser, browse-url-default-windows-browser)
(browse-url-default-macosx-browser, browse-url-chromium)
(browse-url-kde, browse-url-text-xterm): Clarify the usage of ARGS
and NEW-WINDOW arguments in these functions. (Bug#19421)
Paul Eggert [Sat, 26 Dec 2015 17:30:22 +0000 (09:30 -0800)]
Propagate Bug#14412 fix to backtrace_eval_unrewind
* src/eval.c (unbind_to): Redo so that the FALLTHROUGH!! comment
becomes accurate again. This shouldn’t affect behavior.
(backtrace_eval_unrewind): Apply the recent unbind_to fix here, too.
Alain Schneble [Fri, 25 Dec 2015 23:50:25 +0000 (00:50 +0100)]
Make relative URL parsing and resolution consistent with RFC 3986 (bug#22044)
* test/lisp/url/url-parse-tests.el: Add tests covering url-generic-parse-url.
* test/lisp/url/url-expand-tests.el: Add tests covering url-expand-file-name.
* lisp/url/url-parse.el (url-generic-parse-url): Keep empty fragment
information in URL-struct.
* lisp/url/url-parse.el (url-path-and-query): Do not artificially turn empty
path and query into nil path and query, respectively.
* lisp/url/url-expand.el (url-expander-remove-relative-links): Do not turn
empty path into an absolute ("/") path.
* lisp/url/url-expand.el (url-expand-file-name): Properly resolve
fragment-only URIs. Do not just return them unchanged.
* lisp/url/url-expand.el (url-default-expander): An empty path in the relative
reference URI should not drop the last segment.
Eli Zaretskii [Sat, 26 Dec 2015 13:31:32 +0000 (15:31 +0200)]
Document 'url-user-agent'.
* lisp/url/url-http.el (url-user-agent): Move from here...
* lisp/url/url-vars.el (url-user-agent): ...to here. This is to
keep all the URL defcustoms in one place, and also have it defined
whenever the URL library is loaded.
Eli Zaretskii [Sat, 26 Dec 2015 11:48:00 +0000 (13:48 +0200)]
Document changes in Shell-script mode
* lisp/progmodes/sh-script.el (sh-mode, sh-set-shell): Document
the 'sh-shell' file-local variable.
(top level): Add an auto-load form to avoid byte-compiler warning
about 'comint-send-string'.
Eli Zaretskii [Fri, 25 Dec 2015 16:37:31 +0000 (18:37 +0200)]
Make sure *scratch* etc. use forward slashes in its default-directory
* lisp/startup.el (normal-top-level): On MS-Windows, convert
backslashes to forward slashes while decoding default-directory
of the initially-created buffers.
* shr.el (shr-table-body): New function to find the real body
of a table.
(shr-tag-table): Use it to render several <tbody> tags in a
table (bug#22170).
Eli Zaretskii [Fri, 25 Dec 2015 11:35:08 +0000 (13:35 +0200)]
Restore info about the build host in bug reports
* lisp/mail/emacsbug.el (report-emacs-bug): Report the system on
which Emacs was built. This is important information for
investigating bug reports reported by users who don't build their
Emacs.
Eli Zaretskii [Fri, 25 Dec 2015 11:23:17 +0000 (13:23 +0200)]
Fix bootstrap broken by changes related to OS X file-name encoding
* lisp/international/ucs-normalize.el (eval-when-compile): Make
sure char-code-property-alist includes elements that allow access
to 'decomposition' and 'canonical-combining-class' Unicode
properties, as compiling ucs-normalize.el requires that.
* lisp/loadup.el (featurep 'ns): Load ucs-normalize and ns-win
only of charprop.el was already loaded.
* src/Makefile.in ($(lispsource)/international/ucs-normalize.elc):
New order-only dependency.