* lisp/erc/erc-log.el (erc-truncate-buffer-on-save): Doc
clarification (bug#18207) since "truncate" is a word used by
erc-truncate to mean something else.
* lisp/erc/erc-button.el (erc-button-search-url): Renamed from
url-button-google-url (bug#25717). Suggested by Andrew Robbins.
(erc-button-alist): Use it.
(libxml-parse-html-region): Make DISCARD-COMMENTS obsolete
* lisp/subr.el (libxml-parse-xml-region)
(libxml-parse-html-region): Make DISCARD-COMMENTS obsolete.
* src/xml.c (Flibxml_parse_html_region)
(Flibxml_parse_xml_region): Don't mention DISCARD-COMMENTS, since
it's now no longer part of the advertised signature (bug#27178).
Make DISCARD-COMMENTS in `libxml-parse-{html,xml}-region' obsolete
* doc/lispref/text.texi (Parsing HTML/XML): Mention that
discard-comments is obsolete.
* lisp/xml.el (xml-remove-comments): New function (bug#27178).
* src/xml.c (Flibxml_parse_html_region): Clarify what
DISCARD-COMMENTS actually does, and say that the parameter is
obsolete.
(Flibxml_parse_xml_region): Ditto.
Make image-mode respect `imagemagick-types-inhibit'
* lisp/image-mode.el (image--imagemagick-wanted-p): New function
(bug#29584).
(image-toggle-display-image): Use it to see whether we want to use
imagemagick.
Tweak mailcap precedence so that Emacs values are heeded better
* lisp/net/mailcap.el (mailcap-parse-mailcaps): Place entries from
system-wide mailcap files after the values that are distributed
with Emacs, and the ones from ~/.mailcap before.
(mailcap-parse-mailcap): Take an optional `after' parameter to
achieve that.
(mailcap-add-mailcap-entry): Ditto.
* lisp/gnus/mm-decode.el: Do not require shr.el at the top
of the file; `mm-shr' already requires shr.el in its body, and
this function is the only `mm-convert-shr-links' caller (Bug#31151).
* lisp/net/eww.el (eww-link-keymap): Only inherit the normal shr
keymap.
(eww-image-link-keymap): New keymap with the image bindings.
(eww-tag-a): Use the appropriate one on links (bug#30148).
* doc/misc/url.texi (file/ftp): Remove mention of the
url-directory-index-file variable, which is no longer consulted.
* lisp/url/url-file.el (url-file-build-filename): Remove the DWIM
code from the file: handler (bug#30195): It would look for
index.html in a directory if we asked it to fetch the directory.
Determining what to do in a directory should be left up to the
programs that use this low-level library. If the library decides
to load a different file than we specified, then things start
falling apart, as demonstrated by this bug report.
Don't bind image commands on non-image links in Gnus
* lisp/gnus/mm-decode.el (mm--images-in-region-p): New utility
function.
(mm-convert-shr-links): Only use the shr image map on links that
contain images. This avoids binding commands like `r' on links
that don't need it.
From the discussion on the ding mailing list, I said:
I think the colours should be reverted back to what they were before the
change. Normal text should be white on black (if you have a dark
background), and colours should be used to emphasise or de-emphasise
certain text. Following that principle, normal Gnus groups should be
white, not ... er... what are they now? Teal?
* lisp/gnus/gnus-sum.el (gnus-summary-exit-no-update): When
exiting the summary buffer with `Q', move point to the next unread
group (which is the same thing that happens on `q' exit.)
Tweak point placement in gnus-summary-select-article-buffer
* lisp/gnus/gnus-sum.el (gnus-summary-select-article-buffer):
Tweak where point is placed because when the user selects the
article buffer, it's probably to cite something or click on
something, and not do anything with the headers.
Eric Abrahamsen [Sun, 8 Apr 2018 23:49:20 +0000 (16:49 -0700)]
Further fix to eieio-persistent
* lisp/emacs-lisp/eieio-base.el (eieio-persistent-validate/fix-slot-value):
Make handling of hash tables and vectors recursive. This is
necessary because the write process, in `eieio-override-prin1' is
also recursive. With any luck, this will be the last fix of its
kind. If that's true, cherry-pick to Emacs 26.2 later on.
Make nnimap parse pathological spam headers better
* lisp/gnus/nnimap.el (nnimap-transform-headers): Unfold certain
pathological IMAP headers more correctly (bug#25502). Perhaps
this function should be re-implemented.
* lisp/url/url-http.el (url-http--get-referer): Be IDNA-aware.
(url-http-create-request): Don't de-Unicodify host names, because
they may be IDNA names (that are later encoded).
* lisp/url/url-util.el (url-domain): Be IDNA-aware when doing
domain name computations.
* doc/misc/url.texi (Customization): Describe the new user
option url-lastloc-privacy-level.
* lisp/net/eww.el (eww-render): Set url-current-lastloc to the
url we are rendering, to get the referer header right on
subsequent requests.
* lisp/url/url-http.el (url-http--get-referer): New function
to determine which referer to send, if any, considering the
users privacy settings and the target url we are visiting.
(url-http-referer): New variable keeping track of the referer
computed by url-http--get-referer
(url-http-create-request): Use url-http-referer instead of the
optional argument to set up the referer header. Leave
checking of privacy settings to url-http--get-referer.
(url-http): Set up url-http-referer by using
url-http--get-referer.
* lisp/url/url-queue.el (url-queue): New struct member
context-buffer for keeping track of the context a queued job
started from.
(url-queue-retrieve): Store the current buffer in the queue
object.
(url-queue-start-retrieve): Make sure url-retrieve is called
in the context of the original buffer, if available.
* lisp/url/url-util.el (url-domain): New function to determine
the domain of a given URL.
* lisp/url/url-vars.el (url-current-lastloc): New variable to
keep track of the desired "last location" (referer header).
(url-lastloc-privacy-level): New custom setting for more
fine-grained control over how lastloc (referer) is sent to
servers (Bug#27012).
* lisp/net/eww.el (eww-render): When we have a #link link, then
url.el will say that we have a redirect to a non-#link link, so
get the anchor before url.el mangles the URL (bug#28441).
(eww-display-html): ... and don't get it here, because it's gone
by now.
Eli Zaretskii [Fri, 13 Apr 2018 12:48:04 +0000 (15:48 +0300)]
Avoid segfault in processes of type 'pipe'
* src/process.c (Fmake_pipe_process): Set up the decoding and
encoding buffers. For the details, see
http://lists.gnu.org/archive/html/emacs-devel/2018-04/msg00295.html.
When opening external links in eww, blink the link
* lisp/net/eww.el (eww-follow-link): Ditto.
* lisp/net/shr.el (shr-selected-link): New face (bug#25096).
(shr--blink-link): New function to blink links.
(shr--current-link-region): New utility function.
(shr-browse-url): Use it to blink external links.
Blinking the link allows the user to get immediate feedback that the
action has been performed. Opening the external browser may take a
while, and may not be obvious that is going on.
* lisp/gnus/nnimap.el (nnimap-sequence): Start the sequence at a
higher number to avoid reusing the sequence number used by
`open-network-stream' (bug#30022).
* lisp/url/url-http.el (url-http-parse-headers): Treat 302 as 303,
since this is what the standards recommend these days (bug#25703).
See https://en.wikipedia.org/wiki/List_of_HTTP_status_codes#3xx_Redirection
* lisp/net/shr.el (shr-tag-label): Remove so that labels don't
break lines (because they shouldn't: They're usually part of a
selection interface) (bug#30557).
Support list of default values in completing-read-multiple
* lisp/emacs-lisp/crm.el (completing-read-multiple):
Consider head of DEF argument when specified as a list,
as per completing-read-default. (bug#30072)
* doc/misc/gnus.texi (Summary Mail Commands): Ditto.
* doc/misc/message.texi (Forwarding): Note the new default.
* lisp/gnus/message.el (message-forward-as-mime): Default to nil
since it's been reported that many recipients can't read MIME
digest forwards (bug#24878).
Make it possible to exit Gnus without saving .newsrc.eld
* lisp/gnus/gnus-start.el (gnus-save-newsrc-file): Don't error out
here so that we can proceed with shutting down Gnus without saving
the .newsrc.eld file when it has been updated externally (bug#23761).
Make nnml save the .overview file when used as an expiry target
* lisp/gnus/nnmail.el (nnmail-expiry-target-group): Always pass in
the `last' parameter to the acceptance function so that backends
like nnml save the .overview file (bug#24499). This may slow down
some use cases.
* lisp/gnus/message.el (message-simplify-recipients)
(message-recipients-without-full-name): Made obsolete since
Message now simplifies all addresses by default.
Remove repetitions from recipient addresses in Message
* lisp/gnus/message.el (message--alter-repeat-address): New function.
(message-get-reply-headers): Use it to remove repetitions on the
form "foo@bar.com" <foo@bar.com>.
Paul Eggert [Thu, 12 Apr 2018 00:03:43 +0000 (17:03 -0700)]
make-dist: fix bug with top-level ChangeLog
Problem reported by Glenn Morris in:
https://lists.gnu.org/r/emacs-devel/2018-04/msg00307.html
* make-dist (top_level_ChangeLog): New var. Use it to link
top-level ChangeLog only when desired.
Support port number in Gnus X-Message-SMTP-Method header
* lisp/gnus/message.el (message-multi-smtp-send-mail): Try to parse
service as port number. If it succeeds, use parsed number, else use
supplied service name as before (bug#24653). (This only matters
on some operating systems.)
Daniel Dehennin [Wed, 11 Apr 2018 22:40:13 +0000 (00:40 +0200)]
Gnus Group Mail Spliting on mailing-list headers
* texi/gnus.texi: Document the new `list' split abbreviation and
`match-list' group parameter (bug#25346).
* lisp/gnus-mlspl.el: Use the `list' abbreviation when the new
`match-list' group parameter is set to `t'.
The split regexp is modified to match either `@` or `.` as domain
separator to comply with RFC2919 IDs too.
* lisp/nnmail.el: Add new `list' split abbreviation matching common
mailing-list headers.
* lisp/gnus/gnus-sum.el (gnus-summary-next-article): Display the
"No more"... messages if gnus-auto-select-next is nil and the user
has default messaging levels (bug#25582).
Rung new-news-hook from `M-g' in the Gnus summary buffer
* lisp/gnus/gnus-group.el (gnus-group-get-new-news-this-group):
Run `gnus-after-getting-new-news-hook' when doing `M-g' in the
summary buffer, too (bug#25892). This makes `M-g' in both group
and summary buffers work more similar.
* lisp/gnus/gnus-util.el (gnus-rescale-image): Rescale images even
if we don't have a visible article buffer. Reported and fix
suggested by Kevin Brubeck Unhammer.
Don't kill off LibreOffice when selecting the next article in Gnus
* lisp/gnus/mm-decode.el (mm-keep-viewer-alive-types): Add the
media types that LibreOffice uses to the list, since we don't want
to kill off LibreOffice willy-nilly.