tcolorbox,请问如何将左移至背景色里面去,如何将箭头上移至中间位置。

2019-09-10 16:00发布

\documentclass{article}\usepackage{amsmath,amsthm,amssymb}\usepackage{xcolor}\usepackage{colortbl}\u...

\documentclass{article}


\usepackage{amsmath,amsthm,amssymb}

\usepackage{xcolor}

\usepackage{colortbl}

\usepackage{listings}

\usepackage{tcolorbox}

\tcbuselibrary{most}

\usepackage{varwidth}


\begin{document}

\begin{tcolorbox}[sharp corners, text width = 8cm, boxrule=0pt, nobeforeafter, arc=0mm]  

\begin{lstlisting}[language={[LaTeX]TeX}]

$S=\sqrt[n]{\frac{a+b}{a-b}}$.

\end{lstlisting}

\end{tcolorbox}

\qquad $\Rightarrow$ \qquad

\tcbox[sharp corners, colframe=black, colback=white, width=(\linewidth-4pt)/3, boxrule=0.5pt, nobeforeafter, arc=0mm]

{$S=\sqrt[n]{\frac{a+b}{a-b}}$.}

\end{document}



请问如何将$S=\sqrt[n]{\frac{a+b}{a-b}}$.左移至背景色里面去,如何将箭头上移至中间位置。

4条回答
TvZ8lPRVOT8C
2019-09-10 16:27
\documentclass{article}
\usepackage{tcolorbox}
\tcbuselibrary{listings}

\begin{document}
\begin{tcblisting}{sharp corners, text width = 6.5cm, boxrule=0pt, nobeforeafter, arc=0mm,listing only,listing options={language={[LaTeX]TeX}},height=1.3cm}
$S=\sqrt[n]{\frac{a+b}{a-b}}$.
\end{tcblisting}
\qquad \raisebox{0.5cm}{$\Rightarrow$} \qquad
\tcbox[sharp corners, colframe=black, colback=white, width=(\linewidth-4pt)/3, boxrule=0.5pt, nobeforeafter, arc=0mm,height=1.3cm]
{$S=\sqrt[n]{\frac{a+b}{a-b}}$.}
\end{document}

非要玩黑科技也是可行的

QQ截图20190910162655.png

一周热门 更多>

相关问答