Commit 1443a834 authored by Alija Sabic's avatar Alija Sabic
Browse files

Place sidebar elements reliably with TikZ, Makefile: change to process...

Place sidebar elements reliably with TikZ, Makefile: change to process multiple files (), add target open
parent 6871a5da
...@@ -15,7 +15,8 @@ LOG = @echo "$(call print_banner,$(ac),Error Log:$(sc)$1$(rst))\e[1A" ...@@ -15,7 +15,8 @@ LOG = @echo "$(call print_banner,$(ac),Error Log:$(sc)$1$(rst))\e[1A"
grep --color -E -e '' -e '$(ERRS)' && echo "$(ac)$(header)\n$(header)$(rst)\n" grep --color -E -e '' -e '$(ERRS)' && echo "$(ac)$(header)\n$(header)$(rst)\n"
INSTRUCTIONS = "$(call print_banner,$(pr),$(sc)Help Instructions $(rst))\n" \ INSTRUCTIONS = "$(call print_banner,$(pr),$(sc)Help Instructions $(rst))\n" \
"Provided targets:\n\n build, view, preview, log, clean, distclean, help\n\n" \ "Provided targets:\n\n build, view, preview, clean, distclean, log, open, help\n" \
"\n" \
"Three environment variables are used to configure the behavior of those targets:\n" \ "Three environment variables are used to configure the behavior of those targets:\n" \
"\n" \ "\n" \
"$(pr)$(dollar)TARGET$(rst) is used to specify the $(sc)tex$(rst) file to compile" \ "$(pr)$(dollar)TARGET$(rst) is used to specify the $(sc)tex$(rst) file to compile" \
...@@ -34,6 +35,7 @@ INSTRUCTIONS = "$(call print_banner,$(pr),$(sc)Help Instructions $(rst))\n" ...@@ -34,6 +35,7 @@ INSTRUCTIONS = "$(call print_banner,$(pr),$(sc)Help Instructions $(rst))\n"
" $(dollar) export $(pr)TARGET$(rst)=$(sc)resources/tex/intro.tex$(rst)\n" \ " $(dollar) export $(pr)TARGET$(rst)=$(sc)resources/tex/intro.tex$(rst)\n" \
" $(dollar) export $(pr)VARIANTS$(rst)=$(sc)notes$(rst)\n" \ " $(dollar) export $(pr)VARIANTS$(rst)=$(sc)notes$(rst)\n" \
" $(dollar) make\n" \ " $(dollar) make\n" \
" $(dollar) make open\n" \
" $(dollar) make preview\n" \ " $(dollar) make preview\n" \
" $(dollar) make clean\n" \ " $(dollar) make clean\n" \
"\n$(pr)$(header)$(rst)" \ "\n$(pr)$(header)$(rst)" \
...@@ -41,28 +43,46 @@ INSTRUCTIONS = "$(call print_banner,$(pr),$(sc)Help Instructions $(rst))\n" ...@@ -41,28 +43,46 @@ INSTRUCTIONS = "$(call print_banner,$(pr),$(sc)Help Instructions $(rst))\n"
LATEXMK_ERRS = $(if $(strip $(TARGET)),,$(eval TARGET=$(BASENAME))) \ LATEXMK_ERRS = $(if $(strip $(TARGET)),,$(eval TARGET=$(BASENAME))) \
$(if $(strip $(VARIANTS)),,$(eval VARIANTS=$(BASEVARIANTS))) \ $(if $(strip $(VARIANTS)),,$(eval VARIANTS=$(BASEVARIANTS))) \
$(eval SOURCE=$(notdir $(basename $(TARGET)))) \ $(foreach file,$(TARGET), \
$(if $(strip $(VARIANTSLIST)), \ $(eval SOURCE=$(notdir $(basename $(file)))) \
$(foreach v, $(VARIANTSLIST), \ $(if $(strip $(VARIANTSLIST)), \
$(call LOG, $(BUILDDIR)/$(SOURCE)-$(v).log) \ $(foreach variant, $(VARIANTSLIST), \
);, \ $(call LOG, $(BUILDDIR)/$(SOURCE)-$(variant).log) \
$(call LOG, $(BUILDDIR)/$(SOURCE).log) \ );, \
$(call LOG, $(BUILDDIR)/$(SOURCE).log) \
) \
) )
LATEXMK_SELECT = $(if $(strip $(TARGET)),,$(eval TARGET=$(BASENAME))) \ LATEXMK_SELECT = $(if $(strip $(TARGET)),,$(eval TARGET=$(BASENAME))) \
$(if $(strip $(VARIANTS)),,$(eval VARIANTS=$(BASEVARIANTS))) \ $(if $(strip $(VARIANTS)),,$(eval VARIANTS=$(BASEVARIANTS))) \
$(eval SOURCE=$(basename $(TARGET))) \ $(foreach file,$(TARGET), \
$(if $(strip $(VARIANTSLIST)), \ $(eval SOURCE=$(basename $(file))) \
$(foreach v, $(VARIANTSLIST), \ $(if $(strip $(VARIANTSLIST)), \
export JOBNAME=$(notdir $(SOURCE))-$(v) \ $(foreach variant, $(VARIANTSLIST), \
TYPE=$(v) && \ export JOBNAME=$(notdir $(SOURCE))-$(variant) \
$(call LATEXMK,$(SOURCE),$1); \ TYPE=$(variant) && \
), \ $(call LATEXMK,$(SOURCE),$1); \
export JOBNAME=$(notdir $(SOURCE)) \ ), \
TYPE=presentation && \ export JOBNAME=$(notdir $(SOURCE)) \
$(call LATEXMK, $(SOURCE), $1); \ TYPE=presentation && \
$(call LATEXMK, $(SOURCE), $1); \
) \
) )
LATEXMK_PREVIEW = $(if $(strip $(VARIANTS)),,$(eval VARIANTS=$(BASEVARIANTS))) \ LATEXMK_PREVIEW = $(if $(strip $(VARIANTS)),,$(eval VARIANTS=$(BASEVARIANTS))) \
$(if $(strip $(VARIANTSLIST)),$(eval VARIANTSLIST=$(firstword $(VARIANTSLIST))),) \ $(if $(strip $(VARIANTSLIST)),$(eval VARIANTSLIST=$(firstword $(VARIANTSLIST))),) \
$(call LATEXMK_SELECT, -pvc) $(call LATEXMK_SELECT, -pvc)
\ No newline at end of file
LATEXMK_OPEN = $(if $(strip $(TARGET)),,$(eval TARGET=$(BASENAME))) \
$(if $(strip $(VARIANTS)),,$(eval VARIANTS=$(BASEVARIANTS))) \
$(foreach file,$(TARGET), \
$(eval SOURCE=$(basename $(file))) \
$(if $(strip $(VARIANTSLIST)), \
$(foreach variant, $(VARIANTSLIST), \
$(eval JOBNAME=$(notdir $(SOURCE))-$(variant).pdf) \
$(VIEWER) $(BUILDDIR)/$(JOBNAME); \
), \
$(eval JOBNAME=$(notdir $(SOURCE)).pdf) \
$(VIEWER) $(BUILDDIR)/$(JOBNAME); \
) \
)
\ No newline at end of file
include .utils include .utils
BASENAME = demo BASENAME = demo demo2
BUILDDIR = build BUILDDIR = build
BASEVARIANTS = presentation,handout,notes BASEVARIANTS = presentation,handout,notes
# space separated list of requested variants # space separated list of requested variants
...@@ -28,6 +28,9 @@ log: setup ...@@ -28,6 +28,9 @@ log: setup
view: setup view: setup
$(call LATEXMK_SELECT, -pv) $(call LATEXMK_SELECT, -pv)
open: setup
$(call LATEXMK_OPEN)
preview: setup preview: setup
$(call LATEXMK_PREVIEW, -pvc) $(call LATEXMK_PREVIEW, -pvc)
......
...@@ -6,7 +6,7 @@ Template for LaTeX beamer slides (FHTW). ...@@ -6,7 +6,7 @@ Template for LaTeX beamer slides (FHTW).
Provided targets: Provided targets:
build, view, preview, log, clean, distclean, help build, view, preview, clean, distclean, log, open, help
Three environment variables are used to configure the behavior of those targets: Three environment variables are used to configure the behavior of those targets:
...@@ -41,6 +41,7 @@ pass:q[ ...@@ -41,6 +41,7 @@ pass:q[
$ *TARGET*=resources/tex/intro.tex $ *TARGET*=resources/tex/intro.tex
$ *VARIANTS*=notes $ *VARIANTS*=notes
$ make $ make
$ make *open*
$ make *preview* $ make *preview*
$ make *clean* $ make *clean*
] ]
......
= TODOs = TODOs
* Place title, subtitle and author in sidebar using TikZ * Place title, subtitle and author in sidebar using TikZ (done: 2018.12.09)
* Add target `open` to Makefile in addition to `view` avoiding necessity of building if build target exists * Change Makefile to process multiple files specified with `$BASENAME` (done: 2018.12.09)
\ No newline at end of file * Add target `open` to Makefile in addition to `view` avoiding necessity of building if build target exists (done: 2018.12.09)
\ No newline at end of file
No preview for this file type
No preview for this file type
\documentclass{beamer}
% \usepackage[texcoord,grid,gridunit=mm,gridcolor=red!10,subgridcolor=green!10]{eso-pic}
\usepackage[subpreambles,sort]{standalone}
\usepackage{preamble}
\usepackage{fhtw}
\begin{document}
\def\biblio{}
\def\bibliolist{}
% Add acronyms used in images or not used at all by adding to the list
\acuse{FHTW,FG}
% ----------------------------------------------------------------------------------------------------------------------------
% Title & ToC
% ----------------------------------------------------------------------------------------------------------------------------
\input{title}
\begin{frame}[plain]{Outline}
\tableofcontents[subsubsectionstyle=hide]
\addtocounter{framenumber}{-1}
\end{frame}
% ----------------------------------------------------------------------------------------------------------------------------
% Intro
% ----------------------------------------------------------------------------------------------------------------------------
\input{intro}
% ----------------------------------------------------------------------------------------------------------------------------
% Main Content
% ----------------------------------------------------------------------------------------------------------------------------
\input{content}
% ----------------------------------------------------------------------------------------------------------------------------
% Outro
% ----------------------------------------------------------------------------------------------------------------------------
\input{outro}
% ----------------------------------------------------------------------------------------------------------------------------
% Appendix
% ----------------------------------------------------------------------------------------------------------------------------
\section{Appendix}
\appendix
% Acronyms
\begin{frame}[allowframebreaks]{Acronyms}
\label{acronyms}
\printacronyms
\end{frame}
% References
\begin{frame}[allowframebreaks]{References}
\label{references}
\bibliography{references}
\end{frame}
\end{document}
\ No newline at end of file
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
\def\currentdate{\@date} \def\currentdate{\@date}
\makeatletter \def\currentdate{\@date} \makeatother \makeatletter \def\currentdate{\@date} \makeatother
\def\title{Presentation Title} \def\title{Presentation Title}
\def\subtitle{Presentation Subtitle}
\def\shorttitle{\hspace{1.75em}\title} \def\shorttitle{\hspace{1.75em}\title}
\def\authorname{Walter Subject} \def\authorname{Walter Subject}
\def\authortext{\href{mailto:me@technikum-wien.at;other@technikum-wien.at?subject=\title}{Ausgef\"uhrt von: \authorname}} \def\authortext{\href{mailto:me@technikum-wien.at;other@technikum-wien.at?subject=\title}{Ausgef\"uhrt von: \authorname}}
......
...@@ -177,6 +177,7 @@ ...@@ -177,6 +177,7 @@
% Content % Content
\node[title text style, shift={(\identation,8)}] at (start) {\title}; \node[title text style, shift={(\identation,8)}] at (start) {\title};
\node[norm text style, shift={(\identation,7)}] at (start) {\subtitle};
\coordinate (textstart) at ($(current page.south west)+(0.1,-0.1)$); \coordinate (textstart) at ($(current page.south west)+(0.1,-0.1)$);
\node[norm text style, shift={(\identation,4.75)}] at (textstart) {\authortext}; \node[norm text style, shift={(\identation,4.75)}] at (textstart) {\authortext};
\node[norm text style, shift={(\identation,4.25)}] at (textstart) {\studentid}; \node[norm text style, shift={(\identation,4.25)}] at (textstart) {\studentid};
...@@ -221,20 +222,18 @@ ...@@ -221,20 +222,18 @@
\vskip 0.7cm \hskip 0.50cm \vskip 0.7cm \hskip 0.50cm
\includegraphics[height=15pt]{resources/images/fhtw-logo.pdf} \includegraphics[height=15pt]{resources/images/fhtw-logo.pdf}
%FIXME: Place via tikz environment % Author, Title, Subtitle
\vskip 0.75cm \begin{tikzpicture}[
{ overlay,remember picture,
\usebeamercolor[fg]{author in sidebar} base text style/.style = { anchor=center, text width=1.8\sidebarwidth, draw=none, align=center},
\insertshortauthor[width=\sidebarwidth,center,respectlinebreaks] ]
} \node[base text style, color=\secondarycolor] at (0.99\sidebarwidth+0.4,-0.7) {\authorname};
\draw[draw=\primarycolor,dotted] (0.2,-0.95) -- ++(1.6\sidebarwidth,0);
\vskip 0.25cm \node[base text style, color=\primarycolor] at (0.99\sidebarwidth+0.4,-1.3) {\title};
{ \node[base text style, color=\primarycolor] at (0.99\sidebarwidth+0.4,-1.7) {\subtitle};
\usebeamercolor[fg]{title in sidebar} \end{tikzpicture}
\shorttitle
}
\vskip 0.50cm \vskip 2cm
{ {
\insertverticalnavigation{\sidebarwidth} \insertverticalnavigation{\sidebarwidth}
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment