2010-11-03 44 views
2

我在演示文稿中有一些框架,我想擺脫標準標題/標底,因爲我需要數字空間,其中包括使用\includegraphics。這些數字佔據了整個空間。現在我想在右下角插入幀號如何在簡單框架中添加框架編號

注意。我使用自定義標題/腳標的標準主題。一個工作的最小的例子可以在這裏找到: http://rapidshare.com/files/429008846/Beamer.zip

這是代碼:

\documentclass{beamer} 
\usepackage{german} 
\usepackage{graphicx} 
\usepackage{color} 
\usepackage{colortbl} 
\usepackage{pgf} 
%---------------------------------------------------------------------- 
%---------------------------------------------------------------------- 
%new color 
\definecolor{Gray}{gray}{0.9} 
\def\textboxcolor{Gray} 
%---------------------------------------------------------------------- 
%---------------------------------------------------------------------- 
\setbeamertemplate{headline}{% 
\hspace{0.01\textwidth}\begin{minipage}[t]{0.88\textwidth} 
\vspace{0.1cm} 
\begin{tabular}{p{0.5\textwidth}p{0.4\textwidth}p{0.1\textwidth}} 
Organisation - Institution&% 
&% 
\includegraphics[width=1cm]{pictures/logos/logo_ohne_text.jpg}\\ 
\hline\\ 
\end{tabular} 
\end{minipage}} 
%---------------------------------------------------------------------- 
\setbeamertemplate{footline}{% 
\hspace{0.01\textwidth}\begin{minipage}[t]{0.88\textwidth}% 
\begin{tabular}{p{0.3\textwidth}p{0.35\textwidth}p{0.2\textwidth}p{0.1\textwidth}}% 
\rowcolor[rgb]{0.8,0.8,0.8}\hline% 
\raggedright\begin{minipage}{0.3cm}\includegraphics[width=0.30cm]{pictures/logos/quadrat.jpg}\end{minipage}\ \insertauthor &% 
\centering \ \usebeamerfont{date in head/foot}\insertshortdate{}& &% 
Seite \insertframenumber{}/\inserttotalframenumber\\ 
\hline\\ 
\end{tabular} 
\end{minipage}} 
%---------------------------------------------------------------------- 
%---------------------------------------------------------------------- 
\begin{document} 
%---------------------------------------------------------------------- 
    \begin{frame}{Normal Frame} 
     \begin{block}{Blocktitle} 
     Text 
     \end{block} 
    \end{frame} 
%---------------------------------------------------------------------- 
    \begin{frame}[plain]{Frame with Images} 
     \begin{center} 
      \includegraphics[height=0.5\textheight]{pictures/cf.png} 
      \includegraphics[height=0.5\textheight]{pictures/cf.png}\\ 
      \includegraphics[height=0.5\textheight]{pictures/cf.png} 
      \includegraphics[height=0.5\textheight]{pictures/cf.png} 
     \end{center} 
     \begin{pgfpicture}{0}{0}{12.8cm}{9.6cm} 
      \pgfputat{\pgfxy(10.62,1.05)}{\pgfbox[left,base]{ % 
       \tiny{\insertframenumber{}/\inserttotalframenumber}}} 
     \end{pgfpicture} 
    \end{frame} 
%---------------------------------------------------------------------- 
\end{document} 
%---------------------------------------------------------------------- 
%---------------------------------------------------------------------- 
+0

這是標準幀 http://img5.imageshack.us/img5/2246/unbenanntzv.png – Roland 2010-11-04 10:54:21

+0

這是帶有圖像的普通幀,其中框架號應該被添加在右下角http://img178.imageshack.us/img178/6476/unbenannt2tu.png – Roland 2010-11-05 09:59:48

回答

2

在我原來的答覆,我要求一些照片,你貼。非常感謝;那些非常有幫助。


您的幻燈片看起來像是使用格拉茨主題[1]。我下載了這個解決方案。試試這個(更換我的\ {usetheme格拉茨}與任何你叫你的版本,也許你已經修改了一點):

