带边距的阴影环绕框

带边距的阴影环绕框

如何在 tcolorbox 中的左右和底部边距设置阴影环绕框,我尝试了 tcolorbox 中的很多选项,使用 borderline、leftrule 等,但对我不起作用,请帮助我们如何按照所附图片进行设置。(忽略所附图片底部突出显示的黑色部分。)在此处输入图片描述

抱歉,这是代码:

\documentclass{book}
\RequirePackage{amsmath,amssymb,lipsum,textcase,multicol}
\RequirePackage[breakable,hooks]{tcolorbox}

\tcbuselibrary{breakable,skins}

\makeatletter
\def\boxthreelabelfont{\noindent\fontsize{17bp}{14bp}\selectfont\bfseries\color{white}}
\def\boxthreetitlefont{\noindent\fontsize{11bp}{14bp}\selectfont\color{white}}
\def\boxthreetextfont{\noindent\fontsize{8.5bp}{11bp}\selectfont\parindent0pt\parskip9pt}
\newenvironment{Boxthree}[2][]{\begingroup\begin{tcolorbox}
[enhanced,breakable,%
arc=0pt,outer arc=0pt,boxrule=1pt,boxsep=0pt,top=22.7pt,left=14.5pt,right=15pt,bottom=5.5pt,middle=0pt,
bottomsep at break=0pt,topsep at break=2pt,
titlerule=0pt,titlerule style={gray,line width=0pt,},toptitle=9.9pt,bottomtitle=9.0pt,lefttitle=22pt,
righttitle=22pt,
title={{\boxthreelabelfont\MakeTextUppercase{#1}}\par\vskip4.5pt{\boxthreetitlefont\MakeTextUppercase{#2}}},
colbacktitle=black,colframe=gray,colback=white,rounded corners=southeast,
fontupper={\boxthreetextfont},
before skip=15pt,after skip=15pt,
toggle enlargement,
grow to left by=15pt,grow to right by=46pt, bottomrule at break=-8pt, toprule at break=-20pt,
arc=15pt,%leftrule=60pt,rightrule=60pt,
overlay={\draw[gray,line width=63pt]
      (frame.south west) -- (frame.north west);}
%borderline={60pt}{20pt}{15black},
%leftrule=60pt
%overlay first={
%\fill[black!15,sharp corners] ([xshift=0pt]65pt,20pt) rectangle ([xshift=-0mm]frame.north west);
%\fill[black!15] (-35mm,-2.5mm) rectangle (145mm,6mm);}
%overlay last={
%\fill[black!15,sharp corners] ([xshift=0pt]65pt,20pt) rectangle ([xshift=-0mm]frame.north west);
%\fill[black!15] (-35mm,-2.5mm) rectangle (145mm,6mm);}
]\null\ignorespaces\removelastskip\vspace{-16.8\p@}\begin{multicols}{2}}{\end{multicols}\end{tcolorbox}\endgroup}

\def\boxtwobreak{\end{multicols}\pagebreak\begin{multicols}{2}}


\begin{document}
 \begin{Boxthree}{Example 1.4}
What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession the legal profession.

What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession  the legal profession.

 What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession the legal profession.

What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession  the legal profession.

\boxtwobreak

 What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession the legal profession.

What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession  the legal profession.
 What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession the legal profession.

What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession  the legal profession.
\end{Boxthree}


\end{document} 

答案1

我不确定,但也许你想要一个drop midday shadow(v4.20 中的第 185 页)

\documentclass{book}
\RequirePackage{amsmath,amssymb,lipsum,textcase,multicol}
\RequirePackage[breakable,hooks]{tcolorbox}

\tcbuselibrary{breakable,skins}

\makeatletter
\def\boxthreelabelfont{\noindent\fontsize{17bp}{14bp}\selectfont\bfseries\color{white}}
\def\boxthreetitlefont{\noindent\fontsize{11bp}{14bp}\selectfont\color{white}}
\def\boxthreetextfont{\noindent\fontsize{8.5bp}{11bp}\selectfont\parindent0pt\parskip9pt}
\newenvironment{Boxthree}[2][]{%
\begingroup\begin{tcolorbox}[%
enhanced,breakable,%
%arc=0pt, outer arc=0pt, 
boxrule=1pt, boxsep=0pt, top=22.7pt, left=14.5pt, right=15pt, bottom=5.5pt, middle=0pt, bottomsep at break=0pt, topsep at break=2pt, titlerule=0pt, 
titlerule style={gray, line width=0pt,}, 
toptitle=9.9pt, bottomtitle=9.0pt, lefttitle=22pt, righttitle=22pt,title={{\boxthreelabelfont\MakeTextUppercase{#1}}%
        \par\vskip4.5pt{\boxthreetitlefont\MakeTextUppercase{#2}}},
colbacktitle=black, 
colframe=gray, 
colback=white, rounded corners=southeast,
fontupper={\boxthreetextfont}, before skip=15pt, after skip=15pt,
toggle enlargement, grow to left by=15pt, grow to right by=46pt, bottomrule at break=-8pt, toprule at break=-20pt, 
arc=15pt,
drop midday shadow,
%
%
%leftrule=60pt,rightrule=60pt,
%overlay={\draw[gray,line width=63pt]
%      (frame.south west) -- (frame.north west);}
%borderline={60pt}{20pt}{15black},
%leftrule=60pt
%overlay first={
%\fill[black!15,sharp corners] ([xshift=0pt]65pt,20pt) rectangle ([xshift=-0mm]frame.north west);
%\fill[black!15] (-35mm,-2.5mm) rectangle (145mm,6mm);}
%overlay last={
%\fill[black!15,sharp corners] ([xshift=0pt]65pt,20pt) rectangle ([xshift=-0mm]frame.north west);
%\fill[black!15] (-35mm,-2.5mm) rectangle (145mm,6mm);}
]\null\ignorespaces\removelastskip\vspace{-16.8\p@}\begin{multicols}{2}}{\end{multicols}\end{tcolorbox}\endgroup}
\makeatother

\def\boxtwobreak{\end{multicols}\pagebreak\begin{multicols}{2}}


\begin{document}
 \begin{Boxthree}{Example 1.4}
What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession the legal profession.

What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession  the legal profession.

 What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession the legal profession.

What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession  the legal profession.

\boxtwobreak

 What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession the legal profession.

What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession  the legal profession.
 What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession the legal profession.

What made you decide to be a lawyer? Perhaps someone in your family introduced you to the idea, or you were inspired by a lawyer you had read about in a book or seen on TV or in a movie. Perhaps you had the opportunity to speak to a practising lawyer at some point in your life, or you attended a legal trial. Perhaps you have arrived at law school knowing that you have wanted to be a lawyer your entire~life.
By enrolling in your law degree, you have taken the first step in your journey towards becoming a member of a long-standing and honourable profession  the legal profession.
\end{Boxthree}


\end{document} 

在此处输入图片描述

相关内容