6

MS Powerpoint has this neat flowchart:

enter image description here

Because everything I ever needed so far could be done with TeX (just not by me), I really do hope that somehow this can be added in a beamer presentation as well and include that in the \frametitle section.

Preferably, the highlight should be movable (from 1st till last element) by some sort of setting. Optimally, the highlight colours would just be the colour scheme (in the example below from red - highlighted to the greyish colour).

enter image description here

MWE:

\documentclass{beamer}

\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
\usepackage{svg}
%\usepackage{gensymb}
%\usepackage{siunitx}

%\sisetup {
    %locale = DE,
    %per-mode = symbol
%}

% THEME AND COLOR SETUP
\usetheme{CambridgeUS}
\usecolortheme[RGB={205,0,0}]{structure}
\setbeamertemplate{items}[default]
\setbeamertemplate{sections/subsections in toc}[square]

\newcommand{\quoted}[1]{
    \glqq#1\grqq
}
\date{27. June 2018}

\mode<presentation>{}

\begin{document}
\beamertemplatenavigationsymbolsempty

\title{MS Powerpoint and TeX}
\author{Narusan}

\begin{frame}
    \frametitle{Flow Chart}
     %FLOWCHART ON TOP HERE
     \begin{columns}
     \begin{column}{.5\textwidth}
        What MS Powerpoint can do:
        \begin{itemize}[<+->]
            \item Reasonable Slideshows
            \item Fancy, but ultimately useless animations
            \item Infect your computer with the latest virus
            \item Crash when you were just about to save
        \end{itemize}
    \end{column}
    \begin{column}{.5\textwidth}
        What TeX can do
        \begin{itemize}[<+->]
            \item anything
        \end{itemize}
    \end{column}
\end{columns}

\end{frame}

\end{document}

Actual Output:

enter image description here

Desired Output (without the horrible stretching and without the colour scheme):

enter image description here

Narusan
  • 403
  • 2
    I like the idea, but have you already tried to draw the flow chart (independent of the rest)? You could use smartdiagram or do you want a plain TikZ solution? – TeXnician Jun 27 '18 at 20:36
  • 1
    maybe https://tex.stackexchange.com/questions/398326/custom-horizontal-navigation-bar-for-beamer/398341#398341 could help – samcarter_is_at_topanswers.xyz Jun 27 '18 at 20:41
  • 2
    A chain of the signal shapes suggested by @samcarter like here? –  Jun 27 '18 at 20:43
  • @marmot Yeah,just that. But I'm unsure as to how include it in the titlepage, and how to get the highlight for each section/ – Narusan Jun 27 '18 at 20:49
  • @TeXnician My Tikz skills - and TeX skills - are limited at best, I failed at simple line graphs. I'm learning step by step, but that would come in handy sooner than later. I'm fine with anything – Narusan Jun 27 '18 at 20:49

1 Answers1

5

This is not an answer since I do not fully understand the question (which is not your fault but because I never used powerpoint so I dunno what you are after). The TikZy part is easy because it has been done to a large extent by @Zarko here.

\documentclass{beamer}
\usetheme{CambridgeUS}
\usecolortheme[RGB={205,0,0}]{structure}
\setbeamertemplate{items}[default]
\setbeamertemplate{sections/subsections in toc}[square]
\beamertemplatenavigationsymbolsempty

\usepackage{tikz}
\usetikzlibrary{chains, positioning, shapes.symbols}
\tikzset{start/.style = {signal, fill=#1,minimum height=15mm,draw=white,
                 font=\sffamily\Huge,text=white,inner sep=6pt,
                 signal pointer angle=150, on chain},
  cont/.style = {start=#1, signal from=west}}

\tikzset{
    invisible/.style={opacity=0},
    visible on/.style={alt={#1{}{invisible}}},
    highlight on/.style={alt={#1{fill=darkred!80!black}{fill=gray!30!white}}},
    alt/.code args={<#1>#2#3}{%
      \alt<#1>{\pgfkeysalso{#2}}{\pgfkeysalso{#3}} % \pgfkeysalso doesn't change the path
    },
  }


\begin{document}
\section{Quack}

\begin{frame}[t,fragile]
\frametitle{\LaTeX\ wins!\\ 
\begin{tikzpicture}[
node distance = 0mm,
  start chain = going right,
                 ]
\node[start=darkred!80!black,highlight on=<1>] {This};
\node[cont=gray!30!white,highlight on=<2>] {and};
\node[cont=gray!30!white,highlight on=<3>] {then};
\node[cont=gray!30!white,highlight on=<4>] {that};
\end{tikzpicture}}
\begin{enumerate}
 \item Never put pineapple on a pizza!
 \pause
 \item Never!
 \pause
 \item Absolutely never!
 \pause
 \item Trust me!
\end{enumerate}
\end{frame}
\end{document}

enter image description here

EDIT: Added highlight on key and animation. Most likely one could do things more elegantly, though.

  • I've added a gif to explain what I mean with switching the highlight. Is it possible to get the tikz image into the header (LaTeX wins) – Narusan Jun 27 '18 at 21:23
  • 1
    @Narusan (Probably) yes but what determines its content? Do you just want to move the picture there or should be content be determined by the present and past sections. What determines which piece is getting highlighted? (Sorry, you are communicating with a marmot who never used ppt. ;-) –  Jun 27 '18 at 21:32
  • Indeed this is very helpful! – samcarter_is_at_topanswers.xyz Jun 27 '18 at 21:51
  • This is basically what I need. One minor nitpick: How to auto-stretch them fairly equally so that it goes from left margin to right margin? Or I guess I could just centre it// Also, why is the default font colour now that weird orange? Other than that, you've got it! – Narusan Jun 27 '18 at 22:19
  • Nvmd, that's the style. Oh am I stupid – Narusan Jun 27 '18 at 22:25
  • @Narusan You could add text width=2.5cm or something like that. (I am trying to do something cool with the beamer syntax like e.g. here, but so far I fail ... :-) In any case, you should probably accept samcarters answer, who really knows what (s)he's doing ;-) –  Jun 27 '18 at 22:27
  • That highlight on is great, just saves you some trouble – Narusan Jun 27 '18 at 23:23
  • I also should mention that the alt trick seems to go back to Claudio Fiandrino and is also part of the aobs package. I got it from this question, but this was probably just another case in which the user would have benefitted from disclosing the source of the code. I'm saying that because I do not want to make the impression I invented that nice thingy. –  Jun 28 '18 at 04:37