texlive[54866] Master/texmf-dist: willowtreebook (24apr20)

commits+karl at tug.org commits+karl at tug.org
Fri Apr 24 22:59:23 CEST 2020


Revision: 54866
          http://tug.org/svn/texlive?view=revision&revision=54866
Author:   karl
Date:     2020-04-24 22:59:23 +0200 (Fri, 24 Apr 2020)
Log Message:
-----------
willowtreebook (24apr20)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/willowtreebook/README
    trunk/Master/texmf-dist/doc/latex/willowtreebook/willowtreebook.pdf
    trunk/Master/texmf-dist/doc/latex/willowtreebook/willowtreebook.tex
    trunk/Master/texmf-dist/tex/latex/willowtreebook/willowtreebook.cls

Modified: trunk/Master/texmf-dist/doc/latex/willowtreebook/README
===================================================================
--- trunk/Master/texmf-dist/doc/latex/willowtreebook/README	2020-04-24 20:58:51 UTC (rev 54865)
+++ trunk/Master/texmf-dist/doc/latex/willowtreebook/README	2020-04-24 20:59:23 UTC (rev 54866)
@@ -1,6 +1,6 @@
 Willow Tree Book Class
-v1.0
-22 April 2020
+v1.01
+24 April 2020
 
 Authors: 
 Ben McKay

Modified: trunk/Master/texmf-dist/doc/latex/willowtreebook/willowtreebook.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/doc/latex/willowtreebook/willowtreebook.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/willowtreebook/willowtreebook.tex	2020-04-24 20:58:51 UTC (rev 54865)
+++ trunk/Master/texmf-dist/doc/latex/willowtreebook/willowtreebook.tex	2020-04-24 20:59:23 UTC (rev 54866)
@@ -1,5 +1,5 @@
 \documentclass{willowtreebook}
-\Title{The Willow Tree Book Class v1.0}
+\Title{The Willow Tree Book Class 1.01}
 \Author{Benjamin \scotsMc{}Kay}
 \Colophon{Released under the \LaTeX{} Public Project License 1.3c}
 \BibliographyFile{willowtreebook}
@@ -38,21 +38,25 @@
 Compile with \verb!latex! or \verb!pdflatex!.
 \chapter{Definitions, Problems and Theorems}
 \section{Definitions}
-We can define a term like \emph{hamster}\define{hamster}, or say that the term hamster appears again later\SubIndex{hamster}.
-We add notation like when we use a variable called \(\omega\), we put it in the list of notation.\Notation{omega}{\omega}{A variable called $\omega$}
+We can define a term like \emph{hamster}\define{hamster}, or say that the term hamster\SubIndex{hamster} appears again later.
 \begin{Verbatim}[frame=leftline]
 \chapter{Definitions, Problems and Theorems}
 \section{Definitions}
 We can define a term like \emph{hamster}\define{hamster}, 
-or say that the term hamster appears again later\SubIndex{hamster}.
+or say that the term hamster\SubIndex{hamster} appears again later.
 \end{Verbatim}
 Compile, for a book called \verb!filename.tex!, with
 \begin{Verbatim}[frame=leftline]
 	makeindex filename
 \end{Verbatim}
-We add notation like when we use a variable called \(\omega\), 
+We add notation like when we use a variable called \(\omega\),
 we put it in the list of notation.%
-\Notation{omega}{\omega}{A variable called $\omega$}.
+\Notation{omega}{\omega}{A variable called $\omega$}
+\begin{Verbatim}
+We add notation like when we use a variable called \(\omega\),
+we put it in the list of notation.%
+\Notation{omega}{\omega}{A variable called $\omega$}
+\end{Verbatim}
 If you use notation, compile with
 \begin{Verbatim}[frame=leftline]
 	makeindex -s notation.gst -o not.gls not.glo  
@@ -96,4 +100,25 @@
 side of length \(c\) is a right angle.
 \end{theorem}
 \end{Verbatim}
+I often want to present an example, and make clear where it starts and stops.
+\begin{example}
+The integral 
+\[
+\int e^{x^2}x\,dx
+\]
+is evaluated by substituting \(u=x^2\), so
+\[
+\int e^{x^2}x\,dx=\int e^u \frac{du}{2}.
+\]
+\end{example}
+\begin{Verbatim}[frame=leftline]
+The integral 
+\[
+\int e^{x^2}x\,dx
+\]
+is evaluated by substituting \(u=x^2\), so
+\[
+\int e^{x^2}x\,dx=\int e^u \frac{du}{2}.
+\]
+\end{Verbatim}
 \end{document}

