\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}}$.左移至背景色里面去,如何将箭头上移至中间位置。
\tcbset{colframe=blue!50!black,colback=white,
listing engine=listings,
fonttitle=\bfseries,nobeforeafter,center title}
\begin{tcblisting}{listing only,text width = 6cm,
listing options={language={[LaTeX]TeX}},height=1.3cm}
$S=\sqrt[n]{\frac{a+b}{a-b}}$.
\end{tcblisting}
\qquad $\Rightarrow$ \qquad
%
\tcbox[width=0.25\textwidth]{%
$S=\sqrt[n]{\frac{a+b}{a-b}}$.
}
\medskip
\tcbset{colframe=blue!50,colback=white,
fonttitle=\bfseries,nobeforeafter}
\cprotect\tcbox{\verb|$S=\sqrt[n]{\frac{a+b}{a-b}}$.|}
\qquad $\Rightarrow$ \qquad
%
\tcbox[width=0.25\textwidth]{%
$S=\sqrt[n]{\frac{a+b}{a-b}}$.
}
\medskip
\cprotect\tcbox{\lstinline|$S=\sqrt[n]{\frac{a+b}{a-b}}$.|}
\qquad \raisebox{2ex}{$\Rightarrow$} \qquad
%
\tcbox[width=0.25\textwidth]{%
$S=\sqrt[n]{\frac{a+b}{a-b}}$.
}
\medskip
\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}
\begin{tcblisting}{listing options={language={[LaTeX]TeX}},
height=1.3cm,
listing side text,text width=13 }
$S=\sqrt[n]{\frac{a+b}{a-b}}$.
\end{tcblisting}
tcolorbox_mwe.pdf
一周热门 更多>