
これは、大規模なプロジェクトで定義しようとしているセクション タイトルの MWE です。
\documentclass[a2,portrait]{a0poster}
\usepackage{tikz}
% Blue section, large, text on next line.
\def\Lsect#1{\noindent\hbox to \hsize{\large\color{blue} #1}\bigskip}
\begin{document}
\Lsect{This is a title}
Some text.
\end{document}
出力は次のようになります。
問題を再現するために、LaTeX ファイルから不要な行をすべて削除しました (tikz
ただし、なぜそこに必要なのかはわかりません)
タイトルを正しく左揃えにする必要がありますが、その方法がわかりません。定義に対して考えられるあらゆる変更を試しました。
答え1
hbox を特定のサイズに指定すると、TeX はコンテンツをそのサイズに合わせようとします。コンテンツを特定の方向に揃えたい場合は、次のいずれかのラバー長さを試してください。
\hfil
、\hfill
または\hfilll
\hss
\documentclass[a2,portrait]{a0poster}
\usepackage{tikz}
% Blue section, large, text on next line.
\def\Lsect#1{\noindent\hbox to \hsize{\large\color{blue} #1\hfil}\bigskip}
\begin{document}
\Lsect{This is a title}
Some text.
\end{document}