]> git.lyx.org Git - lyx.git/commit
Prune white space after the separating comma of options
authorEnrico Forestieri <forenr@lyx.org>
Sat, 17 Jun 2017 18:41:29 +0000 (20:41 +0200)
committerEnrico Forestieri <forenr@lyx.org>
Sat, 17 Jun 2017 18:41:29 +0000 (20:41 +0200)
commitd4d7cdf9a1d48150eec7dc0fd656488501dad4c0
tree6882079684d7551b72049aba6ebd5ecbde1ea897
parenta1e65ad4580d6ec4ed11de56a43f548e01bb90e5
Prune white space after the separating comma of options

Both listings and minted allow for many complex options. So, a latex
source can be easily written as

\documentclass{article}
\usepackage{minted}
\usepackage{graphicx}
\usepackage{dingbat}
\begin{document}
\begin{minted}[breaklines=true,
               breakautoindent=false,
               breaksymbolleft=\raisebox{0.8ex}{
                   \small\reflectbox{\carriagereturn}},
               breaksymbolindentleft=0pt,
               breaksymbolsepleft=0pt,
               breaksymbolright=\small\carriagereturn,
               breaksymbolindentright=0pt,
               breaksymbolsepright=0pt]{Python}
def f(x):
    return 'Some text' + str(x) + 'some more text' + str(x) + 'even more text that goes on for a while'
\end{minted}
\end{document}

The used text editor can therefore add a mixture of tabs and spaces.
The white space after the options is not a problem and the imported
file compiles just fine, but the validator gets confused and doesn't
validate them. This would entail a difficult editing of the options
only to have them validated. So, better remove the white space.
src/tex2lyx/text.cpp