我正在尝试使用 Beamer,但我不知道如何才能仅隐藏导航文本,但保留上方相应的矩形。根据我上传的图,第一帧是我的实际情况,但我想做的事情在第二帧中呈现。第三帧可以。我只想隐藏第一帧(或标题页)中的导航文本(保留相应的矩形):
这是我的代码,使用主题“华沙”:
\documentclass[xcolor=dvipsnames,t]{beamer}
\definecolor{mikadoyellow}{rgb}{1.0, 0.77, 0.05}
\definecolor{yaleblue}{rgb}{0.06, 0.3, 0.57}
\usetheme{warsaw}
\usefonttheme{serif}
\setbeamerfont{section in head/foot}{family=\sffamily}
\setbeamerfont{subsection in head/foot}{family=\sffamily}
\setbeamerfont{author in head/foot}{family=\sffamily}
\setbeamerfont{title in head/foot}{family=\sffamily}
\setbeamercolor*{palette primary}{use=structure,fg=black,bg=mikadoyellow}
\setbeamercolor*{palette quaternary}{fg=white,bg=yaleblue}
\usepackage{multirow}
\usepackage{ragged2e}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{gensymb}
\usepackage{xcolor}
\usepackage{hyperref}
\justifying
\usefonttheme{professionalfonts}
\usepackage[none]{hyphenat}
\usepackage{cancel}
\usepackage{tikz}
\newcommand{\textunderscript}[1]{$_{\text{#1}}$}
\title[Title 2]{Title 1}
\author{Author}
\date{\today}
\begin{document}
\sloppy
\begin{frame}
\titlepage
\end{frame}
\section{Section 1}\frame{\frametitle{Section 1}}
\section{Section 2}\frame{\frametitle{Section 2}}
\section{Section 3}
\subsection{Subsection 1}\frame{\frametitle{Section 3-1}}
\subsection{Subsection 2}\frame{\frametitle{Section 3-2}}
\subsection{Subsection 3}\frame{\frametitle{Section 3-3}}
\section{Section 4}
\subsection{Subsection 1}\frame{\frametitle{Section 4-1}}
\subsection{Subsection 2}\frame{\frametitle{Section 4-2}}
\end{document}
提前致谢
答案1
基本思想就是将导航文本的颜色设置为与背景相同的颜色——瞧:千与千寻!
\documentclass[xcolor=dvipsnames,t]{beamer}
\definecolor{mikadoyellow}{rgb}{1.0, 0.77, 0.05}
\definecolor{yaleblue}{rgb}{0.06, 0.3, 0.57}
\usetheme{Warsaw}
\usefonttheme{serif}
\setbeamerfont{section in head/foot}{family=\sffamily}
\setbeamerfont{subsection in head/foot}{family=\sffamily}
\setbeamerfont{author in head/foot}{family=\sffamily}
\setbeamerfont{title in head/foot}{family=\sffamily}
\setbeamercolor*{palette primary}{use=structure,fg=black,bg=mikadoyellow}
\setbeamercolor*{palette quaternary}{fg=white,bg=yaleblue}
\usepackage{multirow}
\usepackage{ragged2e}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{gensymb}
\usepackage{hyperref}
\justifying
\usefonttheme{professionalfonts}
\usepackage[none]{hyphenat}
\usepackage{cancel}
\usepackage{tikz}
\newcommand{\textunderscript}[1]{$_{\text{#1}}$}
\title[Title 2]{Title 1}
\author{Author}
\date{\today}
\begin{document}
\sloppy
{
\addtobeamertemplate{headline}{%
\setbeamercolor{section in head/foot}{use=palette quaternary, fg=palette quaternary.bg}
}{}
\begin{frame}
\titlepage
\end{frame}
}
\section{Section 1}\frame{\frametitle{Section 1}}
\section{Section 2}\frame{\frametitle{Section 2}}
\section{Section 3}
\subsection{Subsection 1}\frame{\frametitle{Section 3-1}}
\subsection{Subsection 2}\frame{\frametitle{Section 3-2}}
\subsection{Subsection 3}\frame{\frametitle{Section 3-3}}
\section{Section 4}
\subsection{Subsection 1}\frame{\frametitle{Section 4-1}}
\subsection{Subsection 2}\frame{\frametitle{Section 4-2}}
\end{document}