James Vega wrote:
On Wed, Jul 28, 2010 at 9:55 AM, Charles Campbell
<[email protected]> wrote:
The new tex syntax file supports setting conceallevel to 2 with utf-8 by
showing appropriate glyphs for Greek in math, a few math symbols in math,
and a number of accented characters.
Why does the definition of the conceal syntax rely on&enc == 'utf-8'?
Removing those constraints and specifying the script is in utf-8
encoding (as in the attached patch) seems to work fine for me.
I'll put the
scriptencoding utf-8
into syntax/tex.vim, since the script is, in fact, written with utf-8.
However, the
if has("conceal") && &enc == "utf-8"
lines are still needed. With <enc.vimrc> as:
--------------------------------------------------
set nocp
syn on
set cole=3
--------------------------------------------------
and using
--------------------------------------------------
vi -u enc.vimrc -c ":e ++enc=latin abc.tex"
--------------------------------------------------
on the following tex file named <abc.tex>:
--------------------------------------------------
\documentclass[12pt]{article}
\pagestyle{empty}
\title{nothing}
\begin{document}
\begin{equation}
\delta^0\\
\alpha\alpha = x^{a0123456789zABabTUW} \\
\beta\delta^3\\
y= z^{1.5}\\
\phi= x_{\chi}\\
x_1 + x_2 \\
\end{equation}
\`{a} \`{e} \`{i} \`{o} \`{u} \`{y} \`{A} \`{E} \`{I} \`{O} \`{U} \`{Y}
\'{a} \'{e} \'{i} \'{o} \'{u} \'{y} \'{A} \'{E} \'{I} \'{O} \'{U} \'{Y}
\^{a} \^{e} \^{i} \^{o} \^{u} \^{y} \^{A} \^{E} \^{I} \^{O} \^{U} \^{Y}
\~{a} \~{e} \~{i} \~{o} \~{u} \~{y} \~{A} \~{E} \~{I} \~{O} \~{U} \~{Y}
\~{a} \~{e} \~{i} \~{o} \~{u} \~{y} \~{A} \~{E} \~{I} \~{O} \~{U} \~{Y}
\r{a} \r{A}
\v{a} \v{e} \v{i} \v{o} \v{u} \v{A} \v{E} \v{I} \v{O} \v{U}
\aa \AA \k{a} \k{A} \c{C} \~{n} \~{N} \o \O \H{o} \H{O} \c{r} \AE
\ae \oe \OE \ss
\end{document}
Check if $x$
% vim: cole=2
--------------------------------------------------
shows rather unpleasant behavior otherwise.
Regards,
Chip Campbell
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php