beamerouterthemeJuelich.sty 18.4 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273
% Latex-Beamer Template Research Centre Juelich
% version 17.12
% please report any problems to i.kabadshow@fz-juelich.de
% this version does support pdflatex, xelatex and lualatex
%

\setbeamersize{text margin left=0.5cm,text margin right=0.5cm}

% compute white border
\newlength{\myborder}
\setlength{\myborder}{\dimexpr(\paperwidth-0.1\paperheight)\relax}

% compute height of letter H in title
\newlength{\mylen}
\settoheight{\mylen}{\usebeamerfont{title}H} % according to the CD the headline is not aligned at the baseline, but the top left corner
\newlength{\myheadlinea}
\setlength{\myheadlinea}{\dimexpr(0.10\paperheight-\headheight-6pt+\mylen)\relax}
\newlength{\myheadlineb}
\setlength{\myheadlineb}{\dimexpr(0.55\paperheight-\headheight-6pt+\mylen)\relax} % alignmet at the left top corner of the headline

\newlength{\hlvstart}
\setlength{\hlvstart}{\dimexpr(1cm-15pt)\relax}

% alignment
\newcommand{\tlap}[1]{\vbox to 0pt{\vss\hbox{#1}}}
\newcommand{\blap}[1]{\vbox to 0pt{\hbox{#1}\vss}}

\mode<presentation>

%------------------------------------------------
% navigation symbols
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@navigation symbols@default\endcsname\relax
\defbeamertemplate{navigation symbols}{visible}
{%
  \hbox{%
  \insertslidenavigationsymbol%
  \insertframenavigationsymbol%
  \insertsubsectionnavigationsymbol%
  \insertsectionnavigationsymbol%
  \insertdocnavigationsymbol%
  \insertbackfindforwardnavigationsymbol}%
}

\defbeamertemplate*{navigation symbols}{invisible}{}

\defbeamertemplatealias{navigation symbols}{default}{invisible}

% handout and trans mode settings
\only<handout| trans>{
  % diable navigation symbols
  \setbeamertemplate{navigation symbols}{}
}

%------------------------------------------------
% Helmholtz Banner 
%------------------------------------------------
\defbeamertemplate*{helmholtz banner}{}{\translate{HelmholtzBanner}}

%------------------------------------------------
% frame number
%------------------------------------------------
\defbeamertemplate*{frame number}{visible}[1][\translate{SlideName}]
{%
  \usebeamercolor[fg]{footline}%
  #1~\insertframenumber%
}

\defbeamertemplate{frame number}{full}[1][\translate{SlideName}]
{%
  \usebeamercolor[fg]{footline}%
  #1~\insertframenumber\,\vrule width0.3pt\,\inserttotalframenumber%
}

\defbeamertemplate{frame number}{invisible}[1][]{}

\defbeamertemplatealias{frame number}{default}{visible}


%------------------------------------------------
% date in footer 
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@date@default\endcsname\relax
\defbeamertemplate*{date}{visible}
{%
  \usebeamercolor[fg]{footline}%
  \insertdate%
}

\defbeamertemplate{date}{invisible}{}

\defbeamertemplatealias{date}{default}{visible}

%------------------------------------------------
% headline
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@headline@default\endcsname\relax
\defbeamertemplate*{headline}{visible}[1][\usebeamertemplate*{navigation symbols}]
{%
  \begin{beamercolorbox}[wd=\paperwidth,ht=0ex,dp=0ex]{header}%
  \hfill\blap{#1}%
  \end{beamercolorbox}%
}
\defbeamertemplate{headline}{invible}{}

\defbeamertemplatealias{headline}{default}{visible}

%------------------------------------------------
% footer elements: empty settings
%------------------------------------------------
\defbeamertemplate{footer element1}{empty}{}
\defbeamertemplate{footer element2}{empty}{}
\defbeamertemplate{footer element3}{empty}{}
\defbeamertemplate{footer element4}{empty}{}

%------------------------------------------------
% footline
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@footline@default\endcsname\relax
\defbeamertemplate*{footline}{four elements}
{%
  \leavevmode%
  \ifbeamertemplateempty{footer element1}{
  }{%
    \usebeamertemplate*{footer element1}%
  }%
  \hfill%
  \ifbeamertemplateempty{footer element2}{}{%
    \usebeamertemplate*{footer element2}%
  }%
  \hfill%
  \ifbeamertemplateempty{footer element3}{}{%
    \usebeamertemplate*{footer element3}%
  }%
  \hfill%
  \ifbeamertemplateempty{footer element4}{}{%
    \usebeamertemplate*{footer element4}%
  }%
\par%
  \ifbeamertemplateempty{progressbar}{}{%
    \usebeamertemplate*{progressbar}
  }%
}%

\defbeamertemplatealias{footline}{four elements}{default}

%------------------------------------------------
% footer elements: logos 
%------------------------------------------------
\defbeamertemplate{footer element1}{logo}[1]
{%
  \begin{beamercolorbox}[sep=0.0cm,left,wd=.25\paperwidth,ht=1.25em,dp=0.0cm]{footline}
  \includegraphics[width=3.0cm]{#1}%
  \end{beamercolorbox}%
}

\defbeamertemplate{footer element2}{logo}[1]
{%
  \begin{beamercolorbox}[sep=0.0cm,center,wd=.25\paperwidth,ht=1.25em,dp=0.0cm]{footline}
  \includegraphics[width=3.0cm]{#1}%
  \end{beamercolorbox}%
}

\defbeamertemplate{footer element3}{logo}[1]
{%
  \begin{beamercolorbox}[sep=0.0cm,center,wd=.25\paperwidth,ht=1.25em,dp=0.0cm]{footline}
  \includegraphics[width=3.0cm]{#1}%
  \end{beamercolorbox}%
}

%------------------------------------------------
% footer elements: default settings
%------------------------------------------------
\defbeamertemplate*{footer element1}{default}[1][\usebeamertemplate{helmholtz banner}]
{%
  \tlap{%
  \vspace{\dimexpr(.5cm-3pt)}%
  \begin{beamercolorbox}[sep=0.0cm,wd=.25\paperwidth,ht=1.25em,dp=0.0cm]{footline}
     \hspace*{0.5cm}#1 % if no extra option is given, use \usebeamertemplate{helmholtz banner}
  \end{beamercolorbox}%
  }%
}

\defbeamertemplate*{footer element2}{default}[1][\usebeamertemplate{date}]
{%
  \tlap{%
  \vspace{\dimexpr(.5cm-3pt)}%
  \begin{beamercolorbox}[sep=0.0cm,center,wd=.25\paperwidth,ht=1.25em,dp=0.0cm]{footline}
  #1 % if no extra option is given, use \usebeamertemplate*{date}
  \end{beamercolorbox}%
  }%
}

\defbeamertemplate*{footer element3}{default}[1][\usebeamertemplate*{frame number}]
{%
  \tlap{%
  \vspace{\dimexpr(.5cm-3pt)}%
  \begin{beamercolorbox}[sep=0.0cm,center,wd=.25\paperwidth,ht=1.25em,dp=0.0cm]{footline}
   #1 % if no extra option is given, use \usebeamertemplate*{frame number}
  \end{beamercolorbox}%
  }%
}

\defbeamertemplate*{footer element4}{default}
{%
  \begin{beamercolorbox}[sep=0.0cm,right,wd=.25\paperwidth,ht=1.25em,dp=0.0cm]{footline}
  \includegraphics[scale=0.50]{fzj}%
  \end{beamercolorbox}%
}

%------------------------------------------------
% progressbar at the very bottom
%------------------------------------------------
\defbeamertemplate{progressbar}{visible}
{%
\tlap{\progressbar@progressbar}
}

\defbeamertemplate*{progressbar}{invisible}{}

\defbeamertemplatealias{footline}{default}{visible}

% handout and trans mode settings
\only<handout| trans>{%
  % disable progressbar
  \setbeamertemplate{progressbar}[invisible]
}

%------------------------------------------------
% background canvas
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@background canvas@default\endcsname\relax

% blue background canvas for titles slide, option 1
\defbeamertemplate{background canvas}{text}
{%
  \vbox{%
  \vskip0.05\paperheight%
    \hbox{\color{fzjblue}\vrule width \paperwidth height 0.74\paperheight}%
  }%
}

% blue background canvas for titles slide + image, option 2
\defbeamertemplate{background canvas}{image}
{%
\vbox{%
  \vskip0.05\paperheight%
    \hskip0.05\paperheight\tikz\node[draw=none,
      minimum width=\myborder,
      minimum height=0.45\paperheight,
      path picture={
        \node at (path picture bounding box.center){
         \inserttitlegraphic%
      };
      }]{};
     \hbox{\color{fzjblue}\vrule width\paperwidth height0.29\paperheight}%           
}%
}
\defbeamertemplate*{background canvas}{empty}{}

\pgfkeys{/beamerfzj/outer/.cd,
  background canvas/.initial=empty
}

%------------------------------------------------
% title page definitions 
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@title page@default\endcsname\relax

% title page image version
\defbeamertemplate*{title page}{image}
{%
  \vskip\myheadlineb%
274 275 276
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont*{title}\strut{}\inserttitle\par%
  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsubtitle\par\medskip%
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont*{date}\insertdate\enspace\vrule width0.3pt\enspace\insertauthor\enspace\vrule width0.3pt\enspace\insertinstitute%
277 278 279 280 281
}

% title page text version
\defbeamertemplate{title page}{text}
{%  
282 283 284 285
  \vskip\myheadlinea%
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{title}\strut{}\inserttitle\par\medskip%
  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsubtitle\par\bigskip\bigskip%
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont*{date}\insertdate\enspace\vrule width0.3pt\enspace\insertauthor\enspace\vrule width0.3pt\enspace\insertinstitute
286 287 288 289 290 291 292 293
}

\defbeamertemplate{title page}{empty}{}

\pgfkeys{/beamerfzj/outer/.cd,
  title page/.initial=image
}

294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321
%------------------------------------------------
% teaser page definitions
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@teaser page@default\endcsname\relax

% teaser page image version
\defbeamertemplate*{teaser page}{image}
{%
  \vskip\myheadlineb%
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont*{title}\strut{}\inserttitle\par%
  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsubtitle\par\medskip%
}

%  page text version
\defbeamertemplate{teaser page}{text}
{%
  \vskip\myheadlinea%
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{title}\strut{}\inserttitle\par\medskip%
  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsubtitle\par\bigskip\bigskip%
}

\defbeamertemplate{teaser page}{empty}{}

\pgfkeys{/beamerfzj/outer/.cd,
  teaser page/.initial=image
}


322 323 324 325 326 327 328 329 330
%------------------------------------------------
% lecture page definitions 
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@lecture page@default\endcsname\relax

% part page image version
\defbeamertemplate*{lecture page}{image}
{%
  \vskip\myheadlineb%
331 332 333
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{title}\strut{}\insertlecture\par%
%  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsubtitle\par\medskip%
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont*{date}\insertdate\enspace\vrule width0.3pt\enspace\insertauthor\enspace\vrule width0.3pt\enspace\insertinstitute%
334 335 336 337 338 339
}

% part page text version
\defbeamertemplate{lecture page}{text}
{%  
    \vskip\myheadlinea%
340 341 342
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{title}\strut{}\insertlecture\par\medskip%
%  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsubtitle\par\bigskip\bigskip%
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont*{date}\insertdate\enspace\vrule width0.3pt\enspace\insertauthor\enspace\vrule width0.3pt\enspace\insertinstitute
343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359
}

\defbeamertemplate{lecture page}{empty}{}

\pgfkeys{/beamerfzj/outer/.cd,
  lecture page/.initial=image
}

%------------------------------------------------
% part page definitions 
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@part page@default\endcsname\relax

% part page image version
\defbeamertemplate*{part page}{image}
{%
  \vskip\myheadlineb%
360 361 362
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{part}\strut{}\partname~\insertromanpartnumber:~\insertpart\par%
%  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsubtitle\par\medskip%
%  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{date}\insertdate\enspace\vrule width0.3pt\enspace\insertauthor\enspace\vrule width0.3pt\enspace\insertinstitute%
363 364 365 366 367
}

% part page text version
\defbeamertemplate{part page}{text}
{%  
368 369 370 371
  \vskip\myheadlinea%
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{part}\strut{}\partname~\insertromanpartnumber:~\insertpart\par\medskip%
%  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsubtitle\par\bigskip\bigskip%
%  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont*{date}\insertdate\enspace\vrule width0.3pt\enspace\insertauthor\enspace\vrule width0.3pt\enspace\insertinstitute
372 373 374 375 376 377 378 379 380 381 382 383 384
}

\defbeamertemplate{part page}{empty}{}

\pgfkeys{/beamerfzj/outer/.cd,
  part page/.initial=image
}

%------------------------------------------------
% section page definitions 
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@section page@default\endcsname\relax

385
% section page image version
386 387 388
\defbeamertemplate*{section page}{image}
{%
  \vskip\myheadlineb%
389 390 391
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{part}\strut{}\insertpart\par%
  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsection\par\medskip%
%  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{date}\insertdate\enspace\vrule width0.3pt\enspace\insertauthor\enspace\vrule width0.3pt\enspace\insertinstitute%
392 393
}

394
% section page text version
395 396
\defbeamertemplate{section page}{text}
{%  
397 398 399 400
  \vskip\myheadlinea%
  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont{part}\strut{}\insertpart\par\medskip%
  \hspace{0.5cm}\usebeamercolor[fg]{subtitle}\usebeamerfont{subtitle}\strut{}\insertsection\par\bigskip\bigskip%
%  \hspace{0.5cm}\usebeamercolor[fg]{title}\usebeamerfont*{date}\insertdate\enspace\vrule width0.3pt\enspace\insertauthor\enspace\vrule width0.3pt\enspace\insertinstitute
401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457
}

%------------------------------------------------
% section page definitions 
%------------------------------------------------
\defbeamertemplate{section page}{empty}{}

\pgfkeys{/beamerfzj/outer/.cd,
  section page/.initial=image,
}

%------------------------------------------------
% frametitle definitions 
%------------------------------------------------
\expandafter\let\csname beamer@@tmpop@frametitle@default\endcsname\relax

\defbeamertemplate*{frametitle}{default}{%
  \nointerlineskip%
  \vskip\hlvstart%
  \begin{beamercolorbox}[sep=0.0cm,wd=\paperwidth]{frametitle}
    \hspace*{0.5cm}%
    \usebeamerfont{frametitle}\usebeamercolor[fg]{frametitle}\insertframetitle\strut\par%
    {%
      \ifx\insertframesubtitle\@empty%
      \vskip-2pt% compensate distance to keep equal space between frametitle and text or framesubtitle and text
      \else%
      {%
        \hspace*{0.5cm}%
        \usebeamerfont{framesubtitle}\usebeamercolor[fg]{framesubtitle}\insertframesubtitle\strut\par}%
      \fi
    }%
	    %\hspace*{1cm}\insertframetitle%
	    %\insertframesubtitle
    \end{beamercolorbox}%
}

%------------------------------------------------
% title slide definition via maketitle
%------------------------------------------------
\def\maketitle{%
{%
  \ifbeamer@inframe%
    \titlepage%
    % resetting the background does not work for inframe, since empty title theme template cannot be set after \frame{...} here
  \else%
    \setbeamertemplate{frame number}[invisible]%
    \setbeamertemplate{date}[invisible]%
    \setbeamertemplate{background canvas}[\pgfkeysvalueof{/beamerfzj/outer/title page}]
    \setbeamertemplate{title page}[\pgfkeysvalueof{/beamerfzj/outer/title page}]
    \frame[t,noframenumbering]{\titlepage}%    
\fi%
}%
    % reset background to normal slides, does not change selected theme
    \setbeamertemplate{background canvas}[empty]
}

%------------------------------------------------
458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479
% teaser slide definition via maketeaser
%------------------------------------------------
\def\teaserpage{\usebeamertemplate*{teaser page}}
\def\maketeaser{%
{%
  \ifbeamer@inframe%
    \teaserpage%
    % resetting the background does not work for inframe, since empty title theme template cannot be set after \frame{...} here
  \else%
    \setbeamertemplate{frame number}[invisible]%
    \setbeamertemplate{date}[invisible]%
    \setbeamertemplate{background canvas}[\pgfkeysvalueof{/beamerfzj/outer/teaser page}]
    \setbeamertemplate{title page}[\pgfkeysvalueof{/beamerfzj/outer/teaser page}]
    \frame[t,noframenumbering]{\teaserpage}%
\fi%
}%
    % reset background to normal slides, does not change selected theme
    \setbeamertemplate{background canvas}[empty]
}

%------------------------------------------------
% lecture slide definition via makelecture
480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541
%------------------------------------------------
\def\lecturepage{\usebeamertemplate*{lecture page}}

\def\makelecture{%
{%
  \ifbeamer@inframe%
    \lecturepage%
    % resetting the background does not work for inframe, since empty title theme template cannot be set after \frame{...} here
  \else%
    \setbeamertemplate{frame number}[invisible]%
    \setbeamertemplate{date}[invisible]%
    \setbeamertemplate{background canvas}[\pgfkeysvalueof{/beamerfzj/outer/lecture page}]
    \setbeamertemplate{lecture page}[\pgfkeysvalueof{/beamerfzj/outer/lecture page}]
    \frame[t,noframenumbering]{\lecturepage}%    
\fi%
}%
    % reset background to normal slides, does not change selected theme
    \setbeamertemplate{background canvas}[empty]
}

%------------------------------------------------
% part slide definition via makepart
%------------------------------------------------
\def\makepart{%
{%
  \ifbeamer@inframe%
    \partpage%
    % resetting the background does not work for inframe, since empty title theme template cannot be set after \frame{...} here
  \else%
    \setbeamertemplate{frame number}[invisible]%
    \setbeamertemplate{date}[invisible]%
    \setbeamertemplate{background canvas}[\pgfkeysvalueof{/beamerfzj/outer/part page}]
    \setbeamertemplate{part page}[\pgfkeysvalueof{/beamerfzj/outer/part page}]
    \frame[t,noframenumbering]{\partpage}%    
\fi%
}%
    % reset background to normal slides, does not change selected theme
    \setbeamertemplate{background canvas}[empty]
}

%------------------------------------------------
% section slide definition via makepart
%------------------------------------------------
\def\makesection{%
{%
  \ifbeamer@inframe%
    \sectionpage%
    % resetting the background does not work for inframe, since empty title theme template cannot be set after \frame{...} here
  \else%
    \setbeamertemplate{frame number}[invisible]%
    \setbeamertemplate{date}[invisible]%
    \setbeamertemplate{background canvas}[\pgfkeysvalueof{/beamerfzj/outer/section page}]
    \setbeamertemplate{section page}[\pgfkeysvalueof{/beamerfzj/outer/section page}]
    \frame[noframenumbering]{\sectionpage}%    
\fi%
}%
    % reset background to normal slides, does not change selected theme
    \setbeamertemplate{background canvas}[empty]
}

\mode
<all>