该framerule
选项应设置铸造环境的框架分隔符的厚度。
考虑一下这个MWE:
\documentclass[corpo=11pt,twoside,tipotesi=magistrale,greek]{toptesi}
\usepackage{geometry}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{listings}
\usepackage[newfloat]{minted}
\usemintedstyle{bw}
\setminted{
linenos,
breaklines,
breakanywhere,
frame=lines,
framesep=4mm,
framerule=1pt
}
\AtBeginEnvironment{minted}{%
\renewcommand{\fcolorbox}[4][]{#4}}
\newenvironment{code}{}{}
\usepackage{float}
\usepackage{adjustbox}
\begin{document}
\begin{code}
\begin{minted}{python}
class ExceptionHandler:
...
\end{minted}
\end{code}
\end{document}
可以清楚地看到线条粗细超过 1pt
答案1
该规则的厚度恰好为 1pt。我在这里展示如何测试它。
\documentclass[corpo=11pt,twoside,tipotesi=magistrale,greek]{toptesi}
\usepackage[T1]{fontenc}
\usepackage{geometry}
\usepackage{caption}
\usepackage{subcaption}
\usepackage{listings}
\usepackage[newfloat]{minted}
\usemintedstyle{bw}
\setminted{
linenos,
breaklines,
breakanywhere,
frame=lines,
framesep=4mm,
framerule=1pt
}
\AtBeginEnvironment{minted}{\renewcommand{\fcolorbox}[4][]{#4}}
\newenvironment{code}{}{}
\usepackage{float}
\usepackage{adjustbox}
\begin{document}
\hrule height 1pt
\begin{code}
\begin{minted}{python}
class ExceptionHandler:
...
\end{minted}
\end{code}
% now let's test it for 0.4pt
\hrule height 0.4pt
\setminted{framerule=0.4pt}
\begin{code}
\begin{minted}{python}
class ExceptionHandler:
...
\end{minted}
\end{code}
\end{document}