From b17a790b77257512973c5d0de6b32c4a01534a4c Mon Sep 17 00:00:00 2001 From: Jim Hague Date: Fri, 4 Nov 2016 00:03:54 +0000 Subject: [PATCH] Create a section title page in the print version. Move the section comment to that title page. --- dottes.tex | 18 ------------------ dottes.tex.section-firstlines | 9 +++++++++ dottes.tex.section-tunes | 27 +++++++++++++++++++++++++++ makeBooke.sh | 9 ++++++--- makeBookeTunePages.sh | 4 ++-- 5 files changed, 44 insertions(+), 23 deletions(-) create mode 100644 dottes.tex.section-firstlines create mode 100644 dottes.tex.section-tunes diff --git a/dottes.tex b/dottes.tex index 0bbb0a9..070cdb7 100644 --- a/dottes.tex +++ b/dottes.tex @@ -180,8 +180,6 @@ Havoc musicians come in all shades of experience and ability. This collection is intended to help those like me who are inexpert with instrument and folk music generally, but have a little musical background. -\input{intro.tex} - Being folk tunes, many of the tunes herein have many variations. The music presented here is my attempt at reflecting what the musicians of Cry Havoc play. I'm in no way suggesting that they are @@ -220,17 +218,7 @@ anniversary in 2013. \mainmatter -\addcontentsline{toc}{chapter}{Tunes} - -{ -\newcolumntype{L}{p{0.25\textwidth}}% -\newcolumntype{R}{>{\raggedleft\arraybackslash}p{0.25\textwidth}}% -\newcolumntype{C}{>{\centering\arraybackslash}X}% -\renewcommand{\tabularxcolumn}[1]{m{#1}}% -\renewcommand{\tabcolsep}{0pt} - \input{tunes.tex} -} % ----- @@ -242,13 +230,7 @@ You know the feeling. Everyone has just launched into a well-loved tune. You've heard it before, but don't remember the name. So here's a list of tune first lines to help you figure out what it is in time to join in. -{\renewcommand{\arraystretch}{2.5} -\setlength\LTleft{0pt} -\setlength\LTright{\fill} -\begin{longtable}{@{}>{\raggedright\arraybackslash}m{0.2\textwidth}r@{}} \input{firstlines.tex} -\end{longtable} -} % ----- Back cover page. A plain purple page. diff --git a/dottes.tex.section-firstlines b/dottes.tex.section-firstlines new file mode 100644 index 0000000..4b9198c --- /dev/null +++ b/dottes.tex.section-firstlines @@ -0,0 +1,9 @@ +\section{@SECTION@ tunes} + +{\renewcommand{\arraystretch}{2.5} +\setlength\LTleft{0pt} +\setlength\LTright{\fill} +\begin{longtable}{@{}>{\raggedright\arraybackslash}m{0.2\textwidth}r@{}} +\input{@SECTION@-firstlines.tex} +\end{longtable} +} diff --git a/dottes.tex.section-tunes b/dottes.tex.section-tunes new file mode 100644 index 0000000..29ae2fb --- /dev/null +++ b/dottes.tex.section-tunes @@ -0,0 +1,27 @@ +% ----- Tunes and intro page for a section. + +\newpage + +\addcontentsline{toc}{chapter}{@SECTION@ tunes} + +\vspace*{\fill} + +\begin{center} +{\Large @SECTION@ tunes} +\end{center} + +\vspace*{\fill} + +\input{@SECTION@-intro.tex} + +\newpage + +{ +\newcolumntype{L}{p{0.25\textwidth}}% +\newcolumntype{R}{>{\raggedleft\arraybackslash}p{0.25\textwidth}}% +\newcolumntype{C}{>{\centering\arraybackslash}X}% +\renewcommand{\tabularxcolumn}[1]{m{#1}}% +\renewcommand{\tabcolsep}{0pt} + +\input{@SECTION@-tunes.tex} +} diff --git a/makeBooke.sh b/makeBooke.sh index 07570bc..d2af930 100755 --- a/makeBooke.sh +++ b/makeBooke.sh @@ -36,14 +36,17 @@ do done for item in intro do - rm -f $builddir/$item.tex + rm -f $builddir/$1-$item.tex if [ -r $booke/$item.md ]; then - pandoc --from=markdown --to=latex --output=$builddir/$item.tex $booke/$item.md + pandoc --from=markdown --to=latex --output=$builddir/$1-$item.tex $booke/$item.md else - touch $builddir/$item.tex + touch $builddir/$1-$item.tex fi done +sed -e "s/@SECTION@/$1/" dottes.tex.section-tunes > $builddir/tunes.tex +sed -e "s/@SECTION@/$1/" dottes.tex.section-firstlines > $builddir/firstlines.tex + for filename in $dir/*.${papersize}.tex do name=`basename $filename .${papersize}.tex` diff --git a/makeBookeTunePages.sh b/makeBookeTunePages.sh index 637195b..cc82a9a 100755 --- a/makeBookeTunePages.sh +++ b/makeBookeTunePages.sh @@ -18,8 +18,8 @@ dir=`pwd` booke=$dir/$1 builddir=$dir/build graphicsdir=$dir/graphics/$1 -tunesoutput=$builddir/tunes.tex -indexoutput=$builddir/firstlines.tex +tunesoutput=$builddir/$1-tunes.tex +indexoutput=$builddir/$1-firstlines.tex mkdir -p $builddir