1. 27 Oct, 2019 5 commits
    • Jimmy Aguilar Mena's avatar
      Optimize conditional recursive merge face. · ff544e39
      Jimmy Aguilar Mena authored
      * src/xfaces.c (merge_face_vectors) : Pass ATTR_FILTER to
      merge_face_ref to stop recursion merging in advance when possible.
      (merge_named_face) : add more conditions to potentially reduce calls to
      merge_face_vectors in more unneeded situations.
      ff544e39
    • Jimmy Aguilar Mena's avatar
      Fix extend face in gui interfaces. · 87980c22
      Jimmy Aguilar Mena authored
      * src/xdisp.c (extend_face_to_end_of_line) : Change call to
      PRODUCE_GLYPHS with append_stretch_glyph to fill until the windows
      border.
      87980c22
    • Jimmy Aguilar Mena's avatar
      Fix inherited :extend attribute in faces. · fbd57597
      Jimmy Aguilar Mena authored
      * src/xfaces.c (merge_face_vectors) : Add extra parameter ATTR_FILTER
      with the same functionality than in merge_named_face.  Update all
      occurrences.
      (merge_named_face): Remove condition to avoid call
      `merge_face_vectors`.
      fbd57597
    • João Távora's avatar
      Improve scoring algorithm for flex-style completions · 63fd71cd
      João Távora authored
      The previous algorithm had two problems: it considered non-matches in
      the beginning and end of the string as matching "holes" and failed to
      penalize larger holes, making flex-score-match-tightness only
      effective in some corner cases.
      
      The new formula, which is described in code and in pseudo-code in the
      comments, fixes these problems.
      
      As a result, by default, C-h f flex now correctly bubbles up
      "company-search-flex-regexp" to the top, in front of "file-exists-p".
      With a flex-score-match-tightness smaller than 1.0, the situation is
      reversed.
      
      * lisp/minibuffer.el (flex-score-match-tightness): Adjust default
      value.  Improve docstring example.
      (completion-pcm--hilit-commonality): Improve example.  Remove unused
      variable.  Improve algorithm.
      63fd71cd
    • Juanma Barranquero's avatar
      minibuffer.el: Remove leftover code, unused after recent change · f4ee7c83
      Juanma Barranquero authored
      * lisp/minibuffer.el (completion-pcm--hilit-commonality):
      Don't set point-idx.
      f4ee7c83
  2. 26 Oct, 2019 23 commits
    • Juri Linkov's avatar
      dired-dwim-target uses most recently visited window instead of next window. · c6667cc6
      Juri Linkov authored
      * doc/emacs/dired.texi (Operating on Files): Document behavior change.
      
      * lisp/dired-aux.el (dired-dwim-target-directories): New function.
      (dired-dwim-target-directory, dired-dwim-target-defaults): Use it
      to get the most recently used window instead of the next window (bug#35385).
      
      * lisp/dired.el (dired-dwim-target): Doc fix.
      
      * test/lisp/dired-tests.el: Remove unnecessary require and pacify
      byte-compiler.
      c6667cc6
    • Juri Linkov's avatar
      Customizable tab-line-tabs-function and new buffer-local tab-line-mode. · 1660f587
      Juri Linkov authored
      * lisp/tab-line.el (tab-line-tabs-function): Turn defvar into defcustom
      with default of tab-line-tabs-window-buffers.
      (tab-line-tabs-mode-buffers): New function.
      (tab-line-tabs-window-buffers): Rename from tab-line-tabs.
      (tab-line-select-tab, tab-line-switch-to-prev-tab)
      (tab-line-switch-to-next-tab): Handle the value tab-line-tabs-window-buffers
      of tab-line-tabs-function specially.
      (tab-line-mode): Rename from global-tab-line-mode and change scope
      to buffer-local.
      (global-tab-line-mode): New globalized-minor-mode.
      (tab-line-mode--turn-on): New function.
      (tab-line-exclude-modes): New defcustom.
      (tab-line-exclude): New buffer-local variable.
      https://lists.gnu.org/archive/html/emacs-devel/2019-10/msg00988.html
      
      * lisp/dired.el (dired-mark-pop-up): Set tab-line-exclude to nil.
      Don't set tab-line-format.   (Bug#37699)
      * lisp/speedbar.el (speedbar-mode): Set tab-line-exclude to nil.
      Don't set tab-line-format.
      1660f587
    • Juri Linkov's avatar
      * lisp/tab-bar.el (tab-bar-switch-to-recent-tab): New command. · 5a9a0179
      Juri Linkov authored
      (tab-recent): Alias to tab-bar-switch-to-recent-tab.
      (tab-bar--tab-index-recent): New internal function.
      (tab-bar-close-tab-select): Add new default option 'recent'.
      (tab-bar-close-tab): Handle it.
      
      * lisp/emacs-lisp/seq.el (seq-sort-by, seq-remove): Add autoload.
      5a9a0179
    • Juri Linkov's avatar
      * lisp/tab-bar.el (tab-bar-move-tab-to): Add force-mode-line-update. · 802dc5d4
      Juri Linkov authored
      (tab-bar-close-last-tab-choice, tab-bar-close-tab): Adjust option names.
      802dc5d4
    • Robert Cochran's avatar
      Add customization option for what do when the last tab is closed · 6d2ea60c
      Robert Cochran authored
      * lisp/tab-bar.el (tab-bar-close-last-tab-choice): New custom
      variable.
      (tab-bar-close-tab): Handle closing the last tab specially, referring to
      tab-bar-close-last-tab-choice.
      6d2ea60c
    • Stephen Gildea's avatar
      time-stamp-tests: add name prefix to tests of formatting · f247599e
      Stephen Gildea authored
      * time-stamp-tests.el: rename all the time-stamp-string formatting tests
      to have the word "format" in their name, to make room in the namespace
      for other, future tests.
      f247599e
    • João Távora's avatar
      Restore default value of face completions-common-part · 54477c61
      João Távora authored
      The previous commit titled "Rework face hints for partial-string
      completion styles" contained a potentially controversial
      backwards-incompatible change to this face's default value.
      
      * lisp/minibuffer.el (completions-common-part): Restore empty
      default value.
      54477c61
    • Arash Esbati's avatar
      Improve support for biblatex and cleveref macros · 75b9f465
      Arash Esbati authored
      * lisp/textmodes/reftex-cite.el (reftex-figure-out-cite-format):
      Extend regexp to match additional cite commands from biblatex.sty.
      
      * lisp/textmodes/reftex-dcr.el (reftex-view-crossref): Extend
      regexp to match additional cite commands from biblatex.sty and
      reference commands from cleveref.sty.
      75b9f465
    • Arash Esbati's avatar
      Avoid infloop's by doing a case-sensitive match · 368e88b8
      Arash Esbati authored
      * lisp/textmodes/reftex-ref.el (reftex-format-special): Be
      case-sensitive when checking the actual reference macro against
      \ref.  This avoids infloop when \Ref is chosen.
      368e88b8
    • Eli Zaretskii's avatar
    • Glenn Morris's avatar
      Merge from origin/emacs-26 · 8ea63ecd
      Glenn Morris authored
      55dcd32a (origin/emacs-26) Fix rcirc not to interpret nil as nickname ...
      8ea63ecd
    • Glenn Morris's avatar
      ; Merge from origin/emacs-26 · 045bcdb7
      Glenn Morris authored
      The following commit was skipped:
      
      bd0f1731 Fix trig simplification crash (bug#33052)
      045bcdb7
    • Glenn Morris's avatar
      Merge from origin/emacs-26 · 6624fc4b
      Glenn Morris authored
      73e1727c Fix linear equation system solving in Calc (bug#35374)
      
      # Conflicts:
      #	test/lisp/calc/calc-tests.el
      6624fc4b
    • Glenn Morris's avatar
      ; Merge from origin/emacs-26 · 3d7d926e
      Glenn Morris authored
      The following commit was skipped:
      
      bba9757a Backport: Fix an assignment to free variable warning
      3d7d926e
    • João Távora's avatar
      Rework face hints for partial-string completion styles · da0f8dbf
      João Távora authored
      Don't use completions-first-difference for the 'substring', 'flex' and
      'partial-completion' styles, since there can be really no reasonable
      definition of a "first" difference there.
      
      Make completions-common-part inherit from 'underline' so that it is
      useful by default for all completion styles.
      
      * lisp/minibuffer.el (completions-common-part): Adjust
      description and change default value.
      (completions-first-difference): Ajust docstring.
      (completion-pcm--hilit-commonality): Don't use
      completions-first-difference.
      da0f8dbf
    • João Távora's avatar
      Allow completion styles to adjust completion metadata · e21a1da8
      João Távora authored
      This commit re-does the now-reverted commit with the same title.  That
      version relied on generic functions, which cannot be used yet in files
      such as lisp/minibuffer.el.  This version uses a symbol property
      completion--adjust-metadata instead.
      
      The new facility allows completion styles to have a say in metadata
      properties such as cycle-sort-function and display-sort-function.
      This is especially useful for completion styles such as 'flex', which
      generally produce many matches, including some potentially "obscure"
      ones.  The default sorting strategy would often bubble the latter to
      the top of the list.
      
      The sorting function for 'flex' considers pre-computed matching scores
      and is thus much better than the default for this particular style.
      
      Additionally, it overrides the completion table's cycle-sort-function
      or display-sort-function properties if they exist, although it still
      uses them to pre-sort the result, so that they are still relevant for
      resolving ties.
      
      * lisp/minibuffer.el (completion--nth-completion)
      (completion--flex-adjust-metadata): New helper.
      (flex): Put completion--adjust-metadata property.
      e21a1da8
    • João Távora's avatar
      Revert "Allow completion styles to adjust completion metadata" · 878ea4d8
      João Távora authored
      Unbreaks the build.
      
      This reverts commit 7fc0292f.
      
      Unfortunately, cl-defgeneric has some problems when used in
      lisp/minibuffer.el.
      878ea4d8
    • Stefan Monnier's avatar
    • João Távora's avatar
      Allow completion styles to adjust completion metadata · 7fc0292f
      João Távora authored
      The new facility, realized in the completion-adjust-metadata-for-style
      generic, allows completion styles to have a say in metadata properties
      such as cycle-sort-function and display-sort-function.  This is
      especially useful for completion styles such as 'flex', which
      generally produce many matches, including some potentially "obscure"
      ones.  The default sorting strategy would often bubble the latter
      to the top of the list.
      
      The sorting function for 'flex' considers pre-computed matching scores
      and is thus much better than the default for this particular style.
      
      Additionally, it overrides the completion table's cycle-sort-function
      or display-sort-function properties if they exist, although it still
      uses them to pre-sort the result, so that they are still relevant for
      resolving ties.
      
      * lisp/minibuffer.el (completion--nth-completion): Call
      completion-adjust-metadata-for-style.
      (completion-adjust-metadata-for-style): New generic.
      (completion-adjust-metadata-for-style 'flex): New method.
      7fc0292f
    • memeplex's avatar
      Replay key if kboard is interrupted while initializing (Bug#37782) · e3cebbb8
      memeplex authored
      The problem with the original fix for bug#5095 is that it drops
      the current event, which is a valid character event and not -2.
      Thus, the first ESC character sent by the terminal after turning
      on focus tracking is lost and we get '[' and 'I' events separately
      inserted into the buffer afterwards.
      
      * src/keyboard.c (read_key_sequence): Add key as mock_input and replay
      sequence using new keyboard, when the key is not -2.
      e3cebbb8
    • memeplex's avatar
      Remove redundant initialization of fringe bitmap (Bug#37756) · 16372a5a
      memeplex authored
      * src/fringe.c (Fdefine-fringe-bitmap): Remove redundant zeroing
      of fb.bits that only zeroed half of the array anyway.
      16372a5a
    • Eli Zaretskii's avatar
      Improve the documentation of 'vc-tor' · c3b09506
      Eli Zaretskii authored
      * lisp/vc/vc-dispatcher.el (vc-tor): Add :version.  Enhance
      the doc string.
      
      * etc/NEWS: Announce the new option.
      c3b09506
    • Richard Stallman's avatar
      New defcustom 'vc-tor' · 626e0a6a
      Richard Stallman authored
      * lisp/vc/vc-dispatcher.el (vc-tor): New user option.
      (vc-do-command): If vc-tor is non-nil, use 'torsocks'.
      626e0a6a
  3. 25 Oct, 2019 10 commits
    • Tassilo Horn's avatar
      Adapt doc-view to latest image-mode changes · a0f7ea59
      Tassilo Horn authored
      The functions image-scroll-down, image-scroll-up, image-next-line, and
      image-previous-line now return pixel values instead of multiples of
      character height as of commit 9c66b099.
      
      * lisp/doc-view.el (doc-view-scroll-up-or-next-page):
      (doc-view-scroll-down-or-previous-page):
      (doc-view-next-line-or-next-page):
      (doc-view-previous-line-or-previous-page):
      (doc-view-insert-image): Adapt to image-scroll-up/down and
      image-next/previous-line now returning pixel values instead of
      multiples of character heights.  Fixes bug#37874.
      a0f7ea59
    • Alan Mackenzie's avatar
      CC Mode: Fix positioning of point whilst inserting comments without non-ws · 25ed447b
      Alan Mackenzie authored
      * lisp/progmodes/cc-cmds.el (c-guess-fill-prefix): When determining a new
      block comment prefix (i.e. there isn't one already there to copy), and that
      prefix is hard up against a comment closer, ensure there are at least two
      spaces before the closer.
      (c-indent-new-comment-line): Amend the strategy for ensuring that point isn't
      left hard up against the comment closer after M-j.
      25ed447b
    • Stephen Gildea's avatar
      time-stamp-tests: consistently name the time vars · 4e271a6c
      Stephen Gildea authored
      * time-stamp-tests.el (with-time-stamp-test-env): rename local variable
      'ref-time' to 'ref-time1', for parallelism with ref-time2 and ref-time3.
      4e271a6c
    • Michael Albinus's avatar
      084007a5
    • Michael Albinus's avatar
      Mention completion styles for Tramp user/host name completion · 4bcf3a5f
      Michael Albinus authored
      * doc/misc/tramp.texi (File name completion): Emacs must have one
      of the completion styles `basic', `emacs21', or `emacs22'.
      4bcf3a5f
    • Juanma Barranquero's avatar
      windmove.el: Suppress warnings for obsolete functions · d56e8440
      Juanma Barranquero authored
      * lisp/windmove.el (windmove-constrain-loc-for-movement)
      (windmove-wrap-loc-for-movement, windmove-reference-loc)
      (windmove-other-window-loc): Wrap calls to obsolete functions
      in `with-suppressed-warnings'.
      d56e8440
    • Juanma Barranquero's avatar
      windmove.el: Mark unused code as obsolete · 17db4a0a
      Juanma Barranquero authored
      * lisp/windmove.el (windmove-window-distance-delta)
      (windmove-coord-add, windmove-constrain-to-range)
      (windmove-constrain-around-range, windmove-frame-edges)
      (windmove-constrain-loc-for-movement)
      (windmove-wrap-loc-for-movement, windmove-reference-loc)
      (windmove-other-window-loc): Declare obsolete.
      (windmove-find-other-window, windmove-do-window-select):
      Doc fixes.
      
      * etc/NEWS: Document it.
      17db4a0a
    • Juanma Barranquero's avatar
    • Lars Ingebrigtsen's avatar
      Fix gnus-thread-hide-subtree defcustom · fcc427f3
      Lars Ingebrigtsen authored
      * lisp/gnus/gnus-sum.el (gnus-thread-hide-subtree): Make the
      "Non-nil" predicate do what it's supposed to (i.e., return non-nil
      on non-nil values (excepting predicates)) (bug#37916).
      fcc427f3
    • Stefan Monnier's avatar
      * lisp/cedet/mode-local.el: Clean up name space · f131e396
      Stefan Monnier authored
      Mostly renaming functions by adding `mode-local--` to their name
      and leaving an obsolete alias behind, just in case.
      
      (define-child-mode): Make obsolete.
      (mode-local--set-parent): Rename from set-mode-local-parent.
      (mode-local--new-bindings): Rename from new-mode-local-bindings.
      Use `obarray-make`.
      (mode-local--activate-bindings): Rename from activate-mode-local-bindings.
      (mode-local--deactivate-bindings): Rename from
      deactivate-mode-local-bindings.
      (make-obsolete-overload): Rename properties with a `mode-local--` prefix.
      Adjust all users.
      (mode-local--overload-obsoleted-by): Rename from overload-obsoleted-by.
      (mode-local--overload-that-obsolete): Rename from overload-that-obsolete.
      (mode-local--function-overload-p): Rename from function-overload-p.
      (mode-local-read-function): Mark obsolete.
      (mode-local--overload-docstring-extension): Rename from
      overload-docstring-extension.
      (mode-local--describe-overload): Rename from describe-mode-local-overload.
      
      * lisp/cedet/semantic/fw.el (semantic-install-function-overrides):
      Remove unused `mode` argument.
      
      * lisp/cedet/semantic/grammar-wy.el (semantic-grammar-wy--install-parser):
      * lisp/cedet/semantic/bovine/grammar.el (bovine-grammar-mode):
      * lisp/cedet/semantic/texi.el (semantic-default-texi-setup):
      * lisp/cedet/semantic/wisent/grammar.el (wisent-grammar-setupcode-builder)
      (wisent-grammar-mode):
      * lisp/cedet/semantic/html.el (semantic-default-html-setup):
      Make the `semantic-` prefix explicit to ease grep search.
      (html-helper-mode): Remove obsolete setting.
      
      * lisp/cedet/semantic/wisent/javascript.el: Fix js-mode/javascript-mode
      mixup so we don't need define-child-mode any more.
      (semantic-get-local-variables, semantic-ctxt-current-symbol)
      (semantic-tag-protection, semantic-analyze-scope-calculate-access):
      Use `js-mode` rather than `javascript-mode` as the mode name since
      that's the real mode's name.
      
      * lisp/cedet/semantic/wisent/python.el (python-2-mode, python-3-mode):
      Remove child declaration for non-existing modes.
      
      * lisp/cedet/srecode/map.el (srecode-map-validate-file-for-mode): Simplify.
      f131e396
  4. 24 Oct, 2019 2 commits
    • Paul Eggert's avatar
      Update from Gnulib · 4a083b0d
      Paul Eggert authored
      This incorporates:
      2019-10-23 nstrftime: speed up integer overflow checking
      2019-10-23 port better to GCC under macOS
      2019-10-15 inttypes: use more-robust test for int range
      2019-10-14 update-copyright: use en dashes in .texi ranges
      * build-aux/update-copyright, lib/intprops.h, lib/inttypes.in.h:
      * lib/nstrftime.c, lib/verify.h:
      Copy from Gnulib.
      4a083b0d
    • Juanma Barranquero's avatar