ap / vim-css-color

Preview colours in source code while editing
http://www.vim.org/scripts/script.php?script_id=5056
MIT License
1.77k stars 78 forks source link

Add support for LaTeX? #177

Open AStcherbinine opened 1 year ago

AStcherbinine commented 1 year ago

Hello, Looks like the module does not support highlighting Latex files currently, would it be possible to add it? Especially for the \textcolor command from the xcolor package. E.g.,

\textcolor{red}{red text}
\textcolor[HTML]{FF0000}{other red text}

Thanks!

ap commented 1 year ago

Almost certainly possible. I’ll take a look.

This syntax does somewhat cut against the plugin’s grain in one obvious way: it doesn’t include the # in front of the RGB value (as most syntaxes do). But that alone just means it’ll take more work to support than usual.