Hi I'm working on my first beamer
presentation in view of my PhD defense,
I've plenty of time and started to experiment, I quite like the design and style of LaTex
presentation; however, I'm not yet confident and might opt in the end for a more conventional PPT — since there is not much math in this work anyway.
That said, I'm faced with the first issue in my title slide. Essentially, I want to have my name on the left (as first author) and both my supervisors on the right in the slide. I've tried so using both tabular
and tabularx
(according to this post, How to make this table fit nicely into one page of beamer?), but for the sake of me I cannot have my supervisors aligned to the right of the slide...
Basically, I would like the Supervisors, xxx and yyy to be centered but pushed all the way to the right, similarly to how my name is pushed all the way to the left. Also, it would be nice to have my name vertically centered in the table, I attempted to do so with column type m
but it didn't work. Below, a MWE to run the code:
Please, if you see something weird in the code or that could be optimized let me know! Thanks in advance.
P.S. There is also a warning when compiling related to
`pdfauthor' has already been used
is there a way to get rid of it? I need the \AtBeginDocument
for the authors table to exist before the document and this appears to conflict with something...
\documentclass[169]{beamer}
\usepackage[utf8]{inputenc}
\usetheme{Boadilla}
\usepackage{xcolor}
\usepackage{comment}
\usepackage{graphicx}
\usepackage{tikz,etoolbox}
\usepackage{tabularx,booktabs}
\newcolumntype{C}{>{\centering\arraybackslash}X}
\definecolor{bground}{HTML}{0074c0}
\definecolor{anti-flashwhite}{rgb}{0.95, 0.95, 0.96}
\makeatletter
\setbeamertemplate{background canvas}{%
\ifnum\c@framenumber=1%
{\begin{tikzpicture}
\useasboundingbox (0,0) rectangle (\paperwidth,\paperheight);
\fill [color=bground] (0,0.66\paperheight) rectangle (\paperwidth,\paperheight);
\end{tikzpicture}}
\else%
{\begin{tikzpicture}
\useasboundingbox (0,0) rectangle (\paperwidth,\paperheight);
\fill [color=bground] (0,0.86\paperheight) rectangle (\paperwidth,\paperheight);
\end{tikzpicture}}
\fi%
}
\makeatother
\makeatletter
\setbeamertemplate{headline}{%
\ifnum\c@framenumber=1%
{\hfill\includegraphics[width=1.25in,keepaspectratio]{example-image-a}\hspace{.05in}\vspace{-1.25in}}
\else%
{\hfill\includegraphics[width=.5in]{example-image-a}\hspace{.05in}\vspace{-.5in}}
\fi%
}
\makeatother
\makeatletter
\newcommand*{\rom}[1]{\expandafter\@slowromancap\romannumeral #1@}
\makeatother
\AtBeginDocument{%
\title[Ph.D. defense]{\hspace{.15in}FIRST LINE \\ SECOND LINE \\ \hspace{.1in}THIRD LINE}
\author[Surname, Givene Name]{
\begin{tabularx}{\textwidth}{@{} lC @{}}
\textbf{Given Name Surname} & \textbf{Supervisors} \\
& xxx \\
& yyy \\
\end{tabularx}}
\institute[]{\centering Ph.D. Program in \\ Evolutionary Biology and Ecology \\ \rom{36}\textdegree cycle}
\date[\today]{Academic Years 2020/2021 – 2022/2023}
\logo{\includegraphics[height=.5in]{example-image-b}}
}
\setbeamerfont{title}{shape=\bfseries,size=\LARGE}
\setbeamercolor{title}{fg=anti-flashwhite}
\setbeamercolor{frametitle}{fg=anti-flashwhite}
\addtobeamertemplate{frametitle}{\vskip-.08in}{}
%\setbeamerfont{author}{size=\Large}
\setbeamerfont{date}{size=\tiny}
\makeatletter
\setbeamertemplate{title page}[default][left,colsep=-4bp,rounded=true,shadow=\beamer@themerounded@shadow]
\makeatother
\AtBeginSection[]
{
\begin{frame}
\frametitle{Table of Contents}
\tableofcontents[currentsection]
\end{frame}
}
\begin{document}
\begin{frame}[t]
\vspace{-.35in}
\titlepage
\end{frame}
\end{document}