![Einrücken von Text in Beamer](https://rvso.com/image/286367/Einr%C3%BCcken%20von%20Text%20in%20Beamer.png)
Ich versuche, Text einzurücken, wie unten.
\\
Um die Ausrichtung richtig hinzubekommen (und sie ist im Moment noch lange nicht perfekt), habe ich es mit einem Zeilenumbruch und versucht \hspace{3.1cm}
. Gibt es eine legitime Möglichkeit, die Ergebnisse im obigen Bild zu erhalten?
Als minimales Arbeitsbeispiel habe ich
\documentclass[12pt,mathserif]{beamer}
\usetheme{Berkeley}
\usecolortheme{dove}
\useinnertheme{default}
\setbeamertemplate{navigation symbols}{}
\setbeamertemplate{itemize items}[default]
\setbeamertemplate{enumerate items}[default]
\beamertemplatenavigationsymbolsempty
\setbeamerfont{footline}{size=\fontsize{9}{11}\selectfont}
\setbeamertemplate{footline}[page number]
\begin{document}
\frame{\frametitle{Detecting MWEs in Typed Text}
\begin{itemize}
\item $\mathbf{Assumption \;1}$: MWEs have unique prosodic\\
\hspace{3.1cm}characteristics
\item $\mathbf{Assumption \;2}$: KD is the reflection of prosody in\\
\hspace{3.1cm}typing
\item $\mathbf{Conclusion}$: \hspace{0.5cm}MWEs should be uniquely\\
\hspace{3.1cm}characterized in typing
\end{itemize}
}
\end{document}
Antwort1
Eine solche Ausrichtung ist einfach, wenn Sie Folgendes verwenden tabular
:
\documentclass{beamer}% http://ctan.org/pkg/beamer
\begin{document}
\begin{frame}
\begin{tabular}{@{\textbullet~}l@{\ }p{2in}}
\bfseries Assumption 1: & MWEs have unique prosodic characteristics \\
\bfseries Assumption 2: & KD is the reflection of prosody in typing \\
\bfseries Conclusion: & MWEs should be uniquely characterized in typing
\end{tabular}
\end{frame}
\end{document}
Wenn Sie die richtige Spaltenbreite (derzeit fest auf 2in
) nicht messen möchten, können Sie eintabularx
stattdessen. Außerdem,array
\bfseries
könnte verwendet werden, um die erste Spalte bei Bedarf automatisch zu formatieren . Hier ist ein Beispiel, das beides enthältmiteine unregelmäßige zweite Spalte:
\documentclass{beamer}% http://ctan.org/pkg/beamer
\usepackage{array,tabularx}% http://ctan.org/pkg/{array,tabularx}
\begin{document}
\begin{frame}
\begin{tabularx}{\linewidth}{@{\textbullet~}>{\bfseries}l@{\ }>{\raggedright\arraybackslash}X@{}}
Assumption 1: & MWEs have unique prosodic characteristics \\
Assumption 2: & KD is the reflection of prosody in typing \\
Conclusion: & MWEs should be uniquely characterized in typing
\end{tabularx}
\end{frame}
\end{document}
Antwort2
Sie können die Methode verwenden, die inhttps://tex.stackexchange.com/a/163733/586, Wechsel zu einer description
Umgebung.
\documentclass[12pt,mathserif]{beamer}
\usetheme{Berkeley}
\usecolortheme{dove}
\useinnertheme{default}
\setbeamertemplate{navigation symbols}{}
\setbeamertemplate{itemize items}[default]
\setbeamertemplate{enumerate items}[default]
\beamertemplatenavigationsymbolsempty
\setbeamerfont{footline}{size=\fontsize{9}{11}\selectfont}
\setbeamertemplate{footline}[page number]
% new additions
\defbeamertemplate{description item}{align left}{$\blacktriangleright$ \bfseries\insertdescriptionitem\hfill}
\setbeamertemplate{description item}[align left]
\begin{document}
\frame{\frametitle{Detecting MWEs in Typed Text}
\begin{description}[Assumption 2:]
\item [Assumption 1:] MWEs have unique prosodic
characteristics
\item [Assumption 2:] KD is the reflection of prosody in
typing
\item [Conclusion:] MWEs should be uniquely
characterized in typing
\end{description}
}
\end{document}
Antwort3
Es könnte bessere Möglichkeiten geben, aber hier ist eine Möglichkeit mit einem Stapel. Ich habe verwendet, \bullet
weil ich den Namen des nach rechts zeigenden Dreiecksymbols nicht kannte. Außerdem musste ich aus irgendeinem Grund das Stapelzeilenendesymbol (EOL) vom Standard \\
in etwas anderes ändern, in diesem Fall \#
. Das Stacktabbedgap legt den Abstand zwischen den Spalten fest.
\documentclass{beamer}
\usepackage{tabstackengine}
\newcommand\pparbox[2]{\protect\parbox[t]{#1}{#2\strut}}
\setstacktabbedgap{1ex}
\setstackEOL{\#}
\begin{document}
\begin{frame}
\tabbedShortstack[l]{
\bfseries $\bullet$ Assumption 1: & \pparbox{2in}{%
MWEs have unique prosodic characteristics}\#
\bfseries $\bullet$ Assumption 2: & \pparbox{2in}{%
KD is the reflection of prosody in typing}\#
\bfseries $\bullet$ Conclusion: & \pparbox{2in}{%
MWEs should be uniquely characterized in typing}
}
\end{frame}
\end{document}
Wenn Sie diese Technik häufig verwenden möchten, könnte ein Großteil der Syntax in Makros umgesetzt werden:
\documentclass{beamer}
\usepackage{tabstackengine}
\newcommand\pparbox[2]{\protect\parbox[t]{#1}{#2\strut}}
\def\secondcolwidth{2in}%DEFAULT
\newcommand\firstcol[1]{\bfseries$\bullet$ #1:}
\newcommand\secondcol[1]{\pparbox{\secondcolwidth}{#1}}
\setstacktabbedgap{1ex}
\setstackEOL{\#}
\begin{document}
\begin{frame}
\def\secondcolwidth{2in}
\tabbedShortstack[l]{
\firstcol{Assumption 1} & \secondcol{MWEs have unique prosodic characteristics}\#
\firstcol{Assumption 2} & \secondcol{KD is the reflection of prosody in typing}\#
\firstcol{Conclusion} & \secondcol{MWEs should be uniquely characterized in typing}
}
\end{frame}
\end{document}