LaTeX Beamer 脚线导航符号/图标

LaTeX Beamer 脚线导航符号/图标

我正在修改LaTex Beamer主题,在修改页脚文件后,导航符号LaTex Beamer被弄乱了。我怎样才能在每张幻灯片中恢复它们。我尝试使用\setbeamertemplate{footline}{}\setbeamertemplate{navigation symbols}{\insertslidenavigationsymbol}“%\setbeamertemplate{navigation symbol}{\insertslidenavigationsymbol}”,但运气不佳 :( 它根本不起作用。

如果可以的话,请告诉我如何让这些漂亮的导航符号变暗一点。谢谢

在此处输入图片描述 带有导航符号的页脚

    \documentclass[xcolor=x11names,compress]{beamer}

    \usetheme{Darmstadt}
    \useoutertheme[subsection=false,footline=authortitle]{miniframes}

    \usefonttheme{serif}
    \usepackage{palatino}

    \setbeamerfont{title like}{shape=\scshape}
    \setbeamerfont{frametitle}{shape=\scshape}

    \setbeamercolor*{lower separation line head}{bg=DeepSkyBlue4} 
    \setbeamercolor*{normal text}{fg=black,bg=white} 
    \setbeamercolor*{alerted text}{fg=red} 
    \setbeamercolor*{example text}{fg=black} 
    \setbeamercolor*{structure}{fg=DeepSkyBlue4,bg=white} 

    \setbeamercolor*{palette tertiary}{fg=black,bg=black!10} 
    \setbeamercolor*{palette quaternary}{fg=black,bg=black!10} 

    \setbeamertemplate{navigation symbols}{}

    \title{Fundamentals of X and Y}
    \subtitle{Tutorial at Z 2009, Vienna, Austria}
    \author{Gsomething Ksomething}
    \institute{Department of Electrical Engineering \\ University of Something Comething}

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    %
    % footline mod. from beamerouterthemeinfolines.sty
    %
    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

    \setbeamercolor{author in head/foot}{fg=white,bg=}
    \setbeamercolor{title in head/foot}{fg=white,bg=}
    \setbeamercolor{date in head/foot}{fg=black,bg=}

    \makeatletter
    \setbeamertemplate{footline}
    {%
        \setbox\beamer@tempbox=\hbox{%
            \begin{beamercolorbox}[wd=.333333\paperwidth,ht=2.25ex,dp=1ex,center]{author in head/foot}%
                \usebeamerfont{author in head/foot}\insertshortauthor
            \end{beamercolorbox}%
            \begin{beamercolorbox}[wd=.333333\paperwidth,ht=2.25ex,dp=1ex,center]{title in head/foot}%
                \usebeamerfont{title in head/foot}\insertshorttitle
            \end{beamercolorbox}%
            \begin{beamercolorbox}[wd=.333333\paperwidth,ht=2.25ex,dp=1ex,right]{date in head/foot}%
                \usebeamerfont{date in head/foot}\insertshortdate{}\hspace*{2em}
                \insertframenumber{} / \inserttotalframenumber\hspace*{2ex} 
            \end{beamercolorbox}%
        }%
        \vskip0pt%
            \begin{pgfpicture}{0pt}{0pt}{\paperwidth}{0cm}%
                \usebeamercolor{frametitle right}%
                \pgfpathrectangle{\pgfpointorigin}{\pgfpoint{\paperwidth}{3.5ex}}%
                \pgfusepath{clip}%
                \pgftext[left,base]{\pgfuseshading{beamer@frametitleshade}}%
            \end{pgfpicture}%
        \beamer@tempdim=\ht\beamer@tempbox%
        \advance\beamer@tempdim by 0.95ex%
        \vskip-\beamer@tempdim%
        \box\beamer@tempbox%
        }  
    \makeatother

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    %
    % titlepage mod. from beamerinnerthemedefault.sty
    %
    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    \setbeamertemplate{title page}
    {
        \vbox{}
        \begingroup
        \includegraphics[height=1.5cm]{example-grid-100x100bp}
        \hfill
        \includegraphics[height=1.5cm]{example-grid-100x100bp}\par
            \vskip1em\par
        \centering
        \begin{beamercolorbox}[sep=8pt,center,colsep=-4bp,rounded=true,shadow=true]{title}
            \usebeamerfont{title}\inserttitle\par%
            \ifx\insertsubtitle\@empty%
            \else%
            \vskip0.25em%
            {\usebeamerfont{subtitle}\usebeamercolor[fg]{subtitle}\insertsubtitle\par}%
            \fi%     
        \end{beamercolorbox}%
        \vskip1em\par
        \begin{beamercolorbox}[sep=8pt,center,colsep=-4bp,rounded=true,shadow=true]{author}
            \usebeamerfont{author}\insertauthor
        \end{beamercolorbox}
        \begin{beamercolorbox}[sep=8pt,center,colsep=-4bp,rounded=true,shadow=true]{institute}
            \usebeamerfont{institute}\insertinstitute
        \end{beamercolorbox}
        \begin{beamercolorbox}[sep=8pt,center,colsep=-4bp,rounded=true,shadow=true]{date}
            \usebeamerfont{date}\insertdate
        \end{beamercolorbox}\vskip0.5em
        {\usebeamercolor[fg]{titlegraphic}\inserttitlegraphic\par}
        \hfill 
        \includegraphics[height=1.5cm]{example-grid-100x100bp}\par
        \endgroup
        \vfill
    }

    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
    %
    % framtitle mod. from beamerouterthemeshadow.sty
    %
    %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

    \colorlet{titleright}{yellow!10!white}
    \colorlet{titleleft}{DeepSkyBlue4}
    \colorlet{titlemid}{green!60!blue}

    \makeatletter

    \pgfdeclarehorizontalshading[titleleft,titleright]{beamer@frametitleshade}{\paperheight}{%
            color(0pt)=(titleleft);
            color(.5\paperwidth)=(titlemid);
            color(\paperwidth)=(titleright)
    }

    \AtBeginDocument{
        \pgfdeclareverticalshading{beamer@topshade}{\paperwidth}{%
            color(0pt)=(bg);
            color(4pt)=(black!50!bg)    
        }
    }

    \setbeamertemplate{frametitle}
    {%
        \nointerlineskip%
        \vskip-2pt%
        \hbox{\leavevmode
            \advance\beamer@leftmargin by -12bp%
            \advance\beamer@rightmargin by -12bp%
            \beamer@tempdim=\textwidth%
            \advance\beamer@tempdim by \beamer@leftmargin%
            \advance\beamer@tempdim by \beamer@rightmargin%
            \hskip-\Gm@lmargin\hbox{%
                \setbox\beamer@tempbox=\hbox{\begin{minipage}[b]{\paperwidth}%
                        \vbox{}\vskip-.75ex%
                        \leftskip0.3cm%
                        \rightskip0.3cm plus1fil\leavevmode
                        \insertframetitle \hfill \raisebox{-0.8mm}{\includegraphics[height=0.5cm]{example-grid-100x100bp}}%
                        \ifx\insertframesubtitle\@empty%
                        \strut\par%
                        \else
                        \par{\usebeamerfont*{framesubtitle}{\usebeamercolor[fg]{framesubtitle}\insertframesubtitle}\strut\par}%
                        \fi%
                        \nointerlineskip
                        \vbox{}%
                    \end{minipage}}%
                    \beamer@tempdim=\ht\beamer@tempbox%
                    \advance\beamer@tempdim by 2pt%
                    \begin{pgfpicture}{0pt}{0pt}{\paperwidth}{\beamer@tempdim}
                        \usebeamercolor{frametitle right}
                        \pgfpathrectangle{\pgfpointorigin}{\pgfpoint{\paperwidth}{\beamer@tempdim}}
                        \pgfusepath{clip}
                        \pgftext[left,base]{\pgfuseshading{beamer@frametitleshade}}
                    \end{pgfpicture}
                    \hskip-\paperwidth%
                    \box\beamer@tempbox%
                }%
                \hskip-\Gm@rmargin%
            }%
            \nointerlineskip
            \vskip-0.2pt
            \hbox to\textwidth{\hskip-\Gm@lmargin\pgfuseshading{beamer@topshade}\hskip-\Gm@rmargin}
            \vskip-2pt
    }

    \makeatother

    \begin{document}

    \begin{frame}[plain]
    \titlepage
    \end{frame}

    \section{test}
    \subsection{test}

    \begin{frame}{test}
        test
    \end{frame}

    \end{document}

答案1

要再次添加导航,您必须将其添加到自定义脚注定义中。

\makeatletter
\setbeamertemplate{footline}
{%
    \insertslidenavigationsymbol% <-- THE LINE I ADDED
    \setbox\beamer@tempbox=\hbox{%
        \begin{beamercolorbox}[wd=.333333\paperwidth,ht=2.25ex,dp=1ex,center]{author in head/foot}%
            \usebeamerfont{author in head/foot}\insertshortauthor
        \end{beamercolorbox}%
        \begin{beamercolorbox}[wd=.333333\paperwidth,ht=2.25ex,dp=1ex,center]{title in head/foot}%
            \usebeamerfont{title in head/foot}\insertshorttitle
        \end{beamercolorbox}%
        \begin{beamercolorbox}[wd=.333333\paperwidth,ht=2.25ex,dp=1ex,right]{date in head/foot}%
            \usebeamerfont{date in head/foot}\insertshortdate{}\hspace*{2em}
            \insertframenumber{} / \inserttotalframenumber\hspace*{2ex} 
        \end{beamercolorbox}%
    }%
    \vskip0pt%
        \begin{pgfpicture}{0pt}{0pt}{\paperwidth}{0cm}%
            \usebeamercolor{frametitle right}%
            \pgfpathrectangle{\pgfpointorigin}{\pgfpoint{\paperwidth}{3.5ex}}%
            \pgfusepath{clip}%
            \pgftext[left,base]{\pgfuseshading{beamer@frametitleshade}}%
        \end{pgfpicture}%
    \beamer@tempdim=\ht\beamer@tempbox%
    \advance\beamer@tempdim by 0.95ex%
    \vskip-\beamer@tempdim%
    \box\beamer@tempbox%
    }  
\makeatother

并将导航符号模板恢复为默认值。

\setbeamertemplate{navigation symbols}[default]

要更改导航符号的颜色,您必须设置相应的投影仪颜色:

\setbeamercolor{navigation symbols}{use=structure,fg=structure.fg!80!bg}
\setbeamercolor{navigation symbols dimmed}{use=structure,fg=structure.fg!60!bg}

在我的示例中,我稍微调整了默认混合比以获得更暗的输出。

相关内容