tikz のグラフィカル垂直線

tikz のグラフィカル垂直線

左側に文字があり、段落全体の高さとまったく同じ高さになる特別なタイプの段落を持つデザイン (クラス) を作成したいと思います{。また、段落の長さ (高さ) に基づいて任意の tikz 画像を拡大縮小できるように拡張したいと思います。

ここに画像の説明を入力してください

答え1

使用法が環境形式ではなくコマンド形式である場合、これが上でコメントした内容です。

スケールレルは、幅がオプションの引数の値 (この場合は 1 インチ) に達するまで、"{" シンボルの完全なスケールを実行します。それより大きいスケールの場合、幅は 1 インチに制限され、そのポイントを超えると、スケールではなくストレッチになります。これにより、シンボルが広くなりすぎるのを防ぎます。

\documentclass{article}
\usepackage{scalerel}
\usepackage{lipsum}
\newcommand\specpar[1]{%
\begin{flushright}
  \scalerel[1in]{\{}{\parbox{4in}{#1}}%
\end{flushright}
}
\parindent 0in
\parskip 1em
\begin{document}

\lipsum[1]

\specpar{\lipsum[2]}

\lipsum[3]
\end{document}

ここに画像の説明を入力してください

答え2

xelatexPSTricks を使用。簡単にするために、でコンパイルします。

ここに画像の説明を入力してください

\documentclass{article}
\usepackage{pstricks-add}
\usepackage{bera}
\begin{document}
Karl's students do not care about dashing patterns. 
Karl's students do not care about arrow tips. 
Karl's students, by the way, do not know what a transformation matrix is.

\begin{center}
\begin{minipage}{0.8\linewidth}
\noindent\rnode{A}{\strut}

\vspace*{-1ex}
Karl's students do not care about dashing patterns. 
Karl's students do not care about arrow tips. 
Karl's students, by the way, do not know what a transformation matrix is.

\vspace*{-2ex}
\noindent\rnode{B}{}
\psbrace[braceWidthInner=3pt,braceWidth=1pt,braceWidthOuter=5pt,linecolor=red](A)(B){}
\end{minipage}
\end{center}

Karl's students do not care about dashing patterns. 
Karl's students do not care about arrow tips. 
Karl's students, by the way, do not know what a transformation matrix is.
\end{document}

関連情報