\documentclass{beamer} 
\usepackage{pgf} % make sure you use this! 
\setbeamertemplate{navigation symbols}{} 
\usetheme{Graz} 

\pgfdeclareimage[height=0.5cm]{university-logo}{images/uni_logo} 
\logo{\pgfuseimage{university-logo}} 

\begin{document} 

\begin{frame}[plain]{Test slide} 
    \begin{pgfpicture}{0}{0}{12.8cm}{9.6cm} % see Note 1 

    \pgfputat{\pgfxy(10.62,1.05)}{\pgfbox[left,base]{ % see Note 2 
       \tiny{\insertframenumber{}/\inserttotalframenumber}}} 

    \pgfputat{\pgfxy(0.4,1.1)}{\pgfimage[width=0.95\textwidth]{figure}} % see Note 3 

    \end{pgfpicture} 
\end{frame} 

\end{document} 

注1:如果你不熟悉PGF [ 2,語法是:

\begin{pgfpicture}{start x}{start y}{end x}{end y} 

那麼你很可能逃脫只是一個PGF圖片{0} {0} {12.8} {1.05},這將填補整個寬度(0 - > 12.8釐米×寬度),並給你足夠的頁腳頁碼(0 - > 1.05釐米高)。

但是,如果您離開它,也可以使用pgf來放置圖像。隨你便。它不會影響任何東西以使其保持整個框架的大小。

注2:改變這些座標,然而你想。您可以在默認幻燈片和這個之間來回翻轉以調整這些座標,直到頁面#/ tot頁面在兩者之間沒有明顯的差異。

需要注意的是,如果你開始添加文本,你有什麼框架,有一個輕微的 pgfbox的位置可能會被打倒。如果是這樣的話,只需讓你的框架對數字很喜歡,然後重做\ pfgputat的座標以獲得它想要的位置。

注意3:我從上面的鏈接中截取了數字並使用了pgf將它放在我的框架中。您的標題左對齊,而我的默認居中位置,但總體上希望這看起來像你想要的(上面的LaTeX命令產生這個):IMAGE

就像我說的,只是調整各種座標,以獲得你想要的一切。


更新11/5:

正如我在註釋2的建議,將東西送到幀可能陷入困境的位置。我已經看過你的更新代碼,並使pgf很好地播放。它可能應該被認爲是「黑客」,因爲它正在做的是克服\ includegraphics命令引起的降級。從本質上講,看起來pgfbox不能駐留在使用此方法放置圖形的位置,因此您必須在幻燈片上「人工」地創建一個框以強制它出現......但這是有效的!我實際上調整了它,所以如果你進入全屏模式,在第一張幻燈片的「Seite 1/2」和第二張的「2/2」之間不應有任何變化。這裏是:

\begin{pgfpicture}{0}{0}{12.8cm}{9.6cm} 
    \pgfputat{\pgfxy(10.585,9.74)}{\pgfbox[left,base]{ % 
     \tiny{\insertframenumber{}/\inserttotalframenumber}}} 
\end{pgfpicture} 

讓我知道那是怎麼回事!


[1] www。 ist。圖拉茲。 at/staff/weiglhofer/misc/tugbeamer/

[2] PGF manual on ctan:www。 ctan。 org/tex-archive/graphics/pgf in base/doc

+0

我添加了一些鏈接到我的問題,我希望現在更清楚,我想要什麼。基本上,我想在右下角的幻燈片中添加幀號。 我在找的是一個帶框號的文本框,我可以放在右下角。 – Roland 2010-11-04 10:58:48

+0

現在下載這個主題(我很熟悉它),所以我可以使用相同的主題,並儘快爲您提供解決方案。 – Hendy 2010-11-04 18:03:27

+0

重新閱讀我的解決方案 - 我將其編輯爲我認爲對您有用的內容。 – Hendy 2010-11-04 18:20:56