1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-15 10:30:25 -08:00
Commit graph

130552 commits

Author SHA1 Message Date
Noam Postavsky
a58d0c590a Fix loading of smie-config rules (Bug#24848)
* lisp/emacs-lisp/smie.el (smie-config--setter): Use `set-default'
instead of `setq-default'.
(smie-config): Use `custom-initialize-set' instead of
`custom-initialize-default' as the :initialize argument.

* lisp/progmodes/sh-script.el (sh-learn-buffer-indent): Mention that
we call `smie-config-guess' so that the user will have a chance to
find the correct docstring to consult.  Remove hedging comments
regarding use of abnormal hooks.
2017-09-25 19:39:19 -04:00
Dmitry Gutov
3a68dec327 ; Update NEWS for the change in eldoc-message 2017-09-26 02:25:03 +03:00
Dmitry Gutov
5a41dd0a1f Reset default-directory inside *xref-grep* buffer
* lisp/progmodes/xref.el (xref-collect-matches):
Reset default-directory, too. (Bug#28575)
2017-09-26 01:47:23 +03:00
Michael Albinus
49cd561dc6 * test/lisp/tramp-tests.el (tramp-test21-file-links): Special code for smb. 2017-09-25 17:52:24 +02:00
Mark Oteiza
b719f6b20b Loosen strict parsing requirement for desktop files
There are other desktop-looking files, for instance those having to do
with MIME typess, that would benefit from being able to be read by this
function.  It helps to have some flexibility.
* lisp/xdg.el (xdg-desktop-read-file): Remove an error condition.
* test/lisp/xdg-tests.el: Remove a test.
2017-09-25 08:45:08 -04:00
Mark Oteiza
c7a0c13777 * lisp/xdg.el (xdg-thumb-uri): Fix doc string. 2017-09-25 08:44:23 -04:00
Martin Rudalics
dc6b3560e5 Fix documentation of `make-frame' and related variables and hooks
* lisp/frame.el (before-make-frame-hook)
(after-make-frame-functions, frame-inherited-parameters)
(make-frame): Fix doc-strings.
* doc/lispref/frames.texi (Creating Frames): Fix description
of `make-frame' and related variables and hooks.
2017-09-25 10:09:32 +02:00
Eric Abrahamsen
3d3778d82a Accept new always' value for option buffer-offer-save'
Also revert ee512e9a82

* lisp/files.el (buffer-offer-save): In addition to nil and t, now
  allows a third symbol value, `always'. A buffer where this option is
  set to `always' will always be offered for save by
  `save-some-buffers'.
  (save-some-buffers): Check the exact value of this buffer-local
  variable. No longer check the buffer name, or the value of
  `write-contents-functions'.
* doc/lispref/buffers.texi (Killing Buffers): Note change in manual.
* doc/lispref/files.texi (Saving Buffers): Remove note about buffer
  names.
* etc/NEWS: Mention in NEWS.
2017-09-24 14:57:40 -07:00
Alan Third
638f64c40a Improve new NS scrolling variable names
* src/nsterm.m (ns-use-system-mwheel-acceleration): Replace with
'ns-use-mwheel-acceleration'.
(ns-touchpad-scroll-line-height): Replace with
'ns-mwheel-line-height'.
(ns-touchpad-use-momentum): Replace with 'ns-use-mwheel-momentum'.
* etc/NEWS: Change variable names.
2017-09-24 22:47:50 +01:00
Philipp Stephani
d93301242f Document 'replace-buffer-contents' in the manual.
* doc/lispref/text.texi (Replacing): New node.
2017-09-24 19:32:16 +02:00
Alan Third
00e4e3e9d2 Fix undecorated frame resizing issues on NS (bug#28512)
* src/nsterm.m (EmacsView::updateFrameSize): Don't wait for the
toolbar on undecorated frames.
(EmacsView::initFrameFromEmacs): Group window flags correctly.
2017-09-23 19:47:21 +01:00
Eli Zaretskii
820739bbb5 ; * doc/emacs/display.texi (Display Custom): Fix wording. 2017-09-23 10:45:46 +03:00
Paul Eggert
f2b2201594 ; Spelling and URL fixes 2017-09-23 00:36:56 -07:00
Eli Zaretskii
0e143b1fc5 Documentation improvements for 'display-line-numbers'
* doc/emacs/display.texi (Display Custom): Document a few more
options for display-line-numbers.  (Bug#28533)  Fix a typo.
2017-09-23 10:07:11 +03:00
Mark Oteiza
f656ccdb43 ; Fix typo
* lisp/emacs-lisp/subr-x.el: Nix extra parenthesis.
2017-09-22 16:34:31 -04:00
Eli Zaretskii
d64da52d57 Fix last change in bat-mode.el
* lisp/progmodes/bat-mode.el (bat-font-lock-keywords): Fix last
change.  (Bug#28311)
2017-09-22 20:41:10 +03:00
Eli Zaretskii
908af46abd Fix restoring in GUI sessions desktop saved in TTY sessions
* lisp/frameset.el (frameset-filter-font-param): New function.
(frameset-persistent-filter-alist): Use it for processing the
'font' frame parameter.  (Bug#17352)
2017-09-22 17:52:47 +03:00
Eli Zaretskii
51cbd85454 Improve syntax highlighting in bat-mode
* lisp/progmodes/bat-mode.el (bat-font-lock-keywords): Improve
font-locking of environment variables.  Suggested by Achim Gratz
<Stromeko@nexgo.de>.  (Bug#28311)  (Bug#18405)
2017-09-22 16:40:59 +03:00
Eli Zaretskii
0273916618 Document the 'list-FOO' convention
* doc/lispref/tips.texi (Coding Conventions): Document the
list-FOO convention.
2017-09-22 12:41:00 +03:00
Mark Oteiza
d24ec58540 Expose viewing conditions in CAM02-UCS metric
Also add tests from the colorspacious library.  Finally, catch an
errant calculation, where degrees were not being converted to radians.
* src/lcms.c (deg2rad, default_viewing_conditions):
(parse_viewing_conditions): New functions.
(lcms-cam02-ucs): Add comments pointing to references used.  Expand
the docstring and explain viewing conditions.  JCh hue is given in
degrees and needs to be converted to radians.
(lcms-d65-xyz): Remove.  No need to duplicate this in Lisp or make the
API needlessly impure.
* test/src/lcms-tests.el: Reword commentary.
(lcms-rgb255->xyz): New function.
(lcms-cri-cam02-ucs): Fix let-binding.
(lcms-dE-cam02-ucs-silver): New test, assimilated from colorspacious.
2017-09-21 23:06:00 -04:00
Alan Third
a81d5a3d3f Revert "Set frame size to actual requested size (bug#18215)"
This reverts commit d31cd79b40.

See bug#28536. I misunderstood bug#18215. It wasn't a bug.
2017-09-21 22:08:48 +01:00
Gemini Lasswell
0bf066d4b2 Add tests for Edebug
* tests/lisp/emacs-lisp/edeug-tests.el: New file.
* tests/lisp/emacs-lisp/edebug-resources/edebug-test-code.el: New file.
2017-09-21 13:36:08 -07:00
Gemini Lasswell
68baca3ee1 Catch more messages in ert-with-message-capture
* lisp/emacs-lisp/ert-x.el (ert-with-message-capture): Capture
messages from prin1, princ and print.
(ert--make-message-advice): New function.
(ert--make-print-advice): New function.
2017-09-21 13:35:45 -07:00
Eli Zaretskii
28e0c410c9 ; * lisp/mouse.el (secondary-selection-exist-p): Doc fix. 2017-09-21 11:29:11 +03:00
Tak Kunihiro
31e1d9ef2f Support setting region from secondary selection and vice versa
* lisp/mouse.el (secondary-selection-exist-p): New function to
allow callers to tell existence of the secondary selection
in current buffer.
(secondary-selection-to-region): New function to set
beginning and end of the region from those of the secondary
selection.
(secondary-selection-from-region): New function to set
beginning and end of the secondary selection from those of
the region.  (Bug#27530)

* etc/NEWS: Mention the new functions.
2017-09-21 11:26:00 +03:00
Paul Eggert
047f02f00f Fix new copy-directory bug with empty dirs
Problem reported by Afdam Plaice (Bug#28520) and by Eli Zaretskii
(Bug#28483#34).  This is another bug that I introduced in my
recent copy-directory changes.
* lisp/files.el (copy-directory): Work with empty subdirectories, too.
* test/lisp/files-tests.el (files-tests--copy-directory):
Test for this bug.
2017-09-20 11:50:35 -07:00
Eli Zaretskii
fbd15836af * doc/lispref/strings.texi (Formatting Strings): Improve indexing. 2017-09-20 16:40:20 +03:00
Eli Zaretskii
f16a8d5dbd Fix 2 testsuite tests for MS-Windows
* test/lisp/ibuffer-tests.el (test-buffer-list): Don't try to
create files with "*" in their names.
* test/src/editfns-tests.el (format-time-string-with-zone): Adapt
results to MS-Windows build.  Reported by Fabrice Popineau
<fabrice.popineau@gmail.com>.
2017-09-20 10:16:11 +03:00
Mark Oteiza
965cffd89c Rename timer-list to list-timers
* doc/emacs/anti.texi (Antinews):
* doc/lispref/os.texi (Timers):
* etc/NEWS:
* lisp/emacs-lisp/timer-list.el:
(timer-list-mode): Rename timer-list to list-timers.
2017-09-19 22:24:23 -04:00
Alan Third
a5fec62b51 Provide native touchpad scrolling on macOS
* etc/NEWS: Describe changes.
* lisp/term/ns-win.el (mouse-wheel-scroll-amount,
mouse-wheel-progressive-speed): Set to smarter values for macOS
touchpads.
* src/nsterm.m (emacsView::mouseDown): Use precise scrolling deltas to
calculate scrolling for touchpads and mouse wheels.
(syms_of_nsterm): Add variables 'ns-use-system-mwheel-acceleration',
'ns-touchpad-scroll-line-height' and 'ns-touchpad-use-momentum'.
* src/keyboard.c (make_lispy_event): Pass on .arg when relevant.
* src/termhooks.h (event_kind): Update comments re. WHEEL_EVENT.
* lisp/mwheel.el (mwheel-scroll): Use line count.
* lisp/subr.el (event-line-count): New function.
2017-09-19 20:08:51 +01:00
Eli Zaretskii
7b3d1c6beb Fix MinGW64 build broken by recent MinGW64 import libraries
* configure.ac (W32_LIBS): Put -lusp10 before -lgdi32, as latest
MinGW64 import libraries require that.  (Bug#28493)

* src/Makefile.in: Adjust commentary to the new order of w32
libraries.
2017-09-19 20:31:02 +03:00
Eli Zaretskii
c83d0c5fdf Fix crashes in 'move-point-visually' in minibuffer windows
* src/xdisp.c (Fmove_point_visually): Fix off-by-one error in
comparing against the last valid glyph_row of a window glyph
matrix.  (Bug#28505)
2017-09-19 20:11:42 +03:00
Eli Zaretskii
7f3d5f929d * src/emacs.c (usage_message): Don't mention 'find-file'. 2017-09-19 19:52:50 +03:00
Eli Zaretskii
6845282200 Fix a minor inaccuracy in the Emacs manual
* doc/emacs/cmdargs.texi (Action Arguments): Don't mention
'find-file', as the implementation has changed.  Reported by
Everton J. Carpes <everton.carpes@gmail.com> in
http://lists.gnu.org/archive/html/help-gnu-emacs/2017-09/msg00146.html.
2017-09-19 19:48:27 +03:00
Eli Zaretskii
74d7bb9498 Fix errors in flyspell-post-command-hook
* lisp/textmodes/ispell.el (ispell-get-decoded-string): Handle the
case of a nil Nth element of the language dictionary slot.  This
avoids errors in 'flyspell-post-command-hook' when switching
dictionaries with some spell-checkers.  (Bug#28501)
2017-09-19 19:32:09 +03:00
Michael Albinus
40fdbb01d0 Work on Tramp's file-truename
* lisp/net/tramp-sh.el (tramp-perl-file-truename):
Check also for symlinks.
(tramp-sh-handle-file-truename): Move check for a symlink
cycle to the end.  Do not blame symlinks which look like a
remote file name.

* lisp/net/tramp.el (tramp-handle-file-truename): Expand result.
2017-09-19 18:12:35 +02:00
Paul Eggert
1a01423b3c Fix bug with make-directory on MS-Windows root
* lisp/files.el (files--ensure-directory): Treat any error, not
just file-already-exists, as an opportunity to check whether DIR
is already a directory (Bug#28508).
2017-09-19 01:48:04 -07:00
Tom Tromey
066efb8666 Fix log-view-diff-common when point is after last entry
Bug#28466
* lisp/vc/log-view.el (log-view-diff-common): If point is after last
entry, look at the previous revision.
2017-09-18 20:02:01 -06:00
Ken Brown
3f006b56cd Adapt fileio-tests--symlink-failure to Cygwin
* test/src/fileio-tests.el (fileio-tests--symlink-failure)
[CYGWIN]: Skip the case of a symlink target starting with '\';
this is treated specially on Cygwin.
2017-09-18 17:22:52 -04:00
Eric Abrahamsen
ee512e9a82 Ignore buffers whose name begins with a space in save-some-buffers
* lisp/files.el (save-some-buffers): Consider these buffers
  "internal", and don't prompt the user to save them.
* doc/lispref/files.texi: Document.
2017-09-18 13:29:44 -07:00
Michael Albinus
9e1b5bd92c Improve tramp-interrupt-process robustness
* lisp/net/tramp.el (tramp-interrupt-process): Wait, until the
process has disappeared.
2017-09-18 18:00:27 +02:00
Michael Albinus
8d4223e61b Minor Tramp doc update
* doc/misc/tramp.texi (Frequently Asked Questions):
Mention `vc-handled-backends'.
2017-09-18 18:00:07 +02:00
Mark Oteiza
331d0e520f Fix gensym
* lisp/subr.el (gensym): Actually implement the default prefix.
* test/lisp/subr-tests.el (subr-tests--gensym): New test.
2017-09-18 09:00:45 -04:00
Michael Albinus
466df76f7d Cleanup in files-tests.el
* test/lisp/files-tests.el (files-tests--make-directory)
(files-tests--copy-directory): Cleanup temporary directories.
2017-09-18 10:00:17 +02:00
Paul Eggert
6359fe630a Remove old cl-assert calls in 'newline'
* lisp/simple.el (newline): Remove cl-assert calls
that didn't seem to be helping us debug Bug#18913,
and that caused problems as reported in Bug#28280.
Suggested by Glenn Morris (Bug#28280#8).
2017-09-17 22:32:55 -07:00
Paul Eggert
059184e645 Avoid crash with C-g C-g in GC
Problem reported by Richard Stallman (Bug#17406).
Based on fix suggested by Eli Zaretskii (Bug#28279#16).
* src/term.c (tty_send_additional_strings):
Use only safe accessors, to avoid crash when C-g C-g in GC.
2017-09-17 22:03:00 -07:00
Paul Eggert
541006c536 Fix format-time-string %Z bug with negative tz
* src/editfns.c (tzlookup): Fix sign error in %Z when a purely
numeric zone is negative (Bug#28746).
* test/src/editfns-tests.el (format-time-string-with-zone):
Add test for this bug.
2017-09-17 20:39:12 -07:00
Paul Eggert
679e05eeb9 message-citation-line-format %Z is now tz name
* etc/NEWS:
* lisp/gnus/message.el (message-citation-line-format):
Fix doc to match new behavior (Bug#28476).
2017-09-17 17:46:58 -07:00
Mark Oteiza
4e8888d438 Use doc-view or pdf-tools on any window-system
* lisp/net/mailcap.el (mailcap-mime-data): Simply check for
window-system.
2017-09-17 19:39:35 -04:00
Paul Eggert
5f28f0db73 Fix bug with min and max and NaNs
* src/data.c (minmax_driver): Fix bug with (min 0 NaN), which
mistakenly yielded 0.  Also, pacify GCC in a better way.
* test/src/data-tests.el (data-tests-min): Test for the bug.
2017-09-17 15:26:41 -07:00