Der Text "Hello there" soll nach oben verschoben werden. Mit makebox habe ich das nicht hinbekommen. \documentclass[11pt, a4paper,twoside]{scrartcl} \usepackage[theorems,skins,breakable]{tcolorbox} \usepackage{bclogo}% \begin{document} \newtcbox{\mybox}[1]{colback=red!5!white, colframe=red!75!black,fonttitle=\bfseries, title=#1} \mybox{\bclampe Hello there}{This is my own box.} \end{document} gefragt 23 Jul '20, 22:53 typ42 |
Warum nicht mit Hausmitteln arbeiten? Intiutiv muss \documentclass[11pt, a4paper,twoside]{scrartcl} \usepackage[theorems,skins,breakable]{tcolorbox} \usepackage{bclogo}% \begin{document} \section{Neu} \newtcbox{\mybox}[1]{colback=red!5!white, colframe=red!75!black,fonttitle=\bfseries, title={\hphantom{\bclampe}#1}, %lefttitle=2mm, % additional to "\hphantom{\bclampe}", default value = 4mm boxsep=0pt, % 1mm = default value of "boxsep" toptitle=0mm, % bottomtitle=5mm, % enhanced, title code={ \node[anchor=west] at (title.west) {\bclampe}; }, % } \mybox{Hello there}{This is my own box.} \section{Alt} \newtcbox{\myboxA}[1]{colback=red!5!white, colframe=red!75!black,fonttitle=\bfseries, title=#1} \myboxA{\bclampe Hello there}{This is my own box.} \end{document} beantwortet 24 Jul '20, 07:14 cis |
\raisebox{2mm}{Hello there}