使用 tikzposter 进行段落缩进

使用 tikzposter 进行段落缩进

我尝试创建一个tikzposter包含一些较长文本的文本框。我希望这些文本框有缩进的段落。我尝试设置\setlength{\parindent}{1em},但这并没有解决问题(它根本没有改变任何东西)。

所以我的问题是:我如何\parindent启用tikzposter

\documentclass[landscape,a0paper]{tikzposter}
\usepackage{scrextend}
\usepackage{multicol}
\usepackage{lipsum} % just for debugging purposes

\title{\bfseries Test title}
\institute{My institute}
\author{My colleagues and me}

\usetheme{Board} %board, envelope, wave, autumn
\usecolorstyle[colorPalette=BlueGrayOrange,colorOne=gray!70,colorTwo=darkgray!80,colorThree=gray!10]{Spain}%Russia
\usebackgroundstyle{Rays}
\usetitlestyle{Default}
\useblockstyle{Board}
\useinnerblockstyle{Default} % Table

\settitle{\centering\vbox{\centering
    \color{titlefgcolor}\vspace*{1em}\scalebox{1.3}{\bfseries\huge\scshape\@title}\par\vspace*{1em}
    {\LARGE\@author\par}\vspace*{1em}{\large\@institute}
}}
\changefontsizes{32pt}

\tikzposterlatexaffectionproofoff

\begin{document}
    \maketitle[width=.7\textwidth] % See Section 4.1
    \block{Block with wrong paragraph indentation}{
        \begin{multicols}{2}
            \innerblock{Test}{
                \lipsum[2]\par
                \lipsum[1]
            }
            \innerblock{Test}{
                \lipsum[2]\par
                \lipsum[1]
            }
        \end{multicols}
    }
\end{document}

答案1

TikZPoster定义和 其内容是默认情况下不缩进。但你可以在每个特定块中强制缩进,blocks添加TikZ-nodes\parbox\setlength{\parindent}{3em}在文本前添加。(参见如何在 TikZ 节点内缩进段落?,以及 Torbjørn T. 对此答案和问题的评论)

\documentclass[landscape,a0paper]{tikzposter}
\usepackage{scrextend}
\usepackage{multicol}
\usepackage{lipsum} % just for debugging purposes

\title{\bfseries Test title}
\institute{My institute}
\author{My colleagues and me}

\usetheme{Board} %board, envelope, wave, autumn
\usecolorstyle[colorPalette=BlueGrayOrange,colorOne=gray!70,colorTwo=darkgray!80,colorThree=gray!10]{Spain}%Russia
\usebackgroundstyle{Rays}
\usetitlestyle{Default}
\useblockstyle{Board}
\useinnerblockstyle{Default} % Table

\settitle{\centering\vbox{\centering
    \color{titlefgcolor}\vspace*{1em}\scalebox{1.3}{\bfseries\huge\scshape\@title}\par\vspace*{1em}
    {\LARGE\@author\par}\vspace*{1em}{\large\@institute}
}}
\changefontsizes{32pt}

\tikzposterlatexaffectionproofoff

\begin{document}
    \maketitle[width=.7\textwidth] % See Section 4.1
    \block{Block with wrong paragraph indentation}{
        \begin{multicols}{2}
            \innerblock{Test}{
                \setlength{\parindent}{3em} %<--- Indentation
                \lipsum[2]\par
                \lipsum[1]
            }
            \innerblock{Test}{
                \lipsum[2]\par
                \lipsum[1]
            }
        \end{multicols}
    }
\end{document}

在此处输入图片描述

相关内容