我正在使用 listing 包来显示一些代码。但是,由于符号 ^^| 的存在而导致结果不如我所愿(见下图)。
我使用的设置如下
\lstset{
language={Mosel},
basicstyle=\mytextsizesmaller, % Global Code Style
captionpos=b, % Position of the Caption (t for top, b for bottom)
extendedchars=true, % Allows 256 instead of 128 ASCII characters
tabsize=2, % number of spaces indented when discovering a tab
columns=fixed, % make all characters equal width
keepspaces=true, % does not ignore spaces to fit width, convert tabs to spaces
showstringspaces=false, % lets spaces in strings appear as real spaces
breaklines=true, % wrap lines if they don't fit
frame=trbl, % draw a frame at the top, right, left and bottom of the listing
frameround=tttt, % make the frame round at all four corners
framesep=4pt, % quarter circle size of the round corners
numbers=left, % show line numbers at the left
numberstyle=\tiny\color{codegray}, % style of the line numbers
commentstyle=\color{airforceblue}, % style of comments
keywordstyle=\color{magenta}, % style of keywords
stringstyle=\color{orange(colorwheel)}, % style of strings
showtabs=false,
showspaces=false
}
我观察到 ^^| 符号与表格相对应。这就是我在设置中插入 showtabs=false、showspaces=false 的原因。但结果并不如预期。有什么建议可以消除这个问题吗?