![反圆角](https://linux22.com/image/330232/%E5%8F%8D%E5%9C%86%E8%A7%92.png)
答案1
使用 是可能的overlay
,但此刻,我正在努力使用尺寸键,即确定框的高度和边框宽度。
警告,如果有标题或较粗的底部或顶部规则,则此方法将不起作用。
\documentclass{article}
\usepackage[most]{tcolorbox}
\makeatletter
\newtcolorbox{myinversearcbox}[1][]{%
enhanced jigsaw,
colback=red!5!white,
colframe=red!75!black,
sharp corners,
rightrule=0pt,
overlay={enhanced,
\path[draw=red!75!black,line width=\kvtcb@top@rule,fill=white] ([xshift=0cm,yshift=-\kvtcb@left@rule/2]frame.north east) arc (90:270:\tcb@height/2-\kvtcb@left@rule/2);
},
#1
}
\makeatother
\begin{document}
\begin{myinversearcbox}
This is a \textbf{tcolorbox}.
\end{myinversearcbox}
\end{document}