memeplex [Tue, 15 Oct 2019 00:37:20 +0000 (21:37 -0300)]
Avoid extra lines in python-shell font lock buffer (Bug#33959)
* lisp/progmodes/python.el
(python-shell-font-lock-comint-output-filter-function): Avoid writing
a newline to the font lock buffer when receiving an empty string.
Juri Linkov [Tue, 22 Oct 2019 21:17:27 +0000 (00:17 +0300)]
Tab-line horizontal scrolling with UI buttons and commands (bug#37667)
* etc/images/tabs/left-arrow.xpm:
* etc/images/tabs/right-arrow.xpm: New images.
* lisp/tab-line.el (tab-line-left-map, tab-line-right-map): New keymaps.
(tab-line-left-button, tab-line-right-button): New variables.
(tab-line-tab-name-function): Turn defvar into defcustom.
(tab-line-tab-name-buffer): New function.
(tab-line-tab-name-truncated-buffer): Rename from tab-line-tab-name.
(tab-line-tabs-limit): Default to nil.
(tab-line-tabs): Behavior depends on tab-line-tabs-limit.
(tab-line-format): Use window-parameter tab-line-hscroll.
Add left/right buttons.
(tab-line-hscroll): New function.
(tab-line-hscroll-right, tab-line-hscroll-left): New commands
bound to mouse-wheel. Rebind tab-switching commands to mouse-wheel
with Ctrl-modifier.
* lisp/tab-bar.el (require): Require seq when compiling to avoid a
compilation warning. The function it uses is autoloaded, but
autoloads aren't loaded when this is built (on "make bootstrap").
Make edebug-eval-last-sexp interactively take a zero prefix
* lisp/emacs-lisp/edebug.el (edebug-eval-last-sexp): Make the zero
prefix work analogously to in eval-last-sexp (bug#28895).
(edebug-eval-print-last-sexp): Ditto.
Robert Pluim [Tue, 22 Oct 2019 07:31:15 +0000 (09:31 +0200)]
Show stash counts in button in vc-dir
Based on suggestions from Mattias Engdegård.
* lisp/vc/vc-git.el (vc-git--make-button-text): New function to
generate text for stash button.
(vc-git-make-stash-button): Show stash counts. Delete and recreate
button when toggling.
(vc-git-dir-extra-headers): Pass counts to vc-git-make-stash-button.
Treat stash count <= vc-git-show-stash as equivalent to showing entire
list.
Arash Esbati [Sun, 20 Oct 2019 18:27:00 +0000 (20:27 +0200)]
Move entry for \Ref into LaTeX core
* lisp/textmodes/reftex-vars.el (reftex-ref-style-alist): Move
entry for \Ref from "Varioref" into "Default" as this macro is
part of LaTeX 2019-10-01 kernel.
Rearrange entries for "Varioref".
Paul Eggert [Tue, 22 Oct 2019 00:28:02 +0000 (17:28 -0700)]
Portcheck only if --enable-gcc-warnings
Problem reported by Richard Copley (Bug#37852).
This patch causes the problem to not occur if one uses plain
‘configure’. The problem can still occur if with ‘configure
--enable-gcc-warnings’, so a further fix may be needed.
* configure.ac (GNULIB_PORTCHECK, _FORTIFY_SOURCE):
Define these only with an explicit --enable-gcc-warnings.
* lisp/vc/vc-git.el (vc-git-show-stash):New user option.
(vc-git-make-stash-button): Create button that allows hiding the stash
list.
(vc-git-dir-extra-headers): Split stash list into hideable and
non-hideable parts depending on value of vc-git-show-stash. Add
button to toggle visibility of hideable part.
Add a way to disable substitution of command keys in help strings
* src/keyboard.c (help_echo_substitute_command_keys): New function.
(help_echo_echo, parse_menu_item): Use it.
(syms_of_keyboard): Define Qhelp_echo_inhibit_substitution.
* doc/lispref/text.texi (Special Properties), etc/NEWS: Document
the effect of 'help-echo-inhibit-substitution'.
Juri Linkov [Sun, 20 Oct 2019 22:37:39 +0000 (01:37 +0300)]
* lisp/tab-line.el: Bind mouse commands to [tab-line].
* lisp/tab-line.el: Bind mouse-4/mouse-5, wheel-up/wheel-down
globally to [tab-line].
(tab-line-tab-map): Remove local bindings of mouse-4/mouse-5.
(tab-line-new-tab, tab-line-switch-to-prev-tab)
(tab-line-switch-to-next-tab, tab-line-close-tab):
Turn commands into mouse-free (can be used without mouse).
* lisp/emacs-lisp/edebug.el (edebug-disabled-breakpoint): New face
(bug#23472).
(edebug-enabled-breakpoint): Rename.
(edebug--overlay-breakpoints): Use the new face.
(edebug-toggle-disable-breakpoint): New command and keystroke.
Alan Mackenzie [Sun, 20 Oct 2019 16:55:26 +0000 (16:55 +0000)]
Optimize c-crosses-statement-barrier-p for large blocks of comment.
This fixes bug #18134.
* lisp/progmodes/cc-engine.el (c-crosses-statement-barrier-p): Give a limit
to the c-backward-syntactic-ws which is searching for a virtual semicolon. In
the main loop, Use c-forward-syntactic-ws to skip blocks of comments.
Juri Linkov [Sun, 20 Oct 2019 16:30:30 +0000 (19:30 +0300)]
Provide default value for tab-name/frame-name reading minibuffer
* lisp/tab-bar.el (tab-bar-rename-tab, tab-bar-rename-tab-by-name):
Provide default value for read-string.
(tab-bar-select-tab-by-name): Alias for tab-bar-switch-to-tab.
* lisp/frame.el (set-frame-name): Provide default value for
read-string in interactive spec.
* lisp/cus-start.el (tab-bar-position): Use choice instead of boolean.
* lisp/emacs-lisp/edebug.el (edebug--recursive-edit): Bind
minor-mode-overriding-map-alist to avoid other minor modes hiding the
edebug commands (bug#11018).
Stefan Kangas [Fri, 18 Oct 2019 20:16:50 +0000 (22:16 +0200)]
Update FAQ entry on XEmacs (Bug#37815)
* doc/misc/efaq.texi (Difference between Emacs and XEmacs): Update
section to reflect the current state of affairs. XEmacs is not
actively developed and is lacking many important features of Emacs.
Stefan Kangas [Sat, 19 Oct 2019 00:51:21 +0000 (02:51 +0200)]
Improve doc string of eshell and eshell-buffer-name
* lisp/eshell/eshell.el (eshell-buffer-name, eshell): Improve doc
strings, by clarifying how buffers are named. Also refer users to the
Info manual. (Bug#37178)
* lisp/emacs-lisp/edebug.el (edebug--overlay-breakpoints)
(edebug--overlay-breakpoints-remove): New functions (bug#23468).
(edebug-modify-breakpoint): Use them to highlight breakpoints.
(edebug--display-1): Restore breakpoint highlights.
(edebug--recursive-edit): Remove highlights on exit.
Fix doc string and interactive spec of cancel-edebug-on-entry
* lisp/emacs-lisp/edebug.el (cancel-edebug-on-entry): Add doc
string and make the interactive spec complete over functions that
have the spec (bug#10806).
(edebug-cancel-edebug-on-entry): Add alias for discoverability.
(edebug-on-entry): Clarify what this command does.
Stefan Kangas [Sat, 19 Oct 2019 13:04:13 +0000 (15:04 +0200)]
Don't explain FTP acronym in FAQ
* doc/misc/efaq.texi (Common acronyms): Remove explanation of the FTP
acronym. Emacs is no longer distributed over FTP, and the FAQ doesn't
refer to any other FTP URLs.
Raimon Grau [Sat, 19 Oct 2019 09:46:17 +0000 (11:46 +0200)]
Fix optional parameter passing in calc-fin-* functions
* lisp/calc/calc-fin.el (calc-fin-pv, calc-fin-fv, calc-fin-pmt)
(calc-fin-pner, calc-fin-rate): Add support for an optional
parameter standing for an initial lump. The functions already
support it but the extra parameter was not taken into account in
stack mode. This commit it takes into consideration when deciding
if a function takes 3 or 4 parameters (bug#37649).
Eli Zaretskii [Sat, 19 Oct 2019 09:12:31 +0000 (12:12 +0300)]
Fix display of Info files on TTY frames
* lisp/info.el (info-symbols-and-replacements): New variable.
(Info-mode): Use 'info-symbols-and-replacements' to set up a
buffer-display-table for non-ASCII symbols used by Info files
that cannot be displayed on TTY frames.
Eli Zaretskii [Sat, 19 Oct 2019 07:42:14 +0000 (10:42 +0300)]
A better fix for tab-line mouse highlight on TTY frames
* src/dispnew.c (mode_line_string):
* src/xdisp.c (note_mode_line_or_margin_highlight): Remove
recently-added workarounds for incorrect TTY mouse highlight:
they are no longer needed.
(mark_window_display_accurate_1): Set the header_line_p and
tab_line_p flags of the window's current_matrix if the window
displays these.
(display_mode_line): Set the header_line_p and tab_line_p
flags of the window's desired_matrix if the window displays
these. (Bug#37807)
Paul Eggert [Fri, 18 Oct 2019 22:33:13 +0000 (15:33 -0700)]
Pacify x86 GCC 9 in tab bar code
* src/xdisp.c (tty_get_tab_bar_item): Simplify a bit. This
pacifies --enable-gcc-warnings with x86 GCC 9.2.1 20190827
(Red Hat 9.2.1-1) when combined with -fsanitize=undefined.
Paul Eggert [Fri, 18 Oct 2019 20:21:11 +0000 (13:21 -0700)]
Generalize list1i etc. to all signed integer types
* src/lisp.h (list1i, list2i, list3i, list4i):
Accept intmax_t instead of EMACS_INT, and use make_int instead
of make_fixnum. This should help avoid integer-overflow
problems akin to the Time bug (Bug#37795).
Paul Eggert [Fri, 18 Oct 2019 20:07:49 +0000 (13:07 -0700)]
Fix integer-overflow bug in Time conversion
Problem reported by Stefan Monnier (Bug#37795).
* src/keyboard.c (make_lispy_position)
(make_scroll_bar_position, make_lispy_event):
* src/xterm.c (x_ewmh_activate_frame):
Use INT_TO_INTEGER to convert Time to a Lisp integer,
since the value might not be a fixnum.
Eli Zaretskii [Fri, 18 Oct 2019 15:48:31 +0000 (18:48 +0300)]
Fix mouse highlight with tab-line on TTY frames
* src/xdisp.c (note_mode_line_or_margin_highlight):
* src/dispnew.c (mode_line_string): Fix mouse highlight on TTY
frames when both header line and tab-line are displayed.
(Bug#37807)
Eli Zaretskii [Fri, 18 Oct 2019 14:55:21 +0000 (17:55 +0300)]
Fix handling of mouse events on header line with tab-line
* src/window.c (coordinates_in_window): Fix conditions for
coordinates being on the window's header line when that
window also displays a tab-line. (Bug#37807)
Use [^z-a] for matching any character (anychar/anything) in rx
* lisp/emacs-lisp/rx.el (rx--translate-symbol):
* test/lisp/emacs-lisp/rx-tests.el (rx-any, rx-atoms):
Use [^z-a] instead of ".\\|\n" for anychar.
The new expression is faster (about 2×) and does not allocate regexp
stack space. For example, (0+ anychar) now matches strings of any
size (bug#37659).
Add `anychar' as alias to `anything' in rx (bug#37659)
* lisp/emacs-lisp/rx.el (rx--translate-symbol, rx--builtin-symbols, rx):
* test/lisp/emacs-lisp/rx-tests.el (rx-atoms):
* doc/lispref/searching.texi (Rx Constructs):
* etc/NEWS:
Add `anychar', an alias for `anything'. Since `anychar' is more
descriptive (and slightly shorter), treat it as the preferred name.