大括号左边的排版材料

大括号左边的排版材料
\documentclass{article}

\newcommand*{\LeftWidth}{3.0cm}%
\newcommand*{\RightWidth}{\dimexpr\linewidth-\LeftWidth-2em\relax}%
\newcommand{\AlignedBrace}[2]{%
    \medskip\par\noindent%
    \makebox[\LeftWidth][r]{\textbf{#1}~}%
    $\left\{~\parbox{\RightWidth}{\strut\textit{#2}\strut}\right.$%
}%

\begin{document}
\AlignedBrace{Gradation}{%
    Industria Virtutem parit: \\
    Virtus Laudem excibat: \\
    Laus adfert honorem: \\
    Honoris socia est, et comes AEmulatio
}
\AlignedBrace{Commutation}{%
    Quae de illo dicuntur; \textasciicircum{}dici non\textasciicircum{} \\
    dici non possunt: \\
    quae dici possunt: \\
    non dicuntur:
}
\AlignedBrace{Distribution}{%
    consilio ciuitatem inuare: \\
    Senatus officium est: \\
    Magistratus officium est: \\
    opera \& diligentia, consequi senatus Voluntatem
}
\AlignedBrace{Division}{%
    Si probus es: \\
    non meruisti: \\
    sin improbus: \\
    non commoVeris:
}
\AlignedBrace{Similitude}{%
    Vt hirundines estiuuo tempore, presto sunt \\
    frigore pulsae recedunt: \\
    Ita falsi amici amici: sereno Vitae tempore, presto sunt \\
    Simulatque hyemem fortunae dederint Auolant omnes
}
\AlignedBrace{Exposition}{%
    Qui est tam tenui cogitatione praeditus: \\
    cuius animus, tantis angustiis invidiae continentur: \\
    Qui non hunc hominem, studiosissime Laudet, \\
    et sapientissimum iudicet:
    Qui pro salute patriae, pro incolumitate ciuitatis \\
    pro Repub: fortunis, quamuis magnum atque \\
    atrox periculum, studiose subeat?
}
\end{document}

这个方法很有效,但是我还有一个问题:有时候,我在左边大括号之前输入的内容太长,超出了左边距,我该怎么办?

这是对齐文本中的括号(非数学)

答案1

在这种情况下,我建议\parbox{}在定义中使用\AlignedBrace

在此处输入图片描述

笔记:

  • 根据 Werner 的评论,我添加了一个,\strut\parbox确保没有降部的线条正确对齐。

代码:

\documentclass{article}

\newcommand*{\LeftWidth}{3.0cm}%
\newcommand*{\RightWidth}{\dimexpr\linewidth-\LeftWidth-2em\relax}%
\newcommand{\AlignedBrace}[2]{%
    \medskip\par\noindent%
    \parbox{\LeftWidth}{\raggedleft\textbf{#1}\strut~}%
    $\left\{~\parbox{\RightWidth}{\strut\textit{#2}\strut}\right.$%
}%

\begin{document}
\AlignedBrace{Some very long text on left}{%
    Industria Virtutem parit: \\
    Virtus Laudem excibat: \\
    Laus adfert honorem: \\
    Honoris socia est, et comes AEmulatio
}
\AlignedBrace{Commutation}{%
    Quae de illo dicuntur; \textasciicircum{}dici non\textasciicircum{} \\
    dici non possunt: \\
    quae dici possunt: \\
    non dicuntur:
}
\end{document}

相关内容