Modified: trunk/Master/texmf-dist/tex/latex/willowtreebook/willowtreebook.cls
===================================================================
--- trunk/Master/texmf-dist/tex/latex/willowtreebook/willowtreebook.cls	2020-04-24 20:58:51 UTC (rev 54865)
+++ trunk/Master/texmf-dist/tex/latex/willowtreebook/willowtreebook.cls	2020-04-24 20:59:23 UTC (rev 54866)
@@ -1,31 +1,21 @@
 \NeedsTeXFormat{LaTeX2e}
-\ProvidesClass{willowtreebook}[2020/04/22 Willow Tree book LaTeX class v1.0]
+\ProvidesClass{willowtreebook}[2020/04/24 Willow Tree Book LaTeX class v1.01]
 \DeclareOption{ContainsChinese}{\def\ChineseTextInThisDocument{}}
-\DeclareOption*{%
-\PassOptionsToClass{\CurrentOption}{article}%
-}
+\DeclareOption*{\PassOptionsToClass{\CurrentOption}{memoir}}
 \ProcessOptions\relax
-
 \LoadClass{memoir}
-
 \RequirePackage{xparse}
-
-\def\emptystring{}
-
-\edef\mckaybook at title{\emptystring}
-\edef\mckaybook at subtitle{\emptystring}
-\edef\mckaybook at author{\emptystring}
-\edef\mckaybook at bibliography{\emptystring}
-\edef\mckaybook at colophon{This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.}
-
+\def\mckaybook at title{}
+\def\mckaybook at subtitle{}
+\def\mckaybook at author{}
+\def\mckaybook at bibliography{}
+\def\mckaybook at colophon{This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.}
 \NewDocumentCommand\Title{m}{\global\def\mckaybook at title{#1}}
 \NewDocumentCommand\Subtitle{m}{\global\def\mckaybook at subtitle{#1}}
 \NewDocumentCommand\Author{m}{\global\def\mckaybook at author{#1}}
 \NewDocumentCommand\BibliographyFile{m}{\global\def\mckaybook at bibliography{#1}}
 \NewDocumentCommand\Colophon{m}{\global\def\mckaybook at colophon{#1}}
-
 % For handling names like Benjamin McKay, where the letter c should be raised up, type in as Benjamin \scotsMc{}Kay.
-\makeatletter
 \DeclareRobustCommand{\scotsMc}{\scotsMcx{c}}
 \DeclareRobustCommand{\scotsMC}{\scotsMcx{\textsc{c}}}
 \DeclareRobustCommand{\scotsMcx}[1]{%
@@ -38,8 +28,6 @@
 \expandafter\def\expandafter\@uclclist\expandafter{%
   \@uclclist\scotsMc\scotsMC
 }
-\makeatother
-
 \RequirePackage{etex}
 \RequirePackage{newunicodechar}
 \RequirePackage[utf8]{inputenc} % Default input file encoding
@@ -49,7 +37,6 @@
 \NewDocumentCommand\Chinese{m}{\begin{CJK*}{UTF8}{gbsn}#1\end{CJK*}}
 \else 
 \fi
-
 \RequirePackage[T1]{fontenc}
 \RequirePackage{lmodern}
 \RequirePackage{isomath}
@@ -72,12 +59,10 @@
 \RequirePackage{braket}
 \RequirePackage{mathtools}
 \mathtoolsset{showonlyrefs,showmanualtags,centercolon,mathic}
-
 % If we need more room between rows of matrices and arrays, we can write
 % \begin{pmatrix}[1.5]
 % instead of 
 % \begin{pmatrix}
-\makeatletter
 \RenewDocumentCommand\env at matrix{O{\arraystretch}}
 {%
 \edef\arraystretch{#1}%
@@ -85,15 +70,12 @@
   \let\@ifnextchar\new at ifnextchar
   \array{*\c at MaxMatrixCols c}
 }%
-\makeatother
 \NewDocumentCommand\tallmatrix{}{1.5}
-
 \RequirePackage{varioref}
 \RequirePackage{longtable}
 \RequirePackage{multicol}
 \setmarginnotes{2em}{3cm}{.5cm}
-
-% Indices
+%.......Indices
 \newcommand{\NotationIndexName}{List of notation}
 \makeindex
 \makeglossary[not]
@@ -123,7 +105,6 @@
 \ifnum\value{page}<10 0\fi%
 \arabic{page}%
 }%%
-
 \newcounter{howmany at notation}
 \setcounter{howmany at notation}{0}
 \newcommand{\Notation}[3]%%
@@ -131,7 +112,6 @@
 {\glossary[not](\paddedpagenumber){\(#2\)}{#3}%
 \stepcounter{howmany at notation}%
 }
-
 \newcounter{howmany at indexentries}
 \setcounter{howmany at indexentries}{0}
 \newcommand{\SubIndex}[1]%
@@ -168,7 +148,6 @@
 }
 \newcommand{\ceilForNotationIndex}[1]{\lcl{#1}\rcl}
 \newcommand{\floorForNotationIndex}[1]{\lflr{#1}\rflr}
-
 % For the subject index:
 % Example:
 %    \define{interest rate}
@@ -184,7 +163,6 @@
 %% PDF Output
 \ifpdf
   \pdfoutput=1
-  \makeatletter
   \RequirePackage[plainpages=false,
     hyperfigures,
     pdftitle={\mckaybook at title},
@@ -196,7 +174,6 @@
     pagebackref,
     pdftex]
     {hyperref}
-  \makeatother
   \RequirePackage{memhfixc}
 % Hyperref uses very bright colours to highlight links. Change them:
   \RequirePackage[svgnames]{xcolor}
@@ -208,7 +185,6 @@
     citecolor={dark-blue}, urlcolor={medium-blue}
   }
 \fi
-
 \newcommand{\idxmark}[1]{#1\markboth{#1}{#1}}
 \newcommand{\doidxbookmark}[1]{{\def\@tempa{Symbols}\def\@tempb{#1}%
 \ifx\@tempa\@tempb %
@@ -221,10 +197,8 @@
 \pdfbookmark[0]{#1}{#1-idx}%
 \fi%
 \vskip\onelineskip\par}}
-
 \newcommand\doglobookmark[1]{%
 }%
-
 %......Figures
 \newcommand{\stdFigSize}{1in}
 \newsubfloat{figure} % Memoir class, instead of subfigure class.
@@ -236,9 +210,7 @@
 \captionnamefont{\scriptsize}
 \captiontitlefont{\scriptsize}
 \newcommand{\heading}{\sffamily}
-
 \newcommand{\chapterSummary}[1]{{\small{#1}}\vspace{0.5cm}\par\noindent}
-
 \makechapterstyle{bobo}{%
 \aliaspagestyle{part}{empty}
 \renewcommand{\partnamefont}{\raggedleft\normalfont\huge\heading}
@@ -256,14 +228,11 @@
 \renewcommand*{\chaptitlefont}{\Large\heading}
 \renewcommand*{\printchaptertitle}[1]{%
 \centering\smallcolouredbox\chaptitlefont ##1}}
-
 \chapterstyle{bobo}
-
 \setsecheadstyle{\large\heading\raggedright}
 \setsubsecheadstyle{\heading\raggedright}
 \setsubsubsecheadstyle{\heading\raggedright}
 \setheadfoot{2\onelineskip}{3\onelineskip}
-
 \newcommand{\optionalSection}[1]%
 {%%
 \section{#1}
@@ -270,7 +239,6 @@
 {\small{This section can be omitted without loss of continuity.}}%
 \medskip\par\noindent%
 }%%
-
 %......Table of contents
 % depth of numbering of sectioning commands:
 \setsecnumdepth{chapter}
@@ -277,24 +245,18 @@
 \maxsecnumdepth{chapter}
 %% depth of table of contents:  
 \setcounter{tocdepth}{0}
-
 \RenewDocumentCommand\cftpartfont{}{\heading\small}
 \RenewDocumentCommand\cftpartpagefont{}{\normalfont\small}
-
 \RenewDocumentCommand\cftchapterfont{}{\heading\small}
 \RenewDocumentCommand\cftchapterpagefont{}{\normalfont\small}
-
 \setlength{\cftbeforechapterskip}{3pt}
 \RenewDocumentCommand\cftchapterleader{}{\quad}
 \setpnumwidth{1em}
 \RenewDocumentCommand\cftchapterafterpnum{}{\cftparfillskip}
-
 \setlength{\cftbeforepartskip}{10pt}
 \RenewDocumentCommand\cftpartleader{}{\quad}
 \setpnumwidth{1em}
 \RenewDocumentCommand\cftpartafterpnum{}{\cftparfillskip}
-
-
 %......Title page
 \pretitle{\begin{center}\HUGE}
 \posttitle{\end{center}}
@@ -302,11 +264,9 @@
 \postauthor{\end{center}}
 \predate{\begin{center}}
 \postdate{\end{center}}
-
 \usepackage{tcolorbox}
 \tcbuselibrary{breakable}
 \tcbuselibrary{skins}
-
 %......Theorem Styles
 %\newtheoremstyle{RegularStyle}% name
 %  {}%      Space above, empty = `usual value'
@@ -324,9 +284,8 @@
 \newtheorem{lemma}[theorem]{Lemma}
 \newtheorem{corollary}[theorem]{Corollary}
 \newtheorem{proposition}[theorem]{Proposition}
-
+%.......Colours
 \colorlet{exampleBackgroundColour}{gray!16}
-
 \newtcolorbox{example}{%
 enhanced,%
 breakable,%
@@ -364,7 +323,6 @@
 \begin{itemize}}%
 {\end{itemize}%
 \end{example}}
-
 % In the middle of an example, the background color is not white. If you need a white background to put an image on it, it looks best to use an imageborderinexample.
 \definecolor{image-border-color}{gray}{.975}
 \NewDocumentCommand\imageborderinexample{m}{\begin{center}\tcbox[colframe=image-border-color, colback=white]
@@ -372,8 +330,6 @@
 \NewDocumentCommand\includegraphicsinexample{om}%
 {\IfValueTF{#1}{\imageborderinexample{\includegraphics[#1]{#2}}}{\imageborderinexample{\includegraphics{#2}}}}
 \NewDocumentCommand\inputinexample{m}{\imageborderinexample{\input{#1}}}
-
-
 %......Problems
 % To define a new problem, use: 
 % \begin{problem}{<label>} <statement> \end{problem}
@@ -422,7 +378,6 @@
 % Otherwise, we get mysterious errors. We could probably
 % just make use of \protect here.
 \let\newparagraph=\par
-\makeatletter
 \NewDocumentEnvironment{@nswer}{m}{\@bsphack\IfStreamOpen{ansout}{}{\openoutputfile{\jobname.ans}{ansout}}
 \addtostream{ansout}{\smallskip\newparagraph\noindent\textbf{\protect\ref{problem:#1}.}}}{\@esphack}
 \newcounter{howmany at answers}
@@ -429,13 +384,10 @@
 \setcounter{howmany at answers}{0}
 \NewDocumentEnvironment{answer}{m}%
 {\stepcounter{howmany at answers}\@bsphack\@nswer{#1}\writeverbatim{ansout}}{\par\endwriteverbatim\end at nswer\@esphack}
-\makeatother
-
 % Colour for the rulings in tables:
 \RequirePackage{colortbl}
 \newcommand{\defaultArrayRuleColor}{gray!30}
 \arrayrulecolor{\defaultArrayRuleColor}
-\makeatletter
     \def\rulecolor#1#{\CT at arc{#1}}
     \def\CT at arc#1#2{%
       \ifdim\baselineskip=\z@\noalign\fi
@@ -442,18 +394,14 @@
       {\gdef\CT at arc@{\color#1{#2}}}}
     \let\CT at arc@\relax
 \rulecolor{gray!30}
-\makeatother
-
 \RequirePackage{enumitem}
 \setlist[enumerate,1]{label=\emph{\alph*.}}
 \setlist[enumerate,2]{label=\arabic*.,
 ref=\theenumi.\emph{\alph*}}
 \setlist[enumerate,3]{label=\roman*), ref=\theenumii.\roman*}
-
-\makeatletter
 \NewDocumentCommand\writetitlepage{}
 {%
-    \ifx\mckaybook at title\emptystring
+    \ifx\mckaybook at title\@empty
     \else
     		\begingroup
     		\raggedleft
@@ -460,7 +408,7 @@
     		\vspace*{\baselineskip}
     		{\Large \mckaybook at author
     		}\\[0.167\textheight]
-    		\ifx\mckaybook at subtitle\emptystring%
+    		\ifx\mckaybook at subtitle\@empty%
 			\Huge\heading\mckaybook at title\\[\baselineskip]%
 		\else%
 			\Huge\heading\mckaybook at title\\[\baselineskip]%
@@ -473,8 +421,6 @@
     		\endgroup
     \fi
 }%
-\makeatother
-
 %% \newclr generates a colour based on the current chapter number, so we execute it every time we create a new chapter. It saves that colour in a global color variable called chpclr. This colour is used to highlight the chapter name at the beginning of the chapter and in all of the headings at the top of each page.
 \newcommand*{\newcolr}%%
 {%%
@@ -508,35 +454,28 @@
 \settoheight{\smallboxh}{l}
 \settodepth{\smallboxd}{l}
 \newcommand*{\blanksp}{\phantom{\rule[\smallboxd]{\smallboxw}{\smallboxh}}}
-
 \newif\ifchaptercolours
 \chaptercoloursfalse
-
 \NewDocumentCommand\smallcolouredbox{}%
 {%%
 \ifchaptercolours\,{\colorbox{chpclr}{\blanksp}}\,\else\fi
 }%%
 \RenewDocumentCommand\chapnamefont{m}{\newcolr\large\centering#1}
-
 \definecolor{colorAAA}{rgb}{.75,1,1}
 \definecolor{colorBBB}{rgb}{1,.75,1}
 \definecolor{colorCCC}{rgb}{1,1,.75}
-
-
-
-\makeatletter
 \AtBeginDocument%
 {%%
 \frontmatter
 % Title page
-\ifx\mckaybook at title\emptystring
+\ifx\mckaybook at title\@empty
 \else
-    \ifx\mckaybook at subtitle\emptystring%
+    \ifx\mckaybook at subtitle\@empty%
         \title{\MakeUppercase{\mckaybook at title}}
 	\else
         \title{\MakeUppercase{\mckaybook at title} \\ \MakeUppercase{\mckaybook at subtitle}}
     \fi
-    \ifx\mckaybook at author\emptystring%
+    \ifx\mckaybook at author\@empty%
     \else
 		\author
 		{%
@@ -547,7 +486,6 @@
 	    }%
 	\fi
 \fi
-\makeatother
 \writetitlepage
 \thispagestyle{empty}
 \pagenumbering{roman}
@@ -556,7 +494,6 @@
 {\normalfont\thepage}{}{\small\heading\leftmark\smallcolouredbox\negphantom{\smallcolouredbox}}
 \makeoddhead{companion}%
 {\small\negphantom{\smallcolouredbox}\smallcolouredbox\heading\rightmark}{}{\normalfont\thepage}
-
 \setlength{\cftchapterindent}{4cm}
 \setlength{\cftpartindent}{4cm}
 \pagestyle{empty}
@@ -564,9 +501,7 @@
 \clearpage
 \pagestyle{companion}
 }%%
-
 \NewDocumentCommand\negphantom{m}{\settowidth{\dimen0}{#1}\hspace*{-\dimen0}}
-
 \NewDocumentCommand\afterpreface{}
 {%
 \clearpage
@@ -575,11 +510,9 @@
 \chaptercolourstrue
 \pagenumbering{arabic}
 }%
-
 \NewDocumentCommand\hintsPreamble{}{}
 \AtEndDocument%
 {%%
-
 \backmatter
 \chaptercoloursfalse
 \ifnum\value{howmany at answers}>0\relax%
@@ -589,9 +522,7 @@
 \hintsPreamble%
 \printanswers%
 \fi%
-
-\makeatletter
-\ifx\mckaybook at bibliography\emptystring
+\ifx\mckaybook at bibliography\@empty
 \else
 % Bibliography
 \bibliographystyle{amsplain}
@@ -598,8 +529,6 @@
 \bibliography{\mckaybook at bibliography}
 \flushbottom
 \fi
-\makeatother
-
 % Notation Index
 \ifnum\value{howmany at notation}>0
 \indexintoc
@@ -606,7 +535,6 @@
 {\RenewDocumentCommand{\indexspace}{}{}\small{\printglossary[not]}}
 \cleardoublepage
 \fi
-
 % Index
 \ifnum\value{howmany at indexentries}>0
 \indexintoc
@@ -613,6 +541,4 @@
 \RenewDocumentCommand\indexname{}{Index}
 {\small{\printindex}}
 \fi
-
-
 }%% AtEndDocument



More information about the tex-live-commits mailing list.