[tex4ht] Error with listings for R programs
Michal Hoftich
michal.h21 at gmail.com
Wed Jun 15 21:59:57 CEST 2016
I replied directly to Steve, but this should really go to the list as
well.
> Dear Steve,
>
> > A minimal working example demonstrating the problem:
> > \documentclass[12pt]{article}
> > \usepackage{listings} %for computer code fragments
> >
> > \begin{document}
> >
> > Some text that precedes the listing for $S = 50$ in R notation.
> >
> > \begin{lstlisting}[language=R]
> > S <- 50
> > \end{lstlisting}
> >
> > \end{document}
> >
>
> It is caused by the following configuration in listings.4ht:
>
> \lst at AddToHook{TextStyle}{%
> \Configure{listings}{}{}{}{}%
> \a:lstinline \bgroup \aftergroup\b:lstinline\aftergroup\egroup
> }
>
> it should be rather
>
> \lst at AddToHook{TextStyle}{%
> \Configure{listings}{}{}{}{}%
> \a:lstinline \bgroup \aftergroup\b:lstinline\egroup
> }
>
> I think. At least it doesn't produce any error. What it produces is
> `<span class="lstinline"></span>`, which don't seem really useful. There
> is also no CSS configuration for this span. So I am not sure what is the
> purpose of this.
>
> Modified listings.4ht is attached.
>
> > Command and Envrionment:
> > htlatex minworkexample.tex "~/ht5mathjax,xhtml,mathml" " -cunihtf" "-cvalidate"
>
> you may try `make4ht`
>
> make4ht -uc ht5mathjax minworkexample.tex mathml
>
> would be the equivalent for your call.
>
> Best regards,
> Michal
More information about the tex4ht
mailing list