Merge from origin/emacs-26
5afbf62
Fix emacsclient check for term.el buffer (Bug#21041)5132a58
Improve documentation of 'set-fontset-font'cd90325
Improve documentation of M-?155a885
Reinterpret Esperanto characters in iso-transl as iso-8859-3.a0ef733
Fix Flyspell mode when several languages are mixed in a buffer
This commit is contained in:
commit
caa4d9c4e7
7 changed files with 83 additions and 40 deletions
|
@ -1987,9 +1987,14 @@ Restart one of the last 2 commands above, from the current location of point.
|
|||
|
||||
@kindex M-?
|
||||
@findex xref-find-references
|
||||
@kbd{M-?} finds all the references for the identifier at point. If
|
||||
there's no identifier at point, or when invoked with a prefix
|
||||
argument, the command prompts for the identifier, with completion. It
|
||||
@kbd{M-?} finds all the references for the identifier at point,
|
||||
prompting for the identifier as needed, with completion. Depending on
|
||||
the current backend (@pxref{Xref}), the command may prompt even if it
|
||||
finds a valid identifier at point. When invoked with a prefix
|
||||
argument, it always prompts for the identifier. (If you want it to
|
||||
prompt always, customize the value of the variable
|
||||
@code{xref-prompt-for-identifier} to @code{t}; or set it to @code{nil}
|
||||
to prompt only if there's no usable identifier at point.) The command
|
||||
then presents the @file{*xref*} buffer with all the references to the
|
||||
identifier, showing the file name and the line where the identifier is
|
||||
referenced. The XREF mode commands are available in this buffer, see
|
||||
|
|
|
@ -3498,11 +3498,15 @@ cons @code{(@var{from} . @var{to})}, where @var{from} and @var{to} are
|
|||
character codepoints. In that case, use @var{font-spec} for all the
|
||||
characters in the range @var{from} and @var{to} (inclusive).
|
||||
|
||||
@var{character} may be a charset. In that case, use
|
||||
@var{font-spec} for all character in the charsets.
|
||||
@var{character} may be a charset (@pxref{Character Sets}). In that
|
||||
case, use @var{font-spec} for all the characters in the charset.
|
||||
|
||||
@var{character} may be a script name. In that case, use
|
||||
@var{font-spec} for all character in the charsets.
|
||||
@var{character} may be a script name (@pxref{Character Properties}).
|
||||
In that case, use @var{font-spec} for all the characters belonging to
|
||||
the script.
|
||||
|
||||
@var{character} may be @code{nil}, which means to use @var{font-spec}
|
||||
for any character which no font-spec is specified.
|
||||
|
||||
@var{font-spec} may be a font-spec object created by the function
|
||||
@code{font-spec} (@pxref{Low-Level Font}).
|
||||
|
@ -3512,7 +3516,7 @@ where @var{family} is a family name of a font (possibly including a
|
|||
foundry name at the head), @var{registry} is a registry name of a font
|
||||
(possibly including an encoding name at the tail).
|
||||
|
||||
@var{font-spec} may be a font name string.
|
||||
@var{font-spec} may be a font name, a string.
|
||||
|
||||
@var{font-spec} may be @code{nil}, which explicitly specifies that
|
||||
there's no font for the specified @var{character}. This is useful,
|
||||
|
|
|
@ -1117,7 +1117,9 @@ find_tty (const char **tty_type, const char **tty_name, int noabort)
|
|||
}
|
||||
}
|
||||
|
||||
if (strcmp (type, "eterm") == 0)
|
||||
const char *inside_emacs = egetenv ("INSIDE_EMACS");
|
||||
if (inside_emacs && strstr (inside_emacs, ",term:")
|
||||
&& strprefix ("eterm", type))
|
||||
{
|
||||
if (noabort)
|
||||
return 0;
|
||||
|
|
|
@ -234,18 +234,18 @@ sequence VECTOR. (VECTOR is normally one character long.)")
|
|||
;; Language-specific translation lists.
|
||||
(defvar iso-transl-language-alist
|
||||
'(("Esperanto"
|
||||
("C" . [?Æ])
|
||||
("G" . [?Ø])
|
||||
("H" . [?¦])
|
||||
("J" . [?¬])
|
||||
("S" . [?Þ])
|
||||
("U" . [?Ý])
|
||||
("c" . [?æ])
|
||||
("g" . [?ø])
|
||||
("h" . [?¶])
|
||||
("j" . [?¼])
|
||||
("s" . [?þ])
|
||||
("u" . [?ý]))
|
||||
("C" . [?Ĉ])
|
||||
("G" . [?Ĝ])
|
||||
("H" . [?Ĥ])
|
||||
("J" . [?Ĵ])
|
||||
("S" . [?Ŝ])
|
||||
("U" . [?Ŭ])
|
||||
("c" . [?ĉ])
|
||||
("g" . [?ĝ])
|
||||
("h" . [?ĥ])
|
||||
("j" . [?ĵ])
|
||||
("s" . [?ŝ])
|
||||
("u" . [?ŭ]))
|
||||
("French"
|
||||
("C" . [?Ç])
|
||||
("c" . [?ç]))
|
||||
|
|
|
@ -869,7 +869,11 @@ buffer where the user can select from the list."
|
|||
;;;###autoload
|
||||
(defun xref-find-references (identifier)
|
||||
"Find references to the identifier at point.
|
||||
With prefix argument, prompt for the identifier."
|
||||
This command might prompt for the identifier as needed, perhaps
|
||||
offering the symbol at point as the default.
|
||||
With prefix argument, or if `xref-prompt-for-identifier' is t,
|
||||
always prompt for the identifier. If `xref-prompt-for-identifier'
|
||||
is nil, prompt only if there's no usable symbol at point."
|
||||
(interactive (list (xref--read-identifier "Find references of: ")))
|
||||
(xref--find-xrefs identifier 'references identifier nil))
|
||||
|
||||
|
|
|
@ -1424,10 +1424,20 @@ determined by `flyspell-large-region'."
|
|||
The list of incorrect words should be in `flyspell-external-ispell-buffer'.
|
||||
\(We finish by killing that buffer and setting the variable to nil.)
|
||||
The buffer to mark them in is `flyspell-large-region-buffer'."
|
||||
(let (words-not-found
|
||||
(ispell-otherchars (ispell-get-otherchars))
|
||||
(buffer-scan-pos flyspell-large-region-beg)
|
||||
case-fold-search)
|
||||
(let* (words-not-found
|
||||
(flyspell-casechars (flyspell-get-casechars))
|
||||
(ispell-otherchars (ispell-get-otherchars))
|
||||
(ispell-many-otherchars-p (ispell-get-many-otherchars-p))
|
||||
(word-chars (concat flyspell-casechars
|
||||
"+\\("
|
||||
(if (not (string= "" ispell-otherchars))
|
||||
(concat ispell-otherchars "?"))
|
||||
flyspell-casechars
|
||||
"+\\)"
|
||||
(if ispell-many-otherchars-p
|
||||
"*" "?")))
|
||||
(buffer-scan-pos flyspell-large-region-beg)
|
||||
case-fold-search)
|
||||
(with-current-buffer flyspell-external-ispell-buffer
|
||||
(goto-char (point-min))
|
||||
;; Loop over incorrect words, in the order they were reported,
|
||||
|
@ -1457,11 +1467,18 @@ The buffer to mark them in is `flyspell-large-region-buffer'."
|
|||
;; Move back into the match
|
||||
;; so flyspell-get-word will find it.
|
||||
(forward-char -1)
|
||||
(flyspell-get-word)))
|
||||
;; Is this a word that matches the
|
||||
;; current dictionary?
|
||||
(if (looking-at word-chars)
|
||||
(flyspell-get-word))))
|
||||
(found (car found-list))
|
||||
(found-length (length found))
|
||||
(misspell-length (length word)))
|
||||
(when (or
|
||||
;; Misspelled word is not from the
|
||||
;; language supported by the current
|
||||
;; dictionary.
|
||||
(null found)
|
||||
;; Size matches, we really found it.
|
||||
(= found-length misspell-length)
|
||||
;; Matches as part of a boundary-char separated
|
||||
|
@ -1483,13 +1500,21 @@ The buffer to mark them in is `flyspell-large-region-buffer'."
|
|||
;; backslash) and none of the previous
|
||||
;; conditions match.
|
||||
(and (not ispell-really-aspell)
|
||||
(not ispell-really-hunspell)
|
||||
(not ispell-really-enchant)
|
||||
(save-excursion
|
||||
(goto-char (- (nth 1 found-list) 1))
|
||||
(if (looking-at "[\\]" )
|
||||
t
|
||||
nil))))
|
||||
(setq keep nil)
|
||||
(flyspell-word nil t)
|
||||
;; Don't try spell-checking words whose
|
||||
;; characters don't match CASECHARS, because
|
||||
;; flyspell-word will then consider as
|
||||
;; misspelling the preceding word that matches
|
||||
;; CASECHARS.
|
||||
(or (null found)
|
||||
(flyspell-word nil t))
|
||||
;; Search for next misspelled word will begin from
|
||||
;; end of last validated match.
|
||||
(setq buffer-scan-pos (point))))
|
||||
|
|
|
@ -1442,23 +1442,26 @@ DEFUN ("set-fontset-font", Fset_fontset_font, Sset_fontset_font, 3, 5, 0,
|
|||
doc: /*
|
||||
Modify fontset NAME to use FONT-SPEC for TARGET characters.
|
||||
|
||||
NAME is a fontset name string, nil for the fontset of FRAME, or t for
|
||||
the default fontset.
|
||||
NAME is a fontset name (a string), nil for the fontset of FRAME,
|
||||
or t for the default fontset.
|
||||
|
||||
TARGET may be a single character to use FONT-SPEC for.
|
||||
|
||||
Target may be a cons (FROM . TO), where FROM and TO are characters.
|
||||
In that case, use FONT-SPEC for all characters in the range FROM
|
||||
and TO (inclusive).
|
||||
In that case, use FONT-SPEC for all the characters in the range
|
||||
between FROM and TO (inclusive).
|
||||
|
||||
TARGET may be a script name symbol. In that case, use FONT-SPEC for
|
||||
all characters that belong to the script.
|
||||
TARGET may be a script symbol. In that case, use FONT-SPEC for
|
||||
all the characters that belong to the script. See the variable
|
||||
`script-representative-chars' for the list of known scripts.
|
||||
|
||||
TARGET may be a charset. In that case, use FONT-SPEC for all
|
||||
characters in the charset.
|
||||
the characters in the charset. See `list-character-sets' and
|
||||
`list-charset-chars' for the list of character sets and their
|
||||
characters.
|
||||
|
||||
TARGET may be nil. In that case, use FONT-SPEC for any characters for
|
||||
that no FONT-SPEC is specified.
|
||||
TARGET may be nil. In that case, use FONT-SPEC for any character for
|
||||
which no font-spec is specified.
|
||||
|
||||
FONT-SPEC may one of these:
|
||||
* A font-spec object made by the function `font-spec' (which see).
|
||||
|
@ -1468,11 +1471,11 @@ FONT-SPEC may one of these:
|
|||
* A font name string.
|
||||
* nil, which explicitly specifies that there's no font for TARGET.
|
||||
|
||||
Optional 4th argument FRAME is a frame or nil for the selected frame
|
||||
that is concerned in the case that NAME is nil.
|
||||
Optional 4th argument FRAME is a frame, or nil for the selected frame,
|
||||
to be considered in the case that NAME is nil.
|
||||
|
||||
Optional 5th argument ADD, if non-nil, specifies how to add FONT-SPEC
|
||||
to the font specifications for TARGET previously set. If it is
|
||||
to the previously set font specifications for TARGET. If it is
|
||||
`prepend', FONT-SPEC is prepended. If it is `append', FONT-SPEC is
|
||||
appended. By default, FONT-SPEC overrides the previous settings. */)
|
||||
(Lisp_Object name, Lisp_Object target, Lisp_Object font_spec, Lisp_Object frame, Lisp_Object add)
|
||||
|
|
Loading…
Add table
Reference in a new issue