在 beamer slide 中为 tikzpicture 分配一个特定位置?

在 beamer slide 中为 tikzpicture 分配一个特定位置?

我想为演示文稿中同时包含文本和图形的幻灯片定义一种格式,以便每张幻灯片都有一些固定的图形和文本部分。幻灯片的两部分不必相等。

我有两个问题

  1. 是否可以为使用 tikz 包创建的图形预先分配投影仪幻灯片的一部分(垂直或水平)。
  2. 在图形部分中,图片的大小根据可用空间进行调整

答案1

Beamer 允许我们分配N列数并排。请参阅 Beamer 手册部分12.7 Splitting a Frame into Multiple Columns。摘自手册:

The beamer class offers several commands and
environments for splitting (perhaps only part of)
a frame into multiple columns.
***some text removed***
Columns are especially useful for placing a graphic
next to a description/explanation.

这是一个示例(根据下面的@Zarko 评论进行了修改)

\documentclass{beamer}

\begin{document}
\begin{frame}
\begin{columns}[t]
\begin{column}{0.5\textwidth} %width of the column
    \begin{figure}
        \centering
        \includegraphics[width=\textwidth]{example-image-a}
        \caption{Figure caption}
    \end{figure}
\end{column}
\begin{column}{0.5\textwidth}
    Some long series of text or images or anything really.
    Writing here restricts it to right half of this slide.
    Some long series of text or images or anything really.
\end{column}
\end{columns}
\end{frame}
\end{document}

在此处输入图片描述

相关内容