summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/colorist/colorbook.cls
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2021-05-23 20:34:49 +0000
committerKarl Berry <karl@freefriends.org>2021-05-23 20:34:49 +0000
commit3b54a871bd1170014aaabf21dcce9ef8d4e21353 (patch)
tree39d536566a29cd6d179df516dad51bff867c9e11 /Master/texmf-dist/tex/latex/colorist/colorbook.cls
parent91764c8b53e5acc5bed3a52e9df0021127ca32d0 (diff)
colorist (23may21)
git-svn-id: svn://tug.org/texlive/trunk@59316 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/colorist/colorbook.cls')
-rw-r--r--Master/texmf-dist/tex/latex/colorist/colorbook.cls83
1 files changed, 34 insertions, 49 deletions
diff --git a/Master/texmf-dist/tex/latex/colorist/colorbook.cls b/Master/texmf-dist/tex/latex/colorist/colorbook.cls
index e620546e5a0..da8b6e75b84 100644
--- a/Master/texmf-dist/tex/latex/colorist/colorbook.cls
+++ b/Master/texmf-dist/tex/latex/colorist/colorbook.cls
@@ -17,7 +17,7 @@
%%
\NeedsTeXFormat{LaTeX2e}[2020-10-01]
\ProvidesClass{colorbook}
- [2021/03/15 A colorful book style]
+ [2021/05/24 A colorful book style]
\def\colorclass@baseclass{book}
\RequirePackage{kvoptions}
\RequirePackage{etoolbox}
@@ -27,6 +27,12 @@
}
\DeclareBoolOption[false]{draft}
\DeclareBoolOption[false]{fast}
+
+\newif\if@colorclass@bfivepaper\@colorclass@bfivepaperfalse
+\DeclareVoidOption{b5paper}{\@colorclass@bfivepapertrue}
+\newif\if@colorclass@afourpaper\@colorclass@afourpaperfalse
+\DeclareVoidOption{a4paper}{\@colorclass@afourpapertrue}
+
\DeclareDefaultOption{\PassOptionsToClass{\CurrentOption}{\colorclass@baseclass}}
\ProcessKeyvalOptions*\relax
\LoadClass{\colorclass@baseclass}
@@ -37,20 +43,41 @@
%%================================
%% Page layout
%%================================
+\RequirePackage{silence}
+\WarningFilter{geometry}{Over-specification in}
\RequirePackage[heightrounded]{geometry}
\geometry{
- % papersize={8in,11in},
+ papersize={8.5in,11in},
+ total={47em,66em},
+ hmarginratio=1:1,
+ vmarginratio=1:1,
+ footnotesep=2em plus 2pt minus 2pt,
+}
+\if@colorclass@bfivepaper
+\geometry{
+ b5paper,
+ total={40em,59em},
+ hmarginratio=1:1,
+ vmarginratio=1:1,
+ footnotesep=2em plus 2pt minus 2pt,
+}
+\fi
+\if@colorclass@afourpaper
+\geometry{
a4paper,
total={47em,70em},
hmarginratio=1:1,
vmarginratio=1:1,
footnotesep=2em plus 2pt minus 2pt,
}
+\fi
\RequirePackage{indentfirst}
\if@colorclass@fast
\PassOptionsToPackage{fast}{colorist}
+ \RequirePackage{draftwatermark}
+ \DraftwatermarkOptions{text={\normalfont DRAFT},colorspec=0.95}
\fi
\RequirePackage{colorist}
@@ -64,6 +91,9 @@
\fi
\RequirePackage{mathpazo}
\RequirePackage{newpxtext}
+\RequirePackage{amssymb}
+
+\def\PJL@font@alreadyset{}
\RequirePackage[verbose=silent]{microtype}
@@ -73,60 +103,15 @@
\RequirePackage{graphicx}
\graphicspath{{images/}}
\RequirePackage{wrapfig}
+\RequirePackage{float}
\RequirePackage{caption}
+\captionsetup{font=small}
%%================================
%% Index
%%================================
\RequirePackage{imakeidx}
-%%================================
-%% Draft mark
-%%================================
-\def\dnfFont{\ttfamily}
-\def\needgraphFont{\ttfamily}
-
-\def\dnfTextEN{To be finished here}
-\def\needgraphTextEN{A graph is needed here}
-\def\dnfTextFR{À terminer ici}
-\def\needgraphTextFR{Il manque encore un graphique ici}
-\def\dnfTextCN{这里的内容尚未完成}
-\def\needgraphTextCN{这里需要一张图片}
-
-\definecolor{dnfColor}{RGB}{21,122,20}
-\definecolor{needgraphColor}{RGB}{70,130,180}
-
-\if@colorclass@fast
- \newcommand{\plainBox}[2][-paper]{\textcolor{#1}{%
- \setlength{\fboxsep}{1.5pt}%
- \setlength{\fboxrule}{1.2pt}%
- \fbox{#2}}}
-\else
- \PassOptionsToPackage{many}{tcolorbox}
- \RequirePackage{tcolorbox}
- \newtcbox{\plainBox}[1][-paper]{enhanced jigsaw,%
- on line, arc = 1.2pt, outer arc = 1pt,breakable,%
- colframe = #1,colupper=#1,opacityback=0,%
- boxsep = 1pt,boxrule = 1.2pt,%
- left = 1pt, right = 1pt, top = 0pt, bottom = 0pt,%
- }
-\fi
-
-\NewDocumentCommand{\dnf}{d<>}{%
- \noindent\plainBox[dnfColor]%
- {\normalfont\dnfFont\bfseries\small%
- \csname dnfText\csname\languagename ABBR\endcsname\endcsname%
- \IfNoValueF{#1}{ : #1}}%
-}
-\NewDocumentCommand{\needgraph}{d<>}{%
- \par%
- \centerline{\plainBox[needgraphColor]%
- {\normalfont\needgraphFont\bfseries\small%
- \csname needgraphText\csname\languagename ABBR\endcsname\endcsname%
- \IfNoValueF{#1}{ : #1}}}%
- \par%
-}
-
\endinput
%%
%% End of file `colorist/colorbook.cls'.