Manage the with/without margin dummy file
set_margin_token_file.RdSee style/lmu-lecture.sty where depending on the presence of an empty .tex file with a
specific name certain layout options are set to compile slides either in 16:9 with margins or
in 4:3 without a margin for the speaker.
Arguments
- wd
Working directory (relative or absolute) where the file needs to be created. This is the directory were the
.texfile to be compiled is located.- margin
[TRUE]Whether to enable or disable the margin.- token_name
"nospeakermargin.tex"If the name changes or needs to be flexible for testing it can be adjusted, but typically the name is set in stone vialmu-lecture.sty.
Examples
wd <- tempdir()
set_margin_token_file(wd = wd, margin = FALSE)
stopifnot("file exists when no margin set" = file.exists(file.path(wd, "nospeakermargin.tex")))
set_margin_token_file(wd = wd, margin = TRUE)
stopifnot("file is removed when margin set" = !file.exists(file.path(wd, "nospeakermargin.tex")))