all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#24868: 26.0.50; LaTeX-verbatim-macros-with-delims-local isn't taken into account
@ 2016-11-03 16:11 Clément Pit--Claudel
  2016-11-03 18:05 ` Eli Zaretskii
  0 siblings, 1 reply; 7+ messages in thread
From: Clément Pit--Claudel @ 2016-11-03 16:11 UTC (permalink / raw)
  To: 24868


[-- Attachment #1.1.1: Type: text/plain, Size: 1322 bytes --]

Starting from emacs -Q with (add-to-list 'auto-mode-alist '("\\.tex$" . LaTeX-mode)), opening the attached file produces incorrect highlighting.  This is due to LaTeX-verbatim-macros-with-delims-local not being applied properly.

Currently, the workarounds are:
* To not set LaTeX-verbatim-macros-with-delims-local locally (instead, put it in .emacs)
* To add \usepackage{polyglossia} to top of file (??! apparently polyglossia.el somehow refreshes the fontification?)
* Use an "eval:" prop line to refresh fontification:
  % Local Variables:
  % LaTeX-verbatim-macros-with-delims-local: ("fiatverb" "facadeverb" "sqlverb" "cverb")
  % eval: (progn (font-latex-set-syntactic-keywords) (font-latex-setup) (setq font-lock-set-defaults nil) (font-lock-set-defaults))
  % End:

None of these are very pleasant, unfortunately.  Can we add a hook to hack-local-variables that refreshes fontification appropriately?

(also: can we give LaTeX-verbatim-macros-with-delims-local a simple #'safe predicate?)

Thanks!
Clément.

In GNU Emacs 26.0.50.14 (x86_64-pc-linux-gnu, GTK+ Version 3.18.9)
 of 2016-10-29 built on clem-w50-mint
Repository revision: fae796fe2695b419aa9277d243633bae400a147a
Windowing system distributor 'The X.Org Foundation', version 11.0.11804000
System Description:	Linux Mint 18 Sarah

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.1.2: test.tex --]
[-- Type: text/x-tex; name="test.tex", Size: 190 bytes --]

\documentclass{article}

\begin{document}
\python=This verb contains an unmatched $=
\end{document}

% Local Variables:
% LaTeX-verbatim-macros-with-delims-local: ("python")
% End:

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-11-03 19:27 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-11-03 16:11 bug#24868: 26.0.50; LaTeX-verbatim-macros-with-delims-local isn't taken into account Clément Pit--Claudel
2016-11-03 18:05 ` Eli Zaretskii
2016-11-03 18:35   ` Tassilo Horn
2016-11-03 19:06     ` Clément Pit--Claudel
2016-11-03 19:27       ` Tassilo Horn
2016-11-03 19:09     ` Eli Zaretskii
2016-11-03 19:26       ` Clément Pit--Claudel

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.