I want to mention a Perl variable name within a TeX file for PDF-ing (via pdflatex). Masking the dollar sign malfunctions with:
log-file:
! Missing $ inserted.
<inserted text>
$
l.7 \item \textit{\$fmt_line_req}
, d.i. eine den User-W\"unschen angepa\s...
I've inserted a begin-math/end-math symbol since I think
you left one out. Proceed, with fingers crossed.
The MWE:
\documentclass[a4paper,10pt]{article}
\usepackage[utf8]{inputenc}
\begin{document}
%\begin{enumerate}
% \item \textit{$fmt_line_req}, d.i. eine den User-W"unschen angepa\ss{}te Formatzeile
% \item \textit{$head_line_req}, d.i. die Spaltenk"opfe wunschgem"a\ss{}
% \item \textit{$content_req}, d.i. die Tabellenzeilen mit w.o. gew"unschter Spaltenpositionierung
%\end{enumerate}
\begin{enumerate}
\item \textit{[%spaltenformatierung%]}, d.i. eine den User-W"unschen angepa\ss{}te Formatzeile
\item \textit{[%spaltenueberschriften%]}, d.i. die Spaltenk"opfe wunschgem"a\ss{}
\item \textit{[%content%]}, d.i. die Tabellenzeilen mit w.o. gew"unschter Spaltenpositionierung
\end{enumerate}
\end{document}
The masking of % is ok! So, is there a solution to get the dollar sign in this environment?
The following output is only possible if dollar sign lines are commented. The \textit format is what I want. But I need itemize/enumerate lines with the dollar sign in same manner.
[%spaltenformatierung%], d.i. eine den User-Wunschen angepate Formatzeile
[%spaltenueberschriften%], d.i. die Spaltenkopfe wunschgema
[%content%], d.i. die Tabellenzeilen mit w.o. gewunschter Spaltenpositionierung
_is for math, escape them as well, aka\_– daleif Nov 22 '19 at 13:55\pathmacro to format$fmt_line_reqthen we do not need to escape – daleif Nov 22 '19 at 14:01