有没有办法可以在LaTeX中添加listings
的垂直标题作为TC1,如下所示:
我做的是:
\definecolor{dkgreen}{rgb}{0,0.6,0}
\definecolor{gray}{rgb}{0.5,0.5,0.5}
\definecolor{mauve}{rgb}{0.58,0,0.82}
\lstset{frame=tb,
language=Java,
aboveskip=3mm,
belowskip=3mm,
showstringspaces=false,
columns=flexible,
basicstyle={\fontsize{7}{8}\ttfamily},
numbers=left,
stepnumber=1,
numberstyle=\tiny\color{gray},
keywordstyle=\color{blue},
commentstyle=\color{dkgreen},
stringstyle=\color{mauve},
breaklines=true,
breakatwhitespace=true,
tabsize=3
}
\lstinputlisting[language=Java]{./TC1.java}
如何在列表中添加TC1?