答案1
从概念上讲,这与Ignasi 先前的回答,当然也有一些不同的键,也使用\newtcolorbox
。它还使用了来自这里得到一条漂亮的虚线。编辑:添加了Ignasi 建议的变更。
\documentclass{article}
\usepackage[most]{tcolorbox}
\newtcolorbox{mybox}[2][]{enhanced,title=#2,
fonttitle=\sffamily\bfseries,top=2pt,bottom=2pt,boxrule=0pt,arc=0pt,colframe=white,
coltitle=white,colback=white,
attach boxed title to top left={yshift=-1pt,xshift=-1pt},
borderline north={0.5mm}{0mm}{orange,dash pattern=on 0.1pt off 4pt,line
width=2pt,line cap=round},
borderline south={0.5mm}{0mm}{orange,dash pattern=on 0.1pt off 4pt,line
width=2pt,line cap=round},
boxed title style = {colback=orange, colframe=red, sharp corners, rounded
corners=northeast, arc=3mm, boxrule=0pt},
#1}
\begin{document}
\begin{mybox}{EXAMPLE 1}
\vspace{10em}
\end{mybox}
\end{document}