1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-25 07:28:20 +00:00
Commit Graph

166 Commits

Author SHA1 Message Date
João Távora
b1f8d98a11 Eglot: rework eglot-imenu
Most newer servers return a vector of 'DocumentSymbol' as a response
to 'textDocument/documentSymbol'.  It's not worth trying to dumb this
down to imenu format of 'SymbolInformation' vectors.

This lays groundwork for the forthcoming "breadcrumb" feature of
bug#58431.

* lisp/progmodes/eglot.el
(eglot--imenu-SymbolInformation, eglot--imenu-DocumentSymbol): New
helpers.
(eglot-imenu): Rework.
2023-04-07 12:57:59 +01:00
Eli Zaretskii
cae528457c ; Add 2023 to copyright years. 2023-01-01 05:31:12 -05:00
Lars Ingebrigtsen
915efbff98 Make buffer-local-value obsolete as a generalized variable
* lisp/electric.el (electric-indent-local-mode)
(electric-layout-local-mode, electric-quote-local-mode):
* lisp/elec-pair.el (electric-pair-local-mode): Adjust usage.
* lisp/emacs-lisp/gv.el (make-obsolete-generalized-variable): Move
since we're using it earlier in the file.
(buffer-local-value): Make obsolete as a generalized variable
since the semantics are unclear (bug#26624).
2022-08-23 12:22:42 +02:00
Lars Ingebrigtsen
ae5fe348fb Revert "Make the generalized buffer-local-variable obsolete"
This reverts commit bfe222288e.

This led to the local modes not working.
2022-08-22 00:14:07 +02:00
Lars Ingebrigtsen
bfe222288e Make the generalized buffer-local-variable obsolete
* lisp/paren.el (show-paren-local-mode):
* lisp/electric.el (electric-indent-local-mode)
(electric-layout-local-mode, electric-quote-local-mode):
* lisp/elec-pair.el (electric-pair-local-mode): Don't use it.

* lisp/emacs-lisp/bytecomp.el (byte-compile-warn-obsolete): Autoload.

* lisp/emacs-lisp/gv.el (buffer-local-variable): Make obsolete
(bug#26624).

* lisp/emacs-lisp/gv.el (make-obsolete-generalized-variable): Move
to allow usage.
2022-08-21 23:38:09 +02:00
Andrea Greselin
41169b5534 Add new user option electric-quote-replace-consecutive
* lisp/electric.el (electric-quote-replace-consecutive): New user
option (bug#57057).
(electric-quote-post-self-insert-function): Use it.
2022-08-09 20:44:07 +02:00
Lars Ingebrigtsen
5b767273d6 Fix a byte compilation warning in electric.el
* lisp/electric.el (electric-quote-mode): Quote a naked ‘ character.
2022-05-24 18:52:58 +02:00
Lars Ingebrigtsen
d036891967 Fix the final divergent single quote usages in doc strings
* lisp/view.el (view-mode-map):
* lisp/repeat.el (repeat-is-really-this-command):
* lisp/help.el (substitute-command-keys):
* lisp/electric.el (electric-quote-mode):
* lisp/cedet/srecode/texi.el (srecode-texi-texify-docstring):
* lisp/cedet/semantic/sort.el
(semantic-orphaned-member-metaparent-type): Audit usages of single
quotes in doc strings.
2022-05-24 18:48:50 +02:00
Stefan Kangas
5ac5d00479 Merge from origin/emacs-28
48201ce8de ; * lisp/electric.el (electric-indent-mode): Fix a typo.
2022-05-16 06:30:38 +02:00
Eli Zaretskii
48201ce8de ; * lisp/electric.el (electric-indent-mode): Fix a typo. 2022-05-15 09:21:36 +03:00
Stefan Kangas
b90909050d Merge from origin/emacs-28
8370caa835 ; * lisp/electric.el (electric-indent-mode): Clarify doc (...
2022-05-15 06:30:34 +02:00
Eli Zaretskii
8370caa835 ; * lisp/electric.el (electric-indent-mode): Clarify doc (bug#22564). 2022-05-14 17:48:22 +03:00
Eli Zaretskii
dcd76bd48d Merge from origin/emacs-28
836be7a112 ; * etc/refcards/ru-refcard.tex: Update Copyright year.
86cbc6ee4a * lisp/net/tramp-sh.el: Adapt copyright year
ebe8772f65 ; Minor fixes related to copyright years
23c1ee6989 ; * test/manual/etags/ETAGS.good_N: Adjust to copyright ye...
8d3fc7ec89 * src/xfaces.c (face_for_font): Make 'hash' be uintptr_t.
19dcb237b5 ; Add 2022 to copyright years.

# Conflicts:
#	etc/NEWS
#	etc/refcards/ru-refcard.tex
#	lib/cdefs.h
#	lisp/erc/erc-dcc.el
#	lisp/erc/erc-imenu.el
#	lisp/erc/erc-replace.el
#	lisp/image-dired.el
#	lisp/progmodes/xref.el
#	m4/alloca.m4
#	m4/byteswap.m4
#	m4/errno_h.m4
#	m4/getopt.m4
#	m4/gnulib-common.m4
#	m4/inttypes.m4
#	m4/stddef_h.m4
#	m4/stdint.m4
#	m4/sys_socket_h.m4
2022-01-01 07:03:03 -05:00
Eli Zaretskii
19dcb237b5 ; Add 2022 to copyright years. 2022-01-01 02:45:51 -05:00
Stefan Kangas
357d273d2e Remove redundant #' before lambda
* admin/unidata/unidata-gen.el (unidata-gen-table)
(unidata-gen-table-symbol, unidata-gen-table-integer)
(unidata-gen-table-numeric, unidata-gen-table-word-list)
(unidata-describe-decomposition):
* lisp/apropos.el (apropos-user-option):
* lisp/bookmark.el (bookmark-bmenu-search):
* lisp/composite.el (unicode-category-table):
* lisp/elec-pair.el (electric-pair--balance-info):
* lisp/electric.el (electric-quote-chars):
* lisp/emulation/cua-base.el (cua-rectangle-mark-key):
* lisp/epa-hook.el (epa-file-encrypt-to):
* lisp/faces.el (face-font-selection-order)
(face-font-family-alternatives, face-font-registry-alternatives)
(face-valid-attribute-values, tty-run-terminal-initialization):
* lisp/files.el (recover-file, file-expand-wildcards):
* lisp/frame.el (frames-on-display-list):
* lisp/help-at-pt.el (help-at-pt-display-when-idle):
* lisp/help-fns.el (help-fns--face-attributes):
* lisp/ido.el (ido-mode, ido-unc-hosts):
* lisp/isearch.el (isearch-highlight-regexp)
(isearch-highlight-lines-matching-regexp):
* lisp/language/indian.el (script-regexp-alist):
* lisp/language/lao.el:
* lisp/leim/quail/ipa.el (ipa-x-sampa-prepend-to-keymap-entry):
* lisp/mh-e/mh-folder.el (mh-process-commands):
* lisp/mh-e/mh-mime.el (mh-display-with-external-viewer):
* lisp/ps-mule.el (ps-mule-end-job):
* lisp/ps-print.el (ps-color-scale, ps-background-pages)
(ps-background-text, ps-background-image, ps-background)
(ps-begin-job, ps-print-translation-table):
* lisp/recentf.el (recentf-sort-ascending)
(recentf-sort-descending, recentf-sort-basenames-ascending)
(recentf-sort-basenames-descending)
(recentf-sort-directories-ascending)
(recentf-sort-directories-descending):
* lisp/replace.el (occur-engine-add-prefix):
* lisp/select.el (xselect--encode-string):
* lisp/server.el (server-use-tcp):
* lisp/ses.el (ses-sort-column):
* lisp/sort.el (sort-columns):
* lisp/term/ns-win.el (window-system-initialization):
* lisp/tree-widget.el (tree-widget-image-formats):
* lisp/whitespace.el (whitespace-report-region): Remove redundant #'
before lambda.
2021-10-21 23:35:07 +02:00
Stefan Monnier
246a41759c * lisp/electric.el: Do auto-indent inside strings and comments by default
This fixes bug#20846 where it transpired that there is no good reason
to shy away from auto-indenting inside comments and strings.

(electric-indent-post-self-insert-function): Don't check syntax-ppss.
2021-05-29 09:22:57 -04:00
Stefan Monnier
898a94a9be Use lexical-binding in the remaining preloaded files
* lisp/widget.el:
* lisp/w32-fns.el:
* lisp/textmodes/fill.el:
* lisp/term/common-win.el:
* lisp/scroll-bar.el:
* lisp/rfn-eshadow.el:
* lisp/menu-bar.el:
* lisp/language/tibetan.el:
* lisp/language/thai.el:
* lisp/language/misc-lang.el:
* lisp/language/lao.el:
* lisp/language/korean.el:
* lisp/language/japanese.el:
* lisp/language/indian.el:
* lisp/language/hebrew.el:
* lisp/language/european.el:
* lisp/language/ethiopic.el:
* lisp/language/english.el:
* lisp/language/cyrillic.el:
* lisp/language/chinese.el:
* lisp/jka-cmpr-hook.el:
* lisp/international/ucs-normalize.el:
* lisp/international/mule.el:
* lisp/international/mule-conf.el:
* lisp/international/iso-transl.el:
* lisp/international/fontset.el:
* lisp/international/characters.el:
* lisp/format.el:
* lisp/facemenu.el:
* lisp/electric.el:
* lisp/dos-w32.el:
* lisp/dos-fns.el:
* lisp/disp-table.el:
* lisp/cus-face.el:
* lisp/composite.el:
* lisp/bindings.el:
* admin/unidata/blocks.awk:
* admin/charsets/eucjp-ms.awk:
* admin/charsets/cp51932.awk: Use `lexical-binding`.
2021-01-04 20:57:42 -05:00
Paul Eggert
ba05d005e5 Update copyright year to 2021
Run "TZ=UTC0 admin/update-copyright".
2021-01-01 01:13:56 -08:00
Stefan Kangas
78eacf31e8 ; Fix many typos in symbols in docs and comments 2020-10-02 13:29:45 +02:00
Paul Eggert
365e01cc9f Update copyright year to 2020
Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
2020-01-01 00:59:52 +00:00
Paul Eggert
d1a791f8ed Spelling fixes 2019-12-09 18:45:18 -08:00
João Távora
5e88b50d54 Correctly reindent previous line in electric-indent-mode
Fixes: bug#35254

Do this even when electric-indent-inhibit is t, except when the
newline insertion is being performed by electric-layout-mode.

* lisp/electric.el (electric-indent-post-self-insert-function):
Reindent previous line unless operating under
electric-layout-mode.
(electric-layout-post-self-insert-function-1): Bind
electric-indent-inhibit to 'electric-layout-mode.

* test/lisp/electric-tests.el
(electric-layout-control-reindentation): New test.
2019-07-02 16:10:45 +01:00
Stefan Monnier
0b4e003766 Revert "* lisp/calc/calc-ext.el (math-scalarp): Fix typo"
This reverts commit 698ff554ac.
2019-06-26 10:24:59 -04:00
Stefan Monnier
698ff554ac * lisp/calc/calc-ext.el (math-scalarp): Fix typo 2019-06-26 10:03:48 -04:00
Stefan Monnier
fe0cb43fb8 * lisp/subr.el (add-hook): Turn append into depth (bug#35508)
Make it possible to control the relative ordering of functions on hooks by
specifying `depth` in the same was as was possible with `add-function`.

* lisp/electric.el (electric--sort-post-self-insertion-hook):
Delete function.
(electric-indent-mode, electric-layout-mode, electric-quote-mode):
* lisp/elec-pair.el (electric-pair-mode): Use new `depth` arg instead of
electric--sort-post-self-insertion-hook.

* lisp/emacs-lisp/syntax.el (syntax-propertize, syntax-ppss):
Use new `depth` arg to make sure noone accidentally gets added
after syntax-ppss-flush-cache.

* doc/lispref/modes.texi (Setting Hooks): Document new `depth` arg.

* test/lisp/subr-tests.el (subr-tests-add-hook-depth): New test.
2019-05-29 15:56:14 -04:00
Paul Eggert
f744797af1 Go back to "Maintainer: emacs-devel@gnu.org"
Restore lines saying "Maintainer: emacs-devel@gnu.org" when there is
no special maintainer for a file.  Although this wasn't documented
it was common practice and removing the lines didn't have consensus.
2019-05-25 14:25:18 -07:00
Paul Eggert
bef1be8730 Fixes for "Maintainer:" and related lines
Mostly, this just removes "Maintainer: emacs-devel@gnu.org" lines,
which are not that useful.  It also cleans up and regularizes a
few similar lines.
2019-05-19 21:34:27 -07:00
Basil L. Contovounesios
0e468a6204 Avoid using obsolete indent-relative-maybe
* lisp/electric.el (electric-indent-functions-without-reindent):
* lisp/indent.el (indent-according-to-mode): Check for
indent-relative-first-indent-point in addition to its obsolete alias
indent-relative-maybe.
* lisp/obsolete/vi.el (vi-com-map): Use
indent-relative-first-indent-point in place of its obsolete alias
indent-relative-maybe.
2019-04-03 17:55:40 +01:00
João Távora
682ab5d92a Adjust previous electric.el and elec-pair.el change
This fixes a serious bug introduced previously
electric-pair-inhibit-if-helps-balance and
electric-pair-skip-if-helps-balance, whereby "innocent" markers were
being pushed by those function's new save-change-and-restore
semantics.  The fix can probably still be improved.

It also adds comments to parts of the code, where deemed necessary.

* lisp/elec-pair.el (electric-pair--insert): Add comment.
(electric-pair--save-literal-point-excursion): New helper macro.
(electric-pair-inhibit-if-helps-balance)
(electric-pair-skip-if-helps-balance): Don't use
insert-before-markers since it may hurt other markers that have
nothing to do with the 'save-excursion'.
(electric-pair-post-self-insert-function): Use
electric-pair--save-literal-point-excursion.

* lisp/electric.el (electric-indent-post-self-insert-function):
Remove lexical variable.
2019-01-25 17:32:18 +00:00
João Távora
fd94312443 electric-layout-mode kicks in before electric-pair-mode
This aims to solve problems with indentation.  Previously in, say, a
js-mode buffer with electric-layout-rules set to

   (?\{ before after)
   (?\} before)

would produce an intended:

   function ()
   {
     <indented point>
   }

The initial state

  function () {

Would go immediately to the following by e-p-m

  function () {}

Only then would e-l-m be applied to } first, and then again to {.
This makes lines indent in the wrong order, which can be a problem in
some modes.

The way we fix this is by reversing the order of e-p-m and e-l-m in
the post-self-insert-hook (and also fixing a number of details that
this uncovered).  In the end this changes the sequence from

  function () {

By way of e-l-m becomes:

  function () <newline>
  {
  <newline>

The e-p-m inserts the pair

  function () <newline>
  {
  <newline>}

And then e-l-m kicks in for the pair again, yielding the desired result

  function () <newline>
  {
  <indented point>
  }

* lisp/elec-pair.el (electric-pair--insert): Bind
electric-layout-no-duplicate-newlines.
(electric-pair-inhibit-if-helps-balance)
(electric-pair-skip-if-helps-balance): Use insert-before-markers,
playing nice with save-excurion.
(electric-pair-post-self-insert-function): Go to correct position
before checking electric-pair-inhibit-predicate and
electric-pair-skip-self predicate.
(electric-pair-post-self-insert-function): Increase priority to
50.

* lisp/electric.el (electric-indent-post-self-insert-function):
Delete trailing space in reindented line only if line was
really reindented.  Rewrite comment.
(electric-layout-allow-duplicate-newlines): New variable.
(electric-layout-post-self-insert-function-1): Rewrite comments.
Honours electric-layout-allow-duplicate-newlines.  Don't reindent
previous line because racecar.

* test/lisp/electric-tests.el: New test.
(plainer-c-mode): Move up.
(electric-modes-int-main-allman-style)
(electric-layout-int-main-kernel-style): Simplify
electric-layout-rules.
(electric-layout-for-c-style-du-jour): New helper.
(electric-layout-plainer-c-mode-use-c-style): New test.
2019-01-22 16:42:43 +00:00
Stefan Monnier
6896604bab * lisp/electric.el: Fix typo in last change. 2019-01-21 14:30:29 -05:00
Stefan Monnier
d1ea675d2c (electric--sort-post-self-insertion-hook): Accept non-symbol functions
* lisp/electric.el (electric--sort-post-self-insertion-hook):
Don't burp on non-symbol functions.
2019-01-21 13:52:51 -05:00
João Távora
7717778e8b Revert "Remove leftover from previous electric-layout-rules API"
This is a backward-incompatible change, and removing it isn't really
necessary.

This reverts commit 942dad2b51.
2019-01-18 22:29:02 +00:00
Stefan Monnier
78725e49d2 (electric-layout-post-self-insert-function-1): Simplify.
Call electric--after-char-pos right from the start, and take advantage of the
fact that it guarantees to return the right position or nil.
2019-01-18 17:20:21 -05:00
João Távora
0621591687 Ensure fns in electric-layout-rules are called in right position
* lisp/electric.el (electric-layout-rules): Ensure rules are
called from right spot.
2019-01-18 22:05:50 +00:00
João Távora
942dad2b51 Remove leftover from previous electric-layout-rules API
An element of electric-layout-rules is either a function or a pair
(CHAR . WHERE), and WHERE can't be a function anymore.

* lisp/electric.el (electric-layout-post-self-insert-function-1):
Remove leftover line.
2019-01-18 22:05:50 +00:00
João Távora
949295ae1a Extend electric-layout-mode to handle more complex layouts (bug#33794)
Entries in electric-layout-rules can specify multiple
newline-related actions which are executed in order of appearance.

Also, have it play nice with electric-pair-mode when inserting a
newlines, particularly with electric-pair-open-newline-between-pairs.

Entries in electric-layout-rules can also be functions.  Among other
things, the logic behind electric-pair-open-newline-between-pairs
could now be moved to electric-layout-mode, but this commit doesn't do
that yet.

This change was motivated by bug#33794 and is an alternative solution
to the problem reported in that bug.

* lisp/electric.el (electric-layout-rules): Adjust docstring.
(electric-layout-post-self-insert-function): Call
electric-layout-post-self-insert-function-1.
(electric-layout-post-self-insert-function-1): Rename from
electric-layout-post-self-insert-function.  Redesign.
(electric-layout-local-mode): New minor mode.

* test/lisp/electric-tests.el (electric-layout-int-main-kernel-style)
(electric-layout-int-main-allman-style)
(electric-modes-in-c-mode-with-self-insert-command)
(electric-pair-mode-newline-between-parens)
(electric-layout-mode-newline-between-parens-without-e-p-m)
(electric-layout-mode-newline-between-parens-without-e-p-m-2): New
tests.
(plainer-c-mode): New helper.
2019-01-02 12:55:16 +00:00
Paul Eggert
ba809612c0 Merge from origin/emacs-26
2fcf2df Fix copyright years by hand
26bed8b Update copyright year to 2019
2814292 Fix value of default frame height.  (Bug#33921)
2018-12-31 17:57:29 -08:00
Paul Eggert
26bed8ba10 Update copyright year to 2019
Run 'TZ=UTC0 admin/update-copyright $(git ls-files)'.
2019-01-01 01:01:13 +00:00
Michael Heerdegen
1808d254a5 Replace insignificant backquotes
Replace most insignificant occurrences of '`' with a straight quote,
sharp quote or nothing.  This includes backquotes in 'pcase' patterns.

* admin/admin.el:
* lisp/apropos.el:
* lisp/arc-mode.el:
* lisp/auth-source.el:
* lisp/avoid.el:
* lisp/bindings.el:
* lisp/bs.el:
* lisp/calculator.el:
* lisp/calendar/todo-mode.el:
* lisp/cedet/semantic.el:
* lisp/cedet/semantic/analyze/debug.el:
* lisp/cedet/semantic/bovine.el:
* lisp/cedet/semantic/dep.el:
* lisp/cedet/semantic/grammar.el:
* lisp/cedet/semantic/wisent/comp.el:
* lisp/cedet/semantic/wisent/grammar.el:
* lisp/cedet/srecode/mode.el:
* lisp/cus-edit.el:
* lisp/doc-view.el:
* lisp/elec-pair.el:
* lisp/electric.el:
* lisp/emacs-lisp/autoload.el:
* lisp/emacs-lisp/benchmark.el:
* lisp/emacs-lisp/byte-opt.el:
* lisp/emacs-lisp/bytecomp.el:
* lisp/emacs-lisp/cconv.el:
* lisp/emacs-lisp/cl-extra.el:
* lisp/emacs-lisp/cl-generic.el:
* lisp/emacs-lisp/cl-macs.el:
* lisp/emacs-lisp/copyright.el:
* lisp/emacs-lisp/debug.el:
* lisp/emacs-lisp/eieio-compat.el:
* lisp/emacs-lisp/ert.el:
* lisp/emacs-lisp/generator.el:
* lisp/emacs-lisp/inline.el:
* lisp/emacs-lisp/macroexp.el:
* lisp/emacs-lisp/map.el:
* lisp/emacs-lisp/package-x.el:
* lisp/emacs-lisp/package.el:
* lisp/emacs-lisp/radix-tree.el:
* lisp/emacs-lisp/smie.el:
* lisp/epa.el:
* lisp/erc/erc-dcc.el:
* lisp/erc/erc-track.el:
* lisp/erc/erc.el:
* lisp/eshell/em-ls.el:
* lisp/eshell/esh-cmd.el:
* lisp/files.el:
* lisp/filesets.el:
* lisp/font-lock.el:
* lisp/frameset.el:
* lisp/gnus/gnus-agent.el:
* lisp/gnus/gnus-art.el:
* lisp/gnus/gnus-cite.el:
* lisp/gnus/gnus-group.el:
* lisp/gnus/gnus-msg.el:
* lisp/gnus/gnus-salt.el:
* lisp/gnus/gnus-srvr.el:
* lisp/gnus/gnus-sum.el:
* lisp/gnus/gnus-topic.el:
* lisp/gnus/gnus-util.el:
* lisp/gnus/gnus.el:
* lisp/gnus/message.el:
* lisp/gnus/mm-util.el:
* lisp/gnus/mml.el:
* lisp/gnus/nnheader.el:
* lisp/gnus/nnimap.el:
* lisp/gnus/nnmairix.el:
* lisp/gnus/spam.el:
* lisp/hexl.el:
* lisp/hi-lock.el:
* lisp/ibuf-ext.el:
* lisp/ibuffer.el:
* lisp/ido.el:
* lisp/info.el:
* lisp/international/mule-cmds.el:
* lisp/international/mule-util.el:
* lisp/json.el:
* lisp/jsonrpc.el:
* lisp/language/cyrillic.el:
* lisp/language/european.el:
* lisp/language/georgian.el:
* lisp/language/tibetan.el:
* lisp/language/utf-8-lang.el:
* lisp/language/vietnamese.el:
* lisp/ldefs-boot.el:
* lisp/mail/mail-extr.el:
* lisp/man.el:
* lisp/menu-bar.el:
* lisp/mh-e/mh-acros.el:
* lisp/mh-e/mh-folder.el:
* lisp/mh-e/mh-mime.el:
* lisp/mh-e/mh-show.el:
* lisp/mh-e/mh-speed.el:
* lisp/minibuffer.el:
* lisp/mpc.el:
* lisp/net/ange-ftp.el:
* lisp/net/hmac-def.el:
* lisp/net/newst-backend.el:
* lisp/net/quickurl.el:
* lisp/net/tramp-archive.el:
* lisp/net/tramp-compat.el:
* lisp/notifications.el:
* lisp/obsolete/pgg-parse.el:
* lisp/obsolete/vc-arch.el:
* lisp/obsolete/xesam.el:
* lisp/org/ob-C.el:
* lisp/org/ob-core.el:
* lisp/org/ob-exp.el:
* lisp/org/ob-groovy.el:
* lisp/org/ob-haskell.el:
* lisp/org/ob-io.el:
* lisp/org/ob-lisp.el:
* lisp/org/ob-lob.el:
* lisp/org/ob-lua.el:
* lisp/org/ob-octave.el:
* lisp/org/ob-perl.el:
* lisp/org/ob-python.el:
* lisp/org/ob-ref.el:
* lisp/org/ob-ruby.el:
* lisp/org/ob-sql.el:
* lisp/org/org-agenda.el:
* lisp/org/org-capture.el:
* lisp/org/org-clock.el:
* lisp/org/org-colview.el:
* lisp/org/org-duration.el:
* lisp/org/org-element.el:
* lisp/org/org-entities.el:
* lisp/org/org-gnus.el:
* lisp/org/org-indent.el:
* lisp/org/org-info.el:
* lisp/org/org-inlinetask.el:
* lisp/org/org-lint.el:
* lisp/org/org-list.el:
* lisp/org/org-mouse.el:
* lisp/org/org-plot.el:
* lisp/org/org-src.el:
* lisp/org/org-table.el:
* lisp/org/org.el:
* lisp/org/ox-ascii.el:
* lisp/org/ox-html.el:
* lisp/org/ox-latex.el:
* lisp/org/ox-man.el:
* lisp/org/ox-md.el:
* lisp/org/ox-org.el:
* lisp/org/ox-publish.el:
* lisp/org/ox-texinfo.el:
* lisp/org/ox.el:
* lisp/play/bubbles.el:
* lisp/play/gamegrid.el:
* lisp/progmodes/autoconf.el:
* lisp/progmodes/cc-defs.el:
* lisp/progmodes/cc-engine.el:
* lisp/progmodes/cc-fonts.el:
* lisp/progmodes/cc-langs.el:
* lisp/progmodes/cperl-mode.el:
* lisp/progmodes/ebrowse.el:
* lisp/progmodes/elisp-mode.el:
* lisp/progmodes/flymake-cc.el:
* lisp/progmodes/flymake.el:
* lisp/progmodes/fortran.el:
* lisp/progmodes/grep.el:
* lisp/progmodes/gud.el:
* lisp/progmodes/idlwave.el:
* lisp/progmodes/js.el:
* lisp/progmodes/m4-mode.el:
* lisp/progmodes/make-mode.el:
* lisp/progmodes/mixal-mode.el:
* lisp/progmodes/modula2.el:
* lisp/progmodes/octave.el:
* lisp/progmodes/opascal.el:
* lisp/progmodes/prolog.el:
* lisp/progmodes/ps-mode.el:
* lisp/progmodes/python.el:
* lisp/progmodes/ruby-mode.el:
* lisp/progmodes/sh-script.el:
* lisp/progmodes/sql.el:
* lisp/progmodes/verilog-mode.el:
* lisp/ps-mule.el:
* lisp/rtree.el:
* lisp/ruler-mode.el:
* lisp/ses.el:
* lisp/simple.el:
* lisp/startup.el:
* lisp/subr.el:
* lisp/term/ns-win.el:
* lisp/textmodes/bibtex.el:
* lisp/textmodes/conf-mode.el:
* lisp/textmodes/css-mode.el:
* lisp/textmodes/refill.el:
* lisp/textmodes/sgml-mode.el:
* lisp/textmodes/tex-mode.el:
* lisp/tutorial.el:
* lisp/url/url-dav.el:
* lisp/url/url-gw.el:
* lisp/url/url-http.el:
* lisp/url/url-methods.el:
* lisp/url/url-privacy.el:
* lisp/vc/cvs-status.el:
* lisp/vc/diff-mode.el:
* lisp/vc/ediff-init.el:
* lisp/vc/ediff-ptch.el:
* lisp/vc/log-edit.el:
* lisp/vc/log-view.el:
* lisp/vc/pcvs-info.el:
* lisp/vc/pcvs.el:
* lisp/vc/smerge-mode.el:
* lisp/vc/vc-git.el:
* lisp/vc/vc-hg.el:
* lisp/vc/vc-mtn.el:
* lisp/vc/vc-rcs.el:
* lisp/whitespace.el:
* lisp/window.el:
* test/lisp/electric-tests.el:
* test/lisp/emacs-lisp/cl-lib-tests.el:
* test/lisp/emacs-lisp/ert-tests.el:
* test/lisp/epg-tests.el:
* test/lisp/jsonrpc-tests.el:
* test/src/data-tests.el:
* test/src/json-tests.el: Replace most insignificant backquotes.
2018-11-25 21:08:08 +01:00
John Shahid
ee3e432300 Optionally add argument description in minor mode DOC (bug#10754)
Add a paragraph to minor mode's docstring documenting the mode's ARG
usage if the supplied docstring doesn't already contain the word "ARG".

* easy-mmode.el (easy-mmode--arg-docstring): New const.
(easy-mmode--arg-docstring): New function.
(define-minor-mode): Use them.

Remove argument documentation from all minor modes.
2018-07-01 23:34:53 -04:00
Noam Postavsky
c71fb6b0cd Suppress indent errors during electric indentation (Bug#18764)
* lisp/electric.el (electric-indent-post-self-insert-function):
Suppress errors from indent code, but don't suppress errors from
elsewhere in this function.  That way, if trouble is encountered with
electric indent "not working", the error should be reproducible by
calling indent directly (as is the case for Bug#18764), or else it's
from the electric indent code and will be reported normally.
2018-06-25 19:18:55 -04:00
Philipp Stephani
6735df4443 Ignore escape characters for context-sensitive quotes (Bug#29812)
* lisp/electric.el (electric-quote-post-self-insert-function): Skip
over escape characters when determining whether a context-sensitive
quote should be opening or closing.

* test/lisp/electric-tests.el
(electric-quote-replace-double-escaped-open)
(electric-quote-replace-double-escaped-close): New unit tests.
2018-01-07 13:52:59 +01:00
Philipp Stephani
f07c325d1f Fix a small bug in electric quoting.
Before this commit, if 'electric-quote-replace-double' is non-nil,
typing " '" turned into " ‘" even if
'electric-quote-context-sensitive' was nil.

* lisp/electric.el (electric-quote-post-self-insert-function): Insert
context-sensitive double quote only if the last character is actually
a double quote character.

* test/lisp/electric-tests.el
(electric-quote-replace-double-no-context-single): New unit test.
2018-01-07 13:50:03 +01:00
Paul Eggert
bb267f17f9 Merge from origin/emacs-26
63b04c11d5 Fix copyright years by hand
5c7dd8a783 Update copyright year to 2018
220a9ecba1 Merge from Gnulib
312c565566 Don't add empty keyboard macro to macro ring (Bug#24992)
39ca289a7a Allow customization of decoding of "man" command
f8240815ea * etc/NEWS: Add security consideration note on passphrase ...
0c78822c70 Fix subtle problem with scroll-down when scroll-margin is ...
acd289c5a4 Fix problems with indexing in User manual
b240c7846b * lisp/help.el (describe-key): Only (copy-sequence elt) wh...
e879a5444a * src/buffer.c (Frestore_buffer_modified_p): Fix bug#29846
81b1028b63 Improve documentation of 'inhibit-modification-hooks' and ...
7175496d7a Fix doc string of 'enable-recursive-minibuffers'
5b38406491 Fix documentation of delsel and of killing text

# Conflicts:
#	etc/NEWS
#	etc/refcards/ru-refcard.tex
2018-01-01 01:13:04 -08:00
Paul Eggert
5c7dd8a783 Update copyright year to 2018
Run admin/update-copyright.
2018-01-01 00:57:59 -08:00
Glenn Morris
33bfbfee7e Merge from origin/emacs-26
6e6bf60 Don't let delete_frame select a tooltip frame (Bug#27647)
e9dd580 Filter obtrusive events in help-read-key-sequence.
90075e8 Fix symlink flag in tramp-gvfs-handle-file-attributes
c355529 Fix bug in tramp-handle-file-truename
4c21d04 Fix a typo in doc string of electric-indent-functions-without...
319c2de Avoid assertion violations in echo_area_display
63c7733 ; * lisp/ido.el (ido-find-alternate-file): Doc fix.  (Bug#29278)
cbd319a Fix case-folding in Occur
29520b0 Fix quick-calc in C mode with hex values
3e80124 Improve documentation of dired-next/prev-marked-file
90add18 Prevent aborts in line-move-visual
648c128 More fixes in src/.gdbinit
104f3e5 Document how to enter whitespace when using grep-read-files
2017-11-20 13:08:35 -05:00
Eli Zaretskii
4c21d04057 Fix a typo in doc string of electric-indent-functions-without-reindent
* lisp/electric.el (electric-indent-functions-without-reindent):
Doc fix.  (Bug#29304)
2017-11-18 13:46:13 +02:00
Stefan Monnier
ee3024c70d * lisp/electric.el: Break recursive loading loop
(electric-pair-text-pairs): Declare instead of requiring elec-pair.
2017-10-01 17:15:22 -04:00
Eli Zaretskii
bb47c72de3 Avoid compilation warning in electric.el
* lisp/electric.el: Require 'elec-pair' when compiling, to avoid a
compiler warning.
2017-10-01 19:12:30 +03:00