texlive[56917] Master/texmf-dist: bookcover (12nov20)
commits+karl at tug.org
commits+karl at tug.org
Thu Nov 12 22:39:04 CET 2020
Revision: 56917
http://tug.org/svn/texlive?view=revision&revision=56917
Author: karl
Date: 2020-11-12 22:39:03 +0100 (Thu, 12 Nov 2020)
Log Message:
-----------
bookcover (12nov20)
Modified Paths:
--------------
trunk/Master/texmf-dist/doc/latex/bookcover/README
trunk/Master/texmf-dist/doc/latex/bookcover/bookcover-example1.pdf
trunk/Master/texmf-dist/doc/latex/bookcover/bookcover-example2.pdf
trunk/Master/texmf-dist/doc/latex/bookcover/bookcover.pdf
trunk/Master/texmf-dist/source/latex/bookcover/bookcover.dtx
trunk/Master/texmf-dist/source/latex/bookcover/bookcover.ins
trunk/Master/texmf-dist/tex/latex/bookcover/bookcover.cls
Removed Paths:
-------------
trunk/Master/texmf-dist/doc/latex/bookcover/bookcover-example-obsoletemethod.tex
Modified: trunk/Master/texmf-dist/doc/latex/bookcover/README
===================================================================
--- trunk/Master/texmf-dist/doc/latex/bookcover/README 2020-11-12 21:38:29 UTC (rev 56916)
+++ trunk/Master/texmf-dist/doc/latex/bookcover/README 2020-11-12 21:39:03 UTC (rev 56917)
@@ -1,4 +1,4 @@
-bookcover class, 2015- by Tibor Tomacs
+bookcover class, 2015-2020 by Tibor Tomacs
This class helps typesetting book covers and dust jackets.
@@ -16,6 +16,6 @@
- Run 'latex bookcover.ins' for bookcover.cls
- Run 'pdflatex bookcover-example1.tex' for bookcover-example1.pdf
- Run 'pdflatex bookcover-example2.tex' for bookcover-example2.pdf
- - Run three times 'pdflatex bookcover.dtx' for bookcover.pdf
+ - Run twice 'pdflatex bookcover.dtx' for bookcover.pdf
Deleted: trunk/Master/texmf-dist/doc/latex/bookcover/bookcover-example-obsoletemethod.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/bookcover/bookcover-example-obsoletemethod.tex 2020-11-12 21:38:29 UTC (rev 56916)
+++ trunk/Master/texmf-dist/doc/latex/bookcover/bookcover-example-obsoletemethod.tex 2020-11-12 21:39:03 UTC (rev 56917)
@@ -1,82 +0,0 @@
-\documentclass[spinewidth=25mm,coverwidth=15cm,coverheight=20cm,flapwidth=6cm]{bookcover}
-\usepackage[outline]{contour}
-\usepackage{lipsum}
-\contourlength{1pt}
-\definecolor{lightbrown}{RGB}{176,88,0}
-\colorlet{title}{yellow!60!black}
-
-\begin{document}
-
-% Black background color on the whole cover
-\setbookcover{bgcolor}{whole}{color=black}
-
-% Brown background picture on the whole cover, without the flaps
-\setbookcover{bgpic}{whole without flaps}{./figures/bg.jpg}
-
-% Vertical light brown transparent trails on the back cover by a tikz code
-\setbookcover{bgtikz}{back}{
- \fill[opacity=0.3,color=lightbrown]
- (0mm,0mm) rectangle (20mm,210mm) (100mm,0mm) rectangle (150mm,210mm);}
-
-% Vertical light brown transparent trails on the front cover by a tikz code
-\setbookcover{bgtikz}{front}{
- \fill[opacity=0.3,color=lightbrown]
- (0mm,0mm) rectangle (50mm,210mm) (130mm,0mm) rectangle (150mm,210mm);}
-
-% Remark
-\setbookcover{fgfirst}{above front}{
- \color{blue}A DUST JACKET}
-
-% Text on the front cover
-\setbookcover{fgfirst}{front}{
- \centering
- \vspace{60mm}
- \color{title}\sffamily\bfseries
- \resizebox*{50mm}{8mm}{\contour{black}{Rose Taylor}}
- \par
- \vspace{20mm}
- \resizebox*{90mm}{40mm}{\parbox{35mm}{
- \centering
- \contour{black}{PROBABILITY}\\
- \contour{black}{THEORY}\\}}}
-
-% Picture (cards.png) on the front, behind the title
-\setbookcover{fgsecond}{front}{
- \vspace{70mm}
- \centering
- \includegraphics[width=8cm]{./figures/cards.png}}
-
-% Text on the spine
-\setbookcover{fgfirst}{spine}{%
- \vfill
- \centering
- \rotatebox[origin=c]{90}{\contour{black}{%
- \color{title}\huge\sffamily\bfseries%
- Rose Taylor -- Probability Theory}}
- \vfill}
-
-% Text on the back cover
-\setbookcover{fgfirst}{back}{
- \centering
- \vspace{20mm}
- \parbox{110mm}{\color{white}\lipsum[1]}}
-
-% Text and picture (dice.png) on the front flap
-\setbookcover{fgfirst}{front flap}{
- \centering
- \vspace{20mm}
- \parbox{40mm}{\color{white}\lipsum[2]}
- \vfill
- \includegraphics[width=30mm]{./figures/dice.png}
- \vspace{10mm}}
-
-% Text on the back flap
-\setbookcover{fgfirst}{back flap}{
- \centering
- \vspace{20mm}
- \parbox{40mm}{\color{white}\lipsum[2]}}
-
-% Making the dust jucket
-\makebookcover
-
-\end{document}
\ No newline at end of file
Modified: trunk/Master/texmf-dist/doc/latex/bookcover/bookcover-example1.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/doc/latex/bookcover/bookcover-example2.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/doc/latex/bookcover/bookcover.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/source/latex/bookcover/bookcover.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/bookcover/bookcover.dtx 2020-11-12 21:38:29 UTC (rev 56916)
+++ trunk/Master/texmf-dist/source/latex/bookcover/bookcover.dtx 2020-11-12 21:39:03 UTC (rev 56917)
@@ -1,6 +1,6 @@
% \iffalse meta-comment
%
-% Copyright (C) 2015- by Tibor Tomacs
+% Copyright (C) 2015-2020 by Tibor Tomacs
%
% This file may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either version 1.2
@@ -17,11 +17,12 @@
% \iffalse
%<*driver>
\ProvidesFile{bookcover.dtx}
-\newcommand{\eifiledate}{2018/01/21}
-\newcommand{\eifilever}{v2.3}
+\newcommand{\eifiledate}{2020/11/12}
+\newcommand{\eifilever}{v2.4}
%</driver>
+%<class>
%<class>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
-%<class>\ProvidesClass{bookcover}[2018/01/21 v2.3 class for book covers and dust jackets]
+%<class>\ProvidesClass{bookcover}[2020/11/12 v2.4 class for book covers and dust jackets]
%
%<*driver>
\documentclass{ltxdoc}
@@ -130,7 +131,7 @@
%
% \section{Loading class}
% The class \texttt{bookcover} requires the services of the class \texttt{article} and the following packages:
-% \texttt{kvoptions}, \texttt{textpos}, \texttt{geometry}, \texttt{graphicx}, \texttt{calc}, \texttt{ifthen}, \texttt{tikz}, \texttt{fgruler}.
+% \texttt{kvoptions}, \texttt{geometry}, \texttt{graphicx}, \texttt{calc}, \texttt{ifthen}, \texttt{tikz}, \texttt{fgruler}.
%
% \medskip\noindent
% Load the class as usual, with
@@ -285,7 +286,7 @@
% \begin{commandlst}
% \bookcovercomponent{tikz}{!<part>!}{!<tikz code>!}
% \end{commandlst}
-% The origin of the Ti\emph{k}Z figure is the lower left corner of the \meta{part}. Two rectangle nodes come into being: \commandinline{part} and \commandinline{trimmed part}. (Thank Zunbeltz Izaola for the idea.)
+% The origin of the Ti\emph{k}Z figure is the lower left corner of the \meta{part}. Two rectangle nodes come into being: \commandinline{part} and \commandinline{trimmed part}. (Thanks to Zunbeltz Izaola for the idea.)
%
% \bigskip\noindent\example
% \begin{examplelst}
@@ -514,17 +515,12 @@
% \end{document}
% \end{examplelst}
%
-% \noindent You can compile this file with \texttt{latex.exe} or \texttt{xelatex.exe}. Using \texttt{pdflatex.exe} or \texttt{lualatex.exe}, write the following code into the preamble:
+% \noindent You can compile this file with \texttt{latex} or \texttt{xelatex}. Using \texttt{pdflatex} or \texttt{lualatex}, write the following code into the preamble:
% \begin{examplelst}
% \usepackage[pdfcrop={-hires}]{auto-pst-pdf}
% \end{examplelst}
-% In this case, the command to compile this file is the following:
+% In this case, the \texttt{pdflatex} or \texttt{lualatex} must be called with the \texttt{-shell-escape} option.
%
-% \medskip\texttt{pdflatex -shell-escape filename}\\
-% or
-%
-% \texttt{lualatex -shell-escape filename}
-%
% \bigskip
% \begin{center}
% \setlength{\fboxsep}{0pt}\setlength{\fboxrule}{.4pt}
@@ -531,115 +527,12 @@
% \fcolorbox{black!50}{white}{\includegraphics[width=\textwidth-.8pt]{figures/barcode}}
% \end{center}
%
-% \newpage\section{Obsolete method}
-%
-% {\large\bfseries\color{red}The goal of the \emph{obsolete method} is to be compatible with the early versions of the \texttt{bookcover}. It is not recommended to use it in the future, because the method described in the Section~\begin{NoHyper}\ref{sec:mainmethod}\end{NoHyper} is much more flexible!\par}
-%
-% \subsection{Commands}
-%
-% \textbf{Background colors}
-% \begin{commandlst}
-% \setbookcover{bgcolor}{!<background part>!}{!<colors>!}
-% \end{commandlst}
-% See the \meta{background part} in Subsubsection \ref{subsubsec:background} and the \meta{colors} in the page \pageref{page:color}.
-%
-% \bigskip\noindent\textbf{Background pictures}
-% \begin{commandlst}
-% \setbookcover{bgpic}{!<background part>!}{!<picture file>!}
-% \end{commandlst}
-% See the \meta{background part} in Subsubsection \ref{subsubsec:background}. The picture will be rescaled according to the sizes of the current background part.
-%
-% \bigskip\noindent\textbf{Background Ti\emph{k}Z figures}
-% \begin{commandlst}
-% \setbookcover{bgtikz}{!<background part>!}{!<tikz code>!}
-% \end{commandlst}
-% See the \meta{background part} in Subsubsection \ref{subsubsec:background}. The Ti\emph{k}Z figure will be placed to the upper left corner of the current background part, without resizing.
-% Using the option \texttt{bgtikznodes} of the document class:
-%
-% \begin{itemize}
-% \item the origin moves to the lower left corner of the current background part;
-% \item two rectangle nodes come into being: \commandinline{part} and \commandinline{trimmed part}.
-% \end{itemize}
-%
-% \noindent The option \texttt{bgtikzclip} of the document class works the same as \texttt{bgtikznodes}, but it clips the current part.
-%
-% \bigskip\noindent\textbf{First foreground}
-% \begin{commandlst}
-% \setbookcover{fgfirst}{!<foreground part>!}{!<content>!}
-% \end{commandlst}
-% See the \meta{foreground part} in Subsubsection \ref{subsubsec:foreground}. The first foreground is the top layer of the book cover (see Subsection \ref{subsec:layers}).
-%
-% \bigskip\noindent\textbf{Second foreground}
-% \begin{commandlst}
-% \setbookcover{fgsecond}{!<foreground part>!}{!<content>!}
-% \end{commandlst}
-% See the \meta{foreground part} in Subsubsection \ref{subsubsec:foreground}. The second foreground is under the first foreground (see Subsection \ref{subsec:layers}).
-%
-% \bigskip\noindent\textbf{Making book cover}
-% \begin{commandlst}
-% \makebookcover
-% \end{commandlst}
-% This command makes the book cover by using the contents of the background and foreground.
-%
-% \subsection{Parts in the obsolete method}
-% \subsubsection{Background parts}\label{subsubsec:background}
-% \begin{center}
-% \textbf{With flaps}\\*[0pt]
-% \includegraphics{figures/background1}\\[2mm]
-% \includegraphics{figures/background2}\\[2mm]
-% \includegraphics{figures/background3}
-% \end{center}
-% \begin{center}
-% \textbf{Without flaps}\\*[0pt]
-% \includegraphics{figures/background4}\\[2mm]
-% \includegraphics{figures/background5}
-% \end{center}
-%
-% \subsubsection{Foreground parts}\label{subsubsec:foreground}
-% \begin{center}
-% \textbf{With flaps}\\*[0pt]
-% \includegraphics{figures/foreground1}
-% \end{center}
-% \begin{center}
-% \textbf{Without flaps}\\*[0pt]
-% \includegraphics{figures/foreground2}
-% \end{center}
-% The other name of \texttt{above front} is \texttt{remark}.
-%
-% \subsection{Layers}\label{subsec:layers}
-% In the following table we can see the hierarchy of the layers:
-% \begin{center}
-% \begin{tabular}{@{}ll@{}c@{}}
-% \cline{1-2}
-% \multirow{2}*{|fgfirst|} & |above front|, |below front|, |above back|, |below back|& \color{layer}top layer\\
-% & |back|, |front|, |spine|, |front flap|, |back flap| &\color{layer}$\uparrow$\\
-% \cline{1-2}
-% |fgsecond| & |back|, |front|, |spine|, |front flap|, |back flap|&\color{layer}$\uparrow$\\
-% \cline{1-2}
-% & |back|, |front|, |spine|, |front flap|, |back flap| &\color{layer}$\uparrow$\\
-% |bgtikz| & |whole without flaps| &\color{layer}$\uparrow$\\
-% & |whole| &\color{layer}$\uparrow$\\
-% \cline{1-2}
-% & |back|, |front|, |spine|, |front flap|, |back flap| &\color{layer}$\uparrow$\\
-% |bgpic| & |whole without flaps| &\color{layer}$\uparrow$\\
-% & |whole| &\color{layer}$\uparrow$\\
-% \cline{1-2}
-% & |back|, |front|, |spine|, |front flap|, |back flap| &\color{layer}$\uparrow$\\
-% |bgcolor| & |whole without flaps| &\color{layer}$\uparrow$\\
-% & |whole| & \color{layer}bottom layer\\
-% \cline{1-2}
-% \end{tabular}
-% \end{center}
-%
-% \subsection{Example}
-% See the figure in the page \pageref{page:example1}.
-% \lstinputlisting[style=examplefile]{bookcover-example-obsoletemethod.tex}
-%
% \StopEventually{}
%
% \begin{macrocode}
-%%
+
%% OPTIONS
+
\RequirePackage{kvoptions}
\SetupKeyvalOptions{family=bookcover,prefix=bookcover@}
\DeclareVoidOption{10pt}{\PassOptionsToClass{10pt}{article}}
@@ -654,28 +547,24 @@
\DeclareStringOption[5mm]{bleedwidth}
\DeclareStringOption[red]{markcolor}
\DeclareBoolOption[false]{trimmed}
-\DeclareBoolOption[false]{bgtikznodes}% for obsolete method
-\DeclareBoolOption[false]{bgtikzclip}% for obsolete method
\ProcessKeyvalOptions{bookcover}
-\ifbookcover at bgtikzclip\bookcover at bgtikznodestrue\fi% for obsolete method
%% CLASS AND PACKAGES
-%%
-%% Don't use 'absolute' option of 'textpos'! It causes problems in some cases:
-%% xelatex.exe + pst-barcode
-%% pdflatex.exe or lualatex.exe + pst-barcode + auto-pst-pdf
-%%
+
\LoadClass{article}
-\RequirePackage{textpos,geometry,graphicx,calc,ifthen,tikz}
+\RequirePackage{geometry,graphicx,calc,ifthen,tikz}
\RequirePackage[nonefgrulers]{fgruler}
%% PAGE STYLE
+
\pagestyle{empty}
%% NEW IF
+
\newif\if at inbookcoverenv
%% USER LENGTHS
+
\newlength{\coverwidth}
\newlength{\coverheight}
\newlength{\spinewidth}
@@ -685,6 +574,8 @@
\newlength{\bleedwidth}
%% INTERNAL LENGTHS
+
+\newlength{\bookcover at templength@}
\newlength{\bookcover at xpos@}
\newlength{\bookcover at ypos@}
\newlength{\bookcover at partwidth@}
@@ -699,6 +590,7 @@
\let\partwidth\bookcover at partwidth@
%% USER LENGTHS SETTING
+
\setlength{\coverwidth}{\bookcover at coverwidth}
\setlength{\coverheight}{\bookcover at coverheight}
\setlength{\spinewidth}{\bookcover at spinewidth}
@@ -708,14 +600,18 @@
\setlength{\bleedwidth}{\bookcover at bleedwidth}
%% PAGE DIMENSIONS SETTING
-\geometry{left=0pt,right=0pt,bottom=0pt,top=-1em,
- paperwidth=2\marklength+2\bleedwidth+2\coverwidth+2\flapwidth+\spinewidth,
- paperheight=2\marklength+2\bleedwidth+\coverheight}
+\geometry{%
+ margin=0pt,
+ paperwidth=2\marklength+2\bleedwidth+2\coverwidth+2\flapwidth+\spinewidth,
+ paperheight=2\marklength+2\bleedwidth+\coverheight}
+
%% NO PARAGRAPH INDENTATION
+
\setlength{\parindent}{0pt}
%% INTERNAL LENGTHS SETTING
+
\def\bookcover at xpos#1{\setlength{\bookcover at xpos@}{#1}}
\def\bookcover at ypos#1{\setlength{\bookcover at ypos@}{#1}}
\def\bookcover at partwidth#1{\setlength{\bookcover at partwidth@}{#1}}
@@ -722,11 +618,9 @@
\def\bookcover at partheight#1{\setlength{\bookcover at partheight@}{#1}}
\def\bookcover at tikz@trimmed at part@param#1#2#3#4{%
\setlength{\bookcover at tikz@trimmed at part@width at minus}{#1}%
- \setlength{\bookcover at tikz@trimmed at part@height at minus}{#2}
- \setlength{\bookcover at tikz@trimmed at part@push at right}{#3}
+ \setlength{\bookcover at tikz@trimmed at part@height at minus}{#2}%
+ \setlength{\bookcover at tikz@trimmed at part@push at right}{#3}%
\setlength{\bookcover at tikz@trimmed at part@push at up}{#4}}
-\def\bookcover at bgtikz@trimmed at part@param#1#2{
- \bookcover at tikz@trimmed at part@param{#1}{2\bleedwidth}{#2}{\bleedwidth}}% for obsolete method
\let\setpartposx\bookcover at xpos
\let\setpartposy\bookcover at ypos
\let\setpartwidth\bookcover at partwidth
@@ -733,17 +627,22 @@
\let\setpartheight\bookcover at partheight
\let\settrimmedpart\bookcover at tikz@trimmed at part@param
+%% POSBOX
+
+\newcommand{\bookcover at posbox}[4]{%
+ \setlength{\bookcover at templength@}{#3}%
+ \put(#2,-\bookcover at templength@){\parbox[b][0pt][t]{#1}{#4}}}
+
%% MARKS
-\def\bookcover at vmark{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- {\color{\bookcover at markcolor}\rule[0pt]{\markthick}{\marklength}}
- \end{textblock*}}
-\def\bookcover at hmark{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- {\color{\bookcover at markcolor}\rule[0pt]{\marklength}{\markthick}}
- \end{textblock*}}
+\def\bookcover at vmark{%
+ \bookcover at posbox{\bookcover at partwidth@}{\bookcover at xpos@}{\bookcover at ypos@}{%
+ {\color{\bookcover at markcolor}\rule[0pt]{\markthick}{\marklength}}}}
+\def\bookcover at hmark{%
+ \bookcover at posbox{\bookcover at partwidth@}{\bookcover at xpos@}{\bookcover at ypos@}{%
+ {\color{\bookcover at markcolor}\rule[0pt]{\marklength}{\markthick}}}}
+
\def\bookcover at marks{
\bookcover at ypos{0mm}
\bookcover at partwidth{\markthick}
@@ -791,8 +690,9 @@
\bookcover at hmark}
%% TRIMMING
-\def\bookcover at trimming{
- \begin{textblock*}{\paperwidth}(0mm,0mm)
+
+\def\bookcover at trimming{%
+ \bookcover at posbox{\paperwidth}{0mm}{0mm}{%
\begin{tikzpicture}
\begin{scope}[color=white]
\fill(0,0)--
@@ -817,8 +717,7 @@
(\paperwidth-\marklength-\bleedwidth,\marklength+\bleedwidth)--
(\paperwidth-\marklength-\bleedwidth,\paperheight-\marklength-\bleedwidth)--
(\marklength+\bleedwidth,\paperheight-\marklength-\bleedwidth)--cycle;
- \end{tikzpicture}
- \end{textblock*}
+ \end{tikzpicture}}
\bookcover at ypos{\bleedwidth}
\bookcover at partwidth{\markthick}
\ifdim\flapwidth>0mm
@@ -842,7 +741,21 @@
\bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth-.5\markthick}
\bookcover at vmark}
+%% BOOKCOVER ENVIRONMENT
+
+\def\bookcover{%
+ \@inbookcoverenvtrue%
+ \newpage%
+ \begin{picture}(\paperwidth,\paperheight)(0,-\paperheight)}
+
+\def\endbookcover{%
+ \bookcover at marks%
+ \ifbookcover at trimmed\bookcover at trimming\fi%
+ \end{picture}%
+ \@inbookcoverenvfalse}
+
%% BOOKCOVER COMPONENT
+
\long\def\bookcovercomponent#1#2#3{
\if at inbookcoverenv\else
\@latexerr{\string\bookcovercomponent\space is not in 'bookcover' environment.}{}\fi
@@ -859,14 +772,8 @@
\ifdim\bookcover at partheight@>0mm
\csname bookcover at componenttype@#1\endcsname{#3}\fi\fi\fi}}}
-%% BOOKCOVER ENVIRONMENT
-\def\bookcover{\@inbookcoverenvtrue}
-\def\endbookcover{
- \bookcover at marks
- \ifbookcover at trimmed\bookcover at trimming\fi
- \mbox{}\newpage\@inbookcoverenvfalse}
+%% NEW BOOKCOVER PART
-%% NEW BOOKCOVER PART
\def\newbookcoverpart#1#2{
\@ifundefined{bookcover at part@param@#1}{
\expandafter\def\csname bookcover at part@param@#1\endcsname{#2}}
@@ -873,11 +780,13 @@
{\@latexerr{Part '#1' already defined.}{}}}
%% RENEW BOOKCOVER PART
+
\def\renewbookcoverpart#1#2{
\@ifundefined{bookcover at part@param@#1}{\@latexerr{Part '#1' undefined.}{}}{
\expandafter\def\csname bookcover at part@param@#1\endcsname{#2}}}
%% NEW NAME BOOKCOVER PART
+
\def\newnamebookcoverpart#1#2{
\@ifundefined{bookcover at part@param@#1}{
\@ifundefined{bookcover at part@param@#2}{\@latexerr{Part '#2' undefined.}{}}{
@@ -886,23 +795,22 @@
{\@latexerr{Part '#1' already defined.}{}}}
%% NEW BOOKCOVER COMPONENT TYPE
-\def\newbookcovercomponenttype#1#2{
- \@ifundefined{bookcover at componenttype@#1}{
- \long\expandafter\def\csname bookcover at componenttype@#1\endcsname##1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- #2
- \end{textblock*}}}
+
+\def\newbookcovercomponenttype#1#2{%
+ \@ifundefined{bookcover at componenttype@#1}{%
+ \long\expandafter\def\csname bookcover at componenttype@#1\endcsname##1{%
+ \bookcover at posbox{\bookcover at partwidth@}{\bookcover at xpos@}{\bookcover at ypos@}{#2}}}
{\@latexerr{Component type '#1' already defined.}{}}}
%% RENEW BOOKCOVER COMPONENT TYPE
-\def\renewbookcovercomponenttype#1#2{
- \@ifundefined{bookcover at componenttype@#1}{\@latex at error{Component type '#1' undefined.}{}}{
- \long\expandafter\def\csname bookcover at componenttype@#1\endcsname##1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- #2
- \end{textblock*}}}}
+\def\renewbookcovercomponenttype#1#2{%
+ \@ifundefined{bookcover at componenttype@#1}{\@latex at error{Component type '#1' undefined.}{}}{%
+ \long\expandafter\def\csname bookcover at componenttype@#1\endcsname##1{%
+ \bookcover at posbox{\bookcover at partwidth@}{\bookcover at xpos@}{\bookcover at ypos@}{#2}}}}
+
%% NEW NAME BOOKCOVER COMPONENT TYPE
+
\def\newnamebookcovercomponenttype#1#2{
\@ifundefined{bookcover at componenttype@#1}{
\@ifundefined{bookcover at componenttype@#2}{\@latexerr{Component type '#2' undefined.}{}}{
@@ -911,6 +819,7 @@
{\@latexerr{Component type '#1' already defined.}{}}}
%% COMPONENT TYPES
+
\newbookcovercomponenttype{color}{
\tikz\fill[#1] (0,0) rectangle (\bookcover at partwidth@,\bookcover at partheight@);}
@@ -973,6 +882,7 @@
\squareruler[#1]{lowerright}{\bookcover at rulerwidth@}{\bookcover at rulerheight@}}{}}
%% BOOKCOVER PARTS
+
\newbookcoverpart{bg back flap}{
\ifdim\flapwidth>0mm
\bookcover at ypos{\marklength}
@@ -1236,379 +1146,6 @@
\bookcover at xpos{\marklength+\bleedwidth}
\bookcover at partwidth{2\coverwidth+2\flapwidth+\spinewidth}}
-%%%%%%%%%%%%%%%%%%%%%
-%% OBSOLETE METHOD %%
-%%%%%%%%%%%%%%%%%%%%%
-
-%% MAIN LAYERS
-\def\bookcover at bgcolor#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \tikz\fill\expandafter[#1] (0,0) rectangle (\bookcover at partwidth@,\bookcover at partheight@);
- \end{textblock*}}
-
-\def\bookcover at bgpic#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \includegraphics[width=\bookcover at partwidth@,height=\bookcover at partheight@]{#1}
- \end{textblock*}}
-
-\def\bookcover at bgtikz#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \ifbookcover at bgtikznodes
- \begin{tikzpicture}[overlay,yshift=-\bookcover at partheight@]
- \begin{scope}[transparent,line width=0pt]
- \pgfset{minimum width=\bookcover at partwidth@,minimum height=\bookcover at partheight@}
- \pgfnode{rectangle}{south west}{}{current part}{\pgfusepath{draw}}% for v1.1.1
- \pgfnode{rectangle}{south west}{}{part}{\pgfusepath{draw}}
- \pgfset{minimum width=\bookcover at partwidth@-\bookcover at tikz@trimmed at part@width at minus,
- minimum height=\bookcover at partheight@-\bookcover at tikz@trimmed at part@height at minus}
- \pgftransformshift{\pgfpoint{\bookcover at tikz@trimmed at part@push at right}
- {\bookcover at tikz@trimmed at part@push at up}}
- \pgfnode{rectangle}{south west}{}{current trimmed part}{\pgfusepath{draw}}% for v1.1.1
- \pgfnode{rectangle}{south west}{}{trimmed part}{\pgfusepath{draw}}
- \end{scope}
- \ifbookcover at bgtikzclip
- \clip (part.south west) rectangle (part.north east);\fi
- \else\begin{tikzpicture}\fi
- #1
- \end{tikzpicture}
- \end{textblock*}}
-
-\def\bookcover at fg#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \parbox[t][\bookcover at partheight@][t]{\bookcover at partwidth@}{#1}
- \end{textblock*}}
-
-\def\bookcover at remark#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \parbox[t][\bookcover at partheight@][c]{\bookcover at partwidth@}{\begin{center}#1\end{center}}
- \end{textblock*}}
-
-%% RESET DATAS
-\def\bookcover at reset{
- \def\bookcover at bgcolor@whole{}
- \def\bookcover at bgcolor@wholewf{}
- \def\bookcover at bgcolor@back{}
- \def\bookcover at bgcolor@front{}
- \def\bookcover at bgcolor@backflap{}
- \def\bookcover at bgcolor@frontflap{}
- \def\bookcover at bgcolor@spine{}
- \def\bookcover at bgpic@whole{}
- \def\bookcover at bgpic@wholewf{}
- \def\bookcover at bgpic@back{}
- \def\bookcover at bgpic@front{}
- \def\bookcover at bgpic@backflap{}
- \def\bookcover at bgpic@frontflap{}
- \def\bookcover at bgpic@spine{}
- \def\bookcover at bgtikz@whole{}
- \def\bookcover at bgtikz@wholewf{}
- \def\bookcover at bgtikz@back{}
- \def\bookcover at bgtikz@front{}
- \def\bookcover at bgtikz@backflap{}
- \def\bookcover at bgtikz@frontflap{}
- \def\bookcover at bgtikz@spine{}
- \def\bookcover at fgfirst@back{}
- \def\bookcover at fgfirst@front{}
- \def\bookcover at fgfirst@spine{}
- \def\bookcover at fgfirst@backflap{}
- \def\bookcover at fgfirst@frontflap{}
- \def\bookcover at fgfirst@abovefront{}
- \def\bookcover at fgfirst@belowfront{}
- \def\bookcover at fgfirst@aboveback{}
- \def\bookcover at fgfirst@belowback{}
- \def\bookcover at fgsecond@back{}
- \def\bookcover at fgsecond@front{}
- \def\bookcover at fgsecond@spine{}
- \def\bookcover at fgsecond@backflap{}
- \def\bookcover at fgsecond@frontflap{}}
-\bookcover at reset
-
-%% SET BOOKCOVER
-\long\def\setbookcover#1#2#3{
- \ifthenelse{\equal{#1}{bgcolor}}{
- \ifthenelse{\equal{#2}{whole}}{\def\bookcover at bgcolor@whole{#3}}{}
- \ifthenelse{\equal{#2}{whole without flaps}}{\def\bookcover at bgcolor@wholewf{#3}}{}
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at bgcolor@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at bgcolor@front{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at bgcolor@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at bgcolor@frontflap{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at bgcolor@spine{#3}}{}}{}
- \ifthenelse{\equal{#1}{bgpic}}{
- \ifthenelse{\equal{#2}{whole}}{\def\bookcover at bgpic@whole{#3}}{}
- \ifthenelse{\equal{#2}{whole without flaps}}{\def\bookcover at bgpic@wholewf{#3}}{}
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at bgpic@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at bgpic@front{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at bgpic@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at bgpic@frontflap{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at bgpic@spine{#3}}{}}{}
- \ifthenelse{\equal{#1}{bgtikz}}{
- \ifthenelse{\equal{#2}{whole}}{\def\bookcover at bgtikz@whole{#3}}{}
- \ifthenelse{\equal{#2}{whole without flaps}}{\def\bookcover at bgtikz@wholewf{#3}}{}
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at bgtikz@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at bgtikz@front{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at bgtikz@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at bgtikz@frontflap{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at bgtikz@spine{#3}}{}}{}
- \ifthenelse{\equal{#1}{fgfirst}}{
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at fgfirst@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at fgfirst@front{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at fgfirst@spine{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at fgfirst@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at fgfirst@frontflap{#3}}{}
- \ifthenelse{\equal{#2}{remark}}{\def\bookcover at fgfirst@abovefront{#3}}{}% for v1.0
- \ifthenelse{\equal{#2}{above front}}{\def\bookcover at fgfirst@abovefront{#3}}{}
- \ifthenelse{\equal{#2}{below front}}{\def\bookcover at fgfirst@belowfront{#3}}{}
- \ifthenelse{\equal{#2}{above back}}{\def\bookcover at fgfirst@aboveback{#3}}{}
- \ifthenelse{\equal{#2}{below back}}{\def\bookcover at fgfirst@belowback{#3}}{}}{}
- \ifthenelse{\equal{#1}{fgsecond}}{
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at fgsecond@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at fgsecond@front{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at fgsecond@spine{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at fgsecond@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at fgsecond@frontflap{#3}}{}}{}}
-
-%% MAKE BOOKCOVER
-\def\makebookcover{
-%% background parameters
-\bookcover at ypos{\marklength}
-\bookcover at partheight{\coverheight+2\bleedwidth}
-%% {bgcolor}{whole}
-\ifx\bookcover at bgcolor@whole\@empty\else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+2\flapwidth+\spinewidth}
- \bookcover at bgcolor{\bookcover at bgcolor@whole}\fi
-%% {bgcolor}{whole without flaps}
-\ifx\bookcover at bgcolor@wholewf\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{2\coverwidth+\spinewidth}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+\spinewidth}\fi
- \bookcover at bgcolor{\bookcover at bgcolor@wholewf}\fi
-%% {bgcolor}{back flap}
-\ifx\bookcover at bgcolor@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgcolor{\bookcover at bgcolor@backflap}\fi\fi
-%% {bgcolor}{back}
-\ifx\bookcover at bgcolor@back\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\coverwidth+\bleedwidth}\fi
- \bookcover at bgcolor{\bookcover at bgcolor@back}\fi
-%% {bgcolor}{spine}
-\ifx\bookcover at bgcolor@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at bgcolor{\bookcover at bgcolor@spine}\fi
-%% {bgcolor}{front}
-\ifx\bookcover at bgcolor@front\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \else
- \bookcover at xpos{\marklength+\bleedwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth+\bleedwidth}\fi
- \bookcover at bgcolor{\bookcover at bgcolor@front}\fi
-%% {bgcolor}{front flap}
-\ifx\bookcover at bgcolor@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgcolor{\bookcover at bgcolor@frontflap}\fi\fi
-%% {bgpic}{whole}
-\ifx\bookcover at bgpic@whole\@empty\else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+2\flapwidth+\spinewidth}
- \bookcover at bgpic{\bookcover at bgpic@whole}\fi
-%% {bgpic}{whole without flaps}
-\ifx\bookcover at bgpic@wholewf\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{2\coverwidth+\spinewidth}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+\spinewidth}\fi
- \bookcover at bgpic{\bookcover at bgpic@wholewf}\fi
-%% {bgpic}{back flap}
-\ifx\bookcover at bgpic@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgpic{\bookcover at bgpic@backflap}\fi\fi
-%% {bgpic}{back}
-\ifx\bookcover at bgpic@back\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\coverwidth+\bleedwidth}\fi
- \bookcover at bgpic{\bookcover at bgpic@back}\fi
-%% {bgpic}{spine}
-\ifx\bookcover at bgpic@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at bgpic{\bookcover at bgpic@spine}\fi
-%% {bgpic}{front}
-\ifx\bookcover at bgpic@front\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \else
- \bookcover at xpos{\marklength+\bleedwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth+\bleedwidth}\fi
- \bookcover at bgpic{\bookcover at bgpic@front}\fi
-%% {bgpic}{front flap}
-\ifx\bookcover at bgpic@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgpic{\bookcover at bgpic@frontflap}\fi\fi
-%% {bgtikz}{whole}
-\ifx\bookcover at bgtikz@whole\@empty\else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+2\flapwidth+\spinewidth}
- \bookcover at bgtikz@trimmed at part@param{2\bleedwidth}{\bleedwidth}
- \bookcover at bgtikz{\bookcover at bgtikz@whole}\fi
-%% {bgtikz}{whole without flaps}
-\ifx\bookcover at bgtikz@wholewf\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{2\coverwidth+\spinewidth}
- \bookcover at bgtikz@trimmed at part@param{0pt}{0pt}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+\spinewidth}
- \bookcover at bgtikz@trimmed at part@param{2\bleedwidth}{\bleedwidth}\fi
- \bookcover at bgtikz{\bookcover at bgtikz@wholewf}\fi
-%% {bgtikz}{back flap}
-\ifx\bookcover at bgtikz@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgtikz@trimmed at part@param{\bleedwidth}{\bleedwidth}
- \bookcover at bgtikz{\bookcover at bgtikz@backflap}\fi\fi
-%% {bgtikz}{back}
-\ifx\bookcover at bgtikz@back\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at bgtikz@trimmed at part@param{0pt}{0pt}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\coverwidth+\bleedwidth}
- \bookcover at bgtikz@trimmed at part@param{\bleedwidth}{\bleedwidth}\fi
- \bookcover at bgtikz{\bookcover at bgtikz@back}\fi
-%% {bgtikz}{spine}
-\ifx\bookcover at bgtikz@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at bgtikz@trimmed at part@param{0pt}{0pt}
- \bookcover at bgtikz{\bookcover at bgtikz@spine}\fi
-%% {bgtikz}{front}
-\ifx\bookcover at bgtikz@front\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at bgtikz@trimmed at part@param{0pt}{0pt}
- \else
- \bookcover at xpos{\marklength+\bleedwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth+\bleedwidth}
- \bookcover at bgtikz@trimmed at part@param{\bleedwidth}{0pt}\fi
- \bookcover at bgtikz{\bookcover at bgtikz@front}\fi
-%% {bgtikz}{front flap}
-\ifx\bookcover at bgtikz@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgtikz@trimmed at part@param{\bleedwidth}{0pt}
- \bookcover at bgtikz{\bookcover at bgtikz@frontflap}\fi\fi
-%% foreground parameters
-\bookcover at ypos{\marklength+\bleedwidth}
-\bookcover at partheight{\coverheight}
-%% {fgsecond}{back flap}
-\ifx\bookcover at fgsecond@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth}
- \bookcover at partwidth{\flapwidth}
- \bookcover at fg{\bookcover at fgsecond@backflap}\fi\fi
-%% {fgsecond}{back}
-\ifx\bookcover at fgsecond@back\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at fg{\bookcover at fgsecond@back}\fi
-%% {fgsecond}{spine}
-\ifx\bookcover at fgsecond@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at fg{\bookcover at fgsecond@spine}\fi
-%% {fgsecond}{front}
-\ifx\bookcover at fgsecond@front\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at fg{\bookcover at fgsecond@front}\fi
-%% {fgsecond}{front flap}
-\ifx\bookcover at fgsecond@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth}
- \bookcover at fg{\bookcover at fgsecond@frontflap}\fi\fi
-%% {fgfirst}{back flap}
-\ifx\bookcover at fgfirst@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth}
- \bookcover at partwidth{\flapwidth}
- \bookcover at fg{\bookcover at fgfirst@backflap}\fi\fi
-%% {fgfirst}{back}
-\ifx\bookcover at fgfirst@back\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at fg{\bookcover at fgfirst@back}\fi
-%% {fgfirst}{spine}
-\ifx\bookcover at fgfirst@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at fg{\bookcover at fgfirst@spine}\fi
-%% {fgfirst}{front}
-\ifx\bookcover at fgfirst@front\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at fg{\bookcover at fgfirst@front}\fi
-%% {fgfirst}{front flap}
-\ifx\bookcover at fgfirst@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth}
- \bookcover at fg{\bookcover at fgfirst@frontflap}\fi\fi
-%% {fgfirst}{above front} = {fgfirst}{remark} in v1.0
-\ifx\bookcover at fgfirst@abovefront\@empty\else\ifdim\marklength>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at ypos{0mm}
- \bookcover at partwidth{\coverwidth}
- \bookcover at partheight{\marklength}
- \bookcover at remark{\bookcover at fgfirst@abovefront}\fi\fi
-%% {fgfirst}{below front}
-\ifx\bookcover at fgfirst@belowfront\@empty\else\ifdim\marklength>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at ypos{\marklength+2\bleedwidth+\coverheight}
- \bookcover at partwidth{\coverwidth}
- \bookcover at partheight{\marklength}
- \bookcover at remark{\bookcover at fgfirst@belowfront}\fi\fi
-%% {fgfirst}{above back}
-\ifx\bookcover at fgfirst@aboveback\@empty\else\ifdim\marklength>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at ypos{0mm}
- \bookcover at partwidth{\coverwidth}
- \bookcover at partheight{\marklength}
- \bookcover at remark{\bookcover at fgfirst@aboveback}\fi\fi
-%% {fgfirst}{below back}
-\ifx\bookcover at fgfirst@belowback\@empty\else\ifdim\marklength>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at ypos{\marklength+2\bleedwidth+\coverheight}
- \bookcover at partwidth{\coverwidth}
- \bookcover at partheight{\marklength}
- \bookcover at remark{\bookcover at fgfirst@belowback}\fi\fi
-%% marks
-\bookcover at marks
-%% trimming
-\ifbookcover at trimmed\bookcover at trimming\fi
-%% new book cover
-\mbox{}\newpage\bookcover at reset}
% \end{macrocode}
% \Finale
\endinput
\ No newline at end of file
Modified: trunk/Master/texmf-dist/source/latex/bookcover/bookcover.ins
===================================================================
--- trunk/Master/texmf-dist/source/latex/bookcover/bookcover.ins 2020-11-12 21:38:29 UTC (rev 56916)
+++ trunk/Master/texmf-dist/source/latex/bookcover/bookcover.ins 2020-11-12 21:39:03 UTC (rev 56917)
@@ -1,5 +1,5 @@
-% Copyright (C) 2015- Tibor Tomacs
+% Copyright (C) 2015-2020 Tibor Tomacs
% This file may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either
% version 1.2 of this license or (at your option) any later
@@ -15,7 +15,7 @@
\usedir{tex/latex/bookcover}
\preamble
This is a generated file.
-Copyright (C) 2015- Tibor Tomacs
+Copyright (C) 2015-2020 Tibor Tomacs
This file may be distributed and/or modified under the
conditions of the LaTeX Project Public License, either
version 1.2 of this license or (at your option) any later
Modified: trunk/Master/texmf-dist/tex/latex/bookcover/bookcover.cls
===================================================================
--- trunk/Master/texmf-dist/tex/latex/bookcover/bookcover.cls 2020-11-12 21:38:29 UTC (rev 56916)
+++ trunk/Master/texmf-dist/tex/latex/bookcover/bookcover.cls 2020-11-12 21:39:03 UTC (rev 56917)
@@ -6,7 +6,7 @@
%%
%% ./bookcover.dtx (with options: `class')
%% This is a generated file.
-%% Copyright (C) 2015- Tibor Tomacs
+%% Copyright (C) 2015-2020 Tibor Tomacs
%% This file may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
%% version 1.2 of this license or (at your option) any later
@@ -17,10 +17,12 @@
%% and version 1.2 or later is part of all distributions of
%% LaTeX version 1999/12/01 or later.
%%
+
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
-\ProvidesClass{bookcover}[2018/01/21 v2.3 class for book covers and dust jackets]
-%%
+\ProvidesClass{bookcover}[2020/11/12 v2.4 class for book covers and dust jackets]
+
%% OPTIONS
+
\RequirePackage{kvoptions}
\SetupKeyvalOptions{family=bookcover,prefix=bookcover@}
\DeclareVoidOption{10pt}{\PassOptionsToClass{10pt}{article}}
@@ -35,28 +37,24 @@
\DeclareStringOption[5mm]{bleedwidth}
\DeclareStringOption[red]{markcolor}
\DeclareBoolOption[false]{trimmed}
-\DeclareBoolOption[false]{bgtikznodes}% for obsolete method
-\DeclareBoolOption[false]{bgtikzclip}% for obsolete method
\ProcessKeyvalOptions{bookcover}
-\ifbookcover at bgtikzclip\bookcover at bgtikznodestrue\fi% for obsolete method
%% CLASS AND PACKAGES
-%%
-%% Don't use 'absolute' option of 'textpos'! It causes problems in some cases:
-%% xelatex.exe + pst-barcode
-%% pdflatex.exe or lualatex.exe + pst-barcode + auto-pst-pdf
-%%
+
\LoadClass{article}
-\RequirePackage{textpos,geometry,graphicx,calc,ifthen,tikz}
+\RequirePackage{geometry,graphicx,calc,ifthen,tikz}
\RequirePackage[nonefgrulers]{fgruler}
%% PAGE STYLE
+
\pagestyle{empty}
%% NEW IF
+
\newif\if at inbookcoverenv
%% USER LENGTHS
+
\newlength{\coverwidth}
\newlength{\coverheight}
\newlength{\spinewidth}
@@ -66,6 +64,8 @@
\newlength{\bleedwidth}
%% INTERNAL LENGTHS
+
+\newlength{\bookcover at templength@}
\newlength{\bookcover at xpos@}
\newlength{\bookcover at ypos@}
\newlength{\bookcover at partwidth@}
@@ -80,6 +80,7 @@
\let\partwidth\bookcover at partwidth@
%% USER LENGTHS SETTING
+
\setlength{\coverwidth}{\bookcover at coverwidth}
\setlength{\coverheight}{\bookcover at coverheight}
\setlength{\spinewidth}{\bookcover at spinewidth}
@@ -89,14 +90,18 @@
\setlength{\bleedwidth}{\bookcover at bleedwidth}
%% PAGE DIMENSIONS SETTING
-\geometry{left=0pt,right=0pt,bottom=0pt,top=-1em,
- paperwidth=2\marklength+2\bleedwidth+2\coverwidth+2\flapwidth+\spinewidth,
- paperheight=2\marklength+2\bleedwidth+\coverheight}
+\geometry{%
+ margin=0pt,
+ paperwidth=2\marklength+2\bleedwidth+2\coverwidth+2\flapwidth+\spinewidth,
+ paperheight=2\marklength+2\bleedwidth+\coverheight}
+
%% NO PARAGRAPH INDENTATION
+
\setlength{\parindent}{0pt}
%% INTERNAL LENGTHS SETTING
+
\def\bookcover at xpos#1{\setlength{\bookcover at xpos@}{#1}}
\def\bookcover at ypos#1{\setlength{\bookcover at ypos@}{#1}}
\def\bookcover at partwidth#1{\setlength{\bookcover at partwidth@}{#1}}
@@ -103,11 +108,9 @@
\def\bookcover at partheight#1{\setlength{\bookcover at partheight@}{#1}}
\def\bookcover at tikz@trimmed at part@param#1#2#3#4{%
\setlength{\bookcover at tikz@trimmed at part@width at minus}{#1}%
- \setlength{\bookcover at tikz@trimmed at part@height at minus}{#2}
- \setlength{\bookcover at tikz@trimmed at part@push at right}{#3}
+ \setlength{\bookcover at tikz@trimmed at part@height at minus}{#2}%
+ \setlength{\bookcover at tikz@trimmed at part@push at right}{#3}%
\setlength{\bookcover at tikz@trimmed at part@push at up}{#4}}
-\def\bookcover at bgtikz@trimmed at part@param#1#2{
- \bookcover at tikz@trimmed at part@param{#1}{2\bleedwidth}{#2}{\bleedwidth}}% for obsolete method
\let\setpartposx\bookcover at xpos
\let\setpartposy\bookcover at ypos
\let\setpartwidth\bookcover at partwidth
@@ -114,17 +117,22 @@
\let\setpartheight\bookcover at partheight
\let\settrimmedpart\bookcover at tikz@trimmed at part@param
+%% POSBOX
+
+\newcommand{\bookcover at posbox}[4]{%
+ \setlength{\bookcover at templength@}{#3}%
+ \put(#2,-\bookcover at templength@){\parbox[b][0pt][t]{#1}{#4}}}
+
%% MARKS
-\def\bookcover at vmark{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- {\color{\bookcover at markcolor}\rule[0pt]{\markthick}{\marklength}}
- \end{textblock*}}
-\def\bookcover at hmark{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- {\color{\bookcover at markcolor}\rule[0pt]{\marklength}{\markthick}}
- \end{textblock*}}
+\def\bookcover at vmark{%
+ \bookcover at posbox{\bookcover at partwidth@}{\bookcover at xpos@}{\bookcover at ypos@}{%
+ {\color{\bookcover at markcolor}\rule[0pt]{\markthick}{\marklength}}}}
+\def\bookcover at hmark{%
+ \bookcover at posbox{\bookcover at partwidth@}{\bookcover at xpos@}{\bookcover at ypos@}{%
+ {\color{\bookcover at markcolor}\rule[0pt]{\marklength}{\markthick}}}}
+
\def\bookcover at marks{
\bookcover at ypos{0mm}
\bookcover at partwidth{\markthick}
@@ -172,8 +180,9 @@
\bookcover at hmark}
%% TRIMMING
-\def\bookcover at trimming{
- \begin{textblock*}{\paperwidth}(0mm,0mm)
+
+\def\bookcover at trimming{%
+ \bookcover at posbox{\paperwidth}{0mm}{0mm}{%
\begin{tikzpicture}
\begin{scope}[color=white]
\fill(0,0)--
@@ -198,8 +207,7 @@
(\paperwidth-\marklength-\bleedwidth,\marklength+\bleedwidth)--
(\paperwidth-\marklength-\bleedwidth,\paperheight-\marklength-\bleedwidth)--
(\marklength+\bleedwidth,\paperheight-\marklength-\bleedwidth)--cycle;
- \end{tikzpicture}
- \end{textblock*}
+ \end{tikzpicture}}
\bookcover at ypos{\bleedwidth}
\bookcover at partwidth{\markthick}
\ifdim\flapwidth>0mm
@@ -223,7 +231,21 @@
\bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth-.5\markthick}
\bookcover at vmark}
+%% BOOKCOVER ENVIRONMENT
+
+\def\bookcover{%
+ \@inbookcoverenvtrue%
+ \newpage%
+ \begin{picture}(\paperwidth,\paperheight)(0,-\paperheight)}
+
+\def\endbookcover{%
+ \bookcover at marks%
+ \ifbookcover at trimmed\bookcover at trimming\fi%
+ \end{picture}%
+ \@inbookcoverenvfalse}
+
%% BOOKCOVER COMPONENT
+
\long\def\bookcovercomponent#1#2#3{
\if at inbookcoverenv\else
\@latexerr{\string\bookcovercomponent\space is not in 'bookcover' environment.}{}\fi
@@ -240,14 +262,8 @@
\ifdim\bookcover at partheight@>0mm
\csname bookcover at componenttype@#1\endcsname{#3}\fi\fi\fi}}}
-%% BOOKCOVER ENVIRONMENT
-\def\bookcover{\@inbookcoverenvtrue}
-\def\endbookcover{
- \bookcover at marks
- \ifbookcover at trimmed\bookcover at trimming\fi
- \mbox{}\newpage\@inbookcoverenvfalse}
+%% NEW BOOKCOVER PART
-%% NEW BOOKCOVER PART
\def\newbookcoverpart#1#2{
\@ifundefined{bookcover at part@param@#1}{
\expandafter\def\csname bookcover at part@param@#1\endcsname{#2}}
@@ -254,11 +270,13 @@
{\@latexerr{Part '#1' already defined.}{}}}
%% RENEW BOOKCOVER PART
+
\def\renewbookcoverpart#1#2{
\@ifundefined{bookcover at part@param@#1}{\@latexerr{Part '#1' undefined.}{}}{
\expandafter\def\csname bookcover at part@param@#1\endcsname{#2}}}
%% NEW NAME BOOKCOVER PART
+
\def\newnamebookcoverpart#1#2{
\@ifundefined{bookcover at part@param@#1}{
\@ifundefined{bookcover at part@param@#2}{\@latexerr{Part '#2' undefined.}{}}{
@@ -267,23 +285,22 @@
{\@latexerr{Part '#1' already defined.}{}}}
%% NEW BOOKCOVER COMPONENT TYPE
-\def\newbookcovercomponenttype#1#2{
- \@ifundefined{bookcover at componenttype@#1}{
- \long\expandafter\def\csname bookcover at componenttype@#1\endcsname##1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- #2
- \end{textblock*}}}
+
+\def\newbookcovercomponenttype#1#2{%
+ \@ifundefined{bookcover at componenttype@#1}{%
+ \long\expandafter\def\csname bookcover at componenttype@#1\endcsname##1{%
+ \bookcover at posbox{\bookcover at partwidth@}{\bookcover at xpos@}{\bookcover at ypos@}{#2}}}
{\@latexerr{Component type '#1' already defined.}{}}}
%% RENEW BOOKCOVER COMPONENT TYPE
-\def\renewbookcovercomponenttype#1#2{
- \@ifundefined{bookcover at componenttype@#1}{\@latex at error{Component type '#1' undefined.}{}}{
- \long\expandafter\def\csname bookcover at componenttype@#1\endcsname##1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- #2
- \end{textblock*}}}}
+\def\renewbookcovercomponenttype#1#2{%
+ \@ifundefined{bookcover at componenttype@#1}{\@latex at error{Component type '#1' undefined.}{}}{%
+ \long\expandafter\def\csname bookcover at componenttype@#1\endcsname##1{%
+ \bookcover at posbox{\bookcover at partwidth@}{\bookcover at xpos@}{\bookcover at ypos@}{#2}}}}
+
%% NEW NAME BOOKCOVER COMPONENT TYPE
+
\def\newnamebookcovercomponenttype#1#2{
\@ifundefined{bookcover at componenttype@#1}{
\@ifundefined{bookcover at componenttype@#2}{\@latexerr{Component type '#2' undefined.}{}}{
@@ -292,6 +309,7 @@
{\@latexerr{Component type '#1' already defined.}{}}}
%% COMPONENT TYPES
+
\newbookcovercomponenttype{color}{
\tikz\fill[#1] (0,0) rectangle (\bookcover at partwidth@,\bookcover at partheight@);}
@@ -354,6 +372,7 @@
\squareruler[#1]{lowerright}{\bookcover at rulerwidth@}{\bookcover at rulerheight@}}{}}
%% BOOKCOVER PARTS
+
\newbookcoverpart{bg back flap}{
\ifdim\flapwidth>0mm
\bookcover at ypos{\marklength}
@@ -617,379 +636,6 @@
\bookcover at xpos{\marklength+\bleedwidth}
\bookcover at partwidth{2\coverwidth+2\flapwidth+\spinewidth}}
-%%%%%%%%%%%%%%%%%%%%%
-%% OBSOLETE METHOD %%
-%%%%%%%%%%%%%%%%%%%%%
-
-%% MAIN LAYERS
-\def\bookcover at bgcolor#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \tikz\fill\expandafter[#1] (0,0) rectangle (\bookcover at partwidth@,\bookcover at partheight@);
- \end{textblock*}}
-
-\def\bookcover at bgpic#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \includegraphics[width=\bookcover at partwidth@,height=\bookcover at partheight@]{#1}
- \end{textblock*}}
-
-\def\bookcover at bgtikz#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \ifbookcover at bgtikznodes
- \begin{tikzpicture}[overlay,yshift=-\bookcover at partheight@]
- \begin{scope}[transparent,line width=0pt]
- \pgfset{minimum width=\bookcover at partwidth@,minimum height=\bookcover at partheight@}
- \pgfnode{rectangle}{south west}{}{current part}{\pgfusepath{draw}}% for v1.1.1
- \pgfnode{rectangle}{south west}{}{part}{\pgfusepath{draw}}
- \pgfset{minimum width=\bookcover at partwidth@-\bookcover at tikz@trimmed at part@width at minus,
- minimum height=\bookcover at partheight@-\bookcover at tikz@trimmed at part@height at minus}
- \pgftransformshift{\pgfpoint{\bookcover at tikz@trimmed at part@push at right}
- {\bookcover at tikz@trimmed at part@push at up}}
- \pgfnode{rectangle}{south west}{}{current trimmed part}{\pgfusepath{draw}}% for v1.1.1
- \pgfnode{rectangle}{south west}{}{trimmed part}{\pgfusepath{draw}}
- \end{scope}
- \ifbookcover at bgtikzclip
- \clip (part.south west) rectangle (part.north east);\fi
- \else\begin{tikzpicture}\fi
- #1
- \end{tikzpicture}
- \end{textblock*}}
-
-\def\bookcover at fg#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \parbox[t][\bookcover at partheight@][t]{\bookcover at partwidth@}{#1}
- \end{textblock*}}
-
-\def\bookcover at remark#1{
- \begin{textblock*}{\bookcover at partwidth@}(\bookcover at xpos@,\bookcover at ypos@)
- \parbox[t][\bookcover at partheight@][c]{\bookcover at partwidth@}{\begin{center}#1\end{center}}
- \end{textblock*}}
-
-%% RESET DATAS
-\def\bookcover at reset{
- \def\bookcover at bgcolor@whole{}
- \def\bookcover at bgcolor@wholewf{}
- \def\bookcover at bgcolor@back{}
- \def\bookcover at bgcolor@front{}
- \def\bookcover at bgcolor@backflap{}
- \def\bookcover at bgcolor@frontflap{}
- \def\bookcover at bgcolor@spine{}
- \def\bookcover at bgpic@whole{}
- \def\bookcover at bgpic@wholewf{}
- \def\bookcover at bgpic@back{}
- \def\bookcover at bgpic@front{}
- \def\bookcover at bgpic@backflap{}
- \def\bookcover at bgpic@frontflap{}
- \def\bookcover at bgpic@spine{}
- \def\bookcover at bgtikz@whole{}
- \def\bookcover at bgtikz@wholewf{}
- \def\bookcover at bgtikz@back{}
- \def\bookcover at bgtikz@front{}
- \def\bookcover at bgtikz@backflap{}
- \def\bookcover at bgtikz@frontflap{}
- \def\bookcover at bgtikz@spine{}
- \def\bookcover at fgfirst@back{}
- \def\bookcover at fgfirst@front{}
- \def\bookcover at fgfirst@spine{}
- \def\bookcover at fgfirst@backflap{}
- \def\bookcover at fgfirst@frontflap{}
- \def\bookcover at fgfirst@abovefront{}
- \def\bookcover at fgfirst@belowfront{}
- \def\bookcover at fgfirst@aboveback{}
- \def\bookcover at fgfirst@belowback{}
- \def\bookcover at fgsecond@back{}
- \def\bookcover at fgsecond@front{}
- \def\bookcover at fgsecond@spine{}
- \def\bookcover at fgsecond@backflap{}
- \def\bookcover at fgsecond@frontflap{}}
-\bookcover at reset
-
-%% SET BOOKCOVER
-\long\def\setbookcover#1#2#3{
- \ifthenelse{\equal{#1}{bgcolor}}{
- \ifthenelse{\equal{#2}{whole}}{\def\bookcover at bgcolor@whole{#3}}{}
- \ifthenelse{\equal{#2}{whole without flaps}}{\def\bookcover at bgcolor@wholewf{#3}}{}
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at bgcolor@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at bgcolor@front{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at bgcolor@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at bgcolor@frontflap{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at bgcolor@spine{#3}}{}}{}
- \ifthenelse{\equal{#1}{bgpic}}{
- \ifthenelse{\equal{#2}{whole}}{\def\bookcover at bgpic@whole{#3}}{}
- \ifthenelse{\equal{#2}{whole without flaps}}{\def\bookcover at bgpic@wholewf{#3}}{}
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at bgpic@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at bgpic@front{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at bgpic@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at bgpic@frontflap{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at bgpic@spine{#3}}{}}{}
- \ifthenelse{\equal{#1}{bgtikz}}{
- \ifthenelse{\equal{#2}{whole}}{\def\bookcover at bgtikz@whole{#3}}{}
- \ifthenelse{\equal{#2}{whole without flaps}}{\def\bookcover at bgtikz@wholewf{#3}}{}
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at bgtikz@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at bgtikz@front{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at bgtikz@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at bgtikz@frontflap{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at bgtikz@spine{#3}}{}}{}
- \ifthenelse{\equal{#1}{fgfirst}}{
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at fgfirst@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at fgfirst@front{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at fgfirst@spine{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at fgfirst@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at fgfirst@frontflap{#3}}{}
- \ifthenelse{\equal{#2}{remark}}{\def\bookcover at fgfirst@abovefront{#3}}{}% for v1.0
- \ifthenelse{\equal{#2}{above front}}{\def\bookcover at fgfirst@abovefront{#3}}{}
- \ifthenelse{\equal{#2}{below front}}{\def\bookcover at fgfirst@belowfront{#3}}{}
- \ifthenelse{\equal{#2}{above back}}{\def\bookcover at fgfirst@aboveback{#3}}{}
- \ifthenelse{\equal{#2}{below back}}{\def\bookcover at fgfirst@belowback{#3}}{}}{}
- \ifthenelse{\equal{#1}{fgsecond}}{
- \ifthenelse{\equal{#2}{back}}{\def\bookcover at fgsecond@back{#3}}{}
- \ifthenelse{\equal{#2}{front}}{\def\bookcover at fgsecond@front{#3}}{}
- \ifthenelse{\equal{#2}{spine}}{\def\bookcover at fgsecond@spine{#3}}{}
- \ifthenelse{\equal{#2}{back flap}}{\def\bookcover at fgsecond@backflap{#3}}{}
- \ifthenelse{\equal{#2}{front flap}}{\def\bookcover at fgsecond@frontflap{#3}}{}}{}}
-
-%% MAKE BOOKCOVER
-\def\makebookcover{
-%% background parameters
-\bookcover at ypos{\marklength}
-\bookcover at partheight{\coverheight+2\bleedwidth}
-%% {bgcolor}{whole}
-\ifx\bookcover at bgcolor@whole\@empty\else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+2\flapwidth+\spinewidth}
- \bookcover at bgcolor{\bookcover at bgcolor@whole}\fi
-%% {bgcolor}{whole without flaps}
-\ifx\bookcover at bgcolor@wholewf\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{2\coverwidth+\spinewidth}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+\spinewidth}\fi
- \bookcover at bgcolor{\bookcover at bgcolor@wholewf}\fi
-%% {bgcolor}{back flap}
-\ifx\bookcover at bgcolor@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgcolor{\bookcover at bgcolor@backflap}\fi\fi
-%% {bgcolor}{back}
-\ifx\bookcover at bgcolor@back\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\coverwidth+\bleedwidth}\fi
- \bookcover at bgcolor{\bookcover at bgcolor@back}\fi
-%% {bgcolor}{spine}
-\ifx\bookcover at bgcolor@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at bgcolor{\bookcover at bgcolor@spine}\fi
-%% {bgcolor}{front}
-\ifx\bookcover at bgcolor@front\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \else
- \bookcover at xpos{\marklength+\bleedwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth+\bleedwidth}\fi
- \bookcover at bgcolor{\bookcover at bgcolor@front}\fi
-%% {bgcolor}{front flap}
-\ifx\bookcover at bgcolor@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgcolor{\bookcover at bgcolor@frontflap}\fi\fi
-%% {bgpic}{whole}
-\ifx\bookcover at bgpic@whole\@empty\else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+2\flapwidth+\spinewidth}
- \bookcover at bgpic{\bookcover at bgpic@whole}\fi
-%% {bgpic}{whole without flaps}
-\ifx\bookcover at bgpic@wholewf\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{2\coverwidth+\spinewidth}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+\spinewidth}\fi
- \bookcover at bgpic{\bookcover at bgpic@wholewf}\fi
-%% {bgpic}{back flap}
-\ifx\bookcover at bgpic@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgpic{\bookcover at bgpic@backflap}\fi\fi
-%% {bgpic}{back}
-\ifx\bookcover at bgpic@back\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\coverwidth+\bleedwidth}\fi
- \bookcover at bgpic{\bookcover at bgpic@back}\fi
-%% {bgpic}{spine}
-\ifx\bookcover at bgpic@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at bgpic{\bookcover at bgpic@spine}\fi
-%% {bgpic}{front}
-\ifx\bookcover at bgpic@front\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \else
- \bookcover at xpos{\marklength+\bleedwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth+\bleedwidth}\fi
- \bookcover at bgpic{\bookcover at bgpic@front}\fi
-%% {bgpic}{front flap}
-\ifx\bookcover at bgpic@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgpic{\bookcover at bgpic@frontflap}\fi\fi
-%% {bgtikz}{whole}
-\ifx\bookcover at bgtikz@whole\@empty\else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+2\flapwidth+\spinewidth}
- \bookcover at bgtikz@trimmed at part@param{2\bleedwidth}{\bleedwidth}
- \bookcover at bgtikz{\bookcover at bgtikz@whole}\fi
-%% {bgtikz}{whole without flaps}
-\ifx\bookcover at bgtikz@wholewf\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{2\coverwidth+\spinewidth}
- \bookcover at bgtikz@trimmed at part@param{0pt}{0pt}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{2\coverwidth+2\bleedwidth+\spinewidth}
- \bookcover at bgtikz@trimmed at part@param{2\bleedwidth}{\bleedwidth}\fi
- \bookcover at bgtikz{\bookcover at bgtikz@wholewf}\fi
-%% {bgtikz}{back flap}
-\ifx\bookcover at bgtikz@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgtikz@trimmed at part@param{\bleedwidth}{\bleedwidth}
- \bookcover at bgtikz{\bookcover at bgtikz@backflap}\fi\fi
-%% {bgtikz}{back}
-\ifx\bookcover at bgtikz@back\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at bgtikz@trimmed at part@param{0pt}{0pt}
- \else
- \bookcover at xpos{\marklength}
- \bookcover at partwidth{\coverwidth+\bleedwidth}
- \bookcover at bgtikz@trimmed at part@param{\bleedwidth}{\bleedwidth}\fi
- \bookcover at bgtikz{\bookcover at bgtikz@back}\fi
-%% {bgtikz}{spine}
-\ifx\bookcover at bgtikz@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at bgtikz@trimmed at part@param{0pt}{0pt}
- \bookcover at bgtikz{\bookcover at bgtikz@spine}\fi
-%% {bgtikz}{front}
-\ifx\bookcover at bgtikz@front\@empty\else
- \ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at bgtikz@trimmed at part@param{0pt}{0pt}
- \else
- \bookcover at xpos{\marklength+\bleedwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth+\bleedwidth}
- \bookcover at bgtikz@trimmed at part@param{\bleedwidth}{0pt}\fi
- \bookcover at bgtikz{\bookcover at bgtikz@front}\fi
-%% {bgtikz}{front flap}
-\ifx\bookcover at bgtikz@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth+\bleedwidth}
- \bookcover at bgtikz@trimmed at part@param{\bleedwidth}{0pt}
- \bookcover at bgtikz{\bookcover at bgtikz@frontflap}\fi\fi
-%% foreground parameters
-\bookcover at ypos{\marklength+\bleedwidth}
-\bookcover at partheight{\coverheight}
-%% {fgsecond}{back flap}
-\ifx\bookcover at fgsecond@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth}
- \bookcover at partwidth{\flapwidth}
- \bookcover at fg{\bookcover at fgsecond@backflap}\fi\fi
-%% {fgsecond}{back}
-\ifx\bookcover at fgsecond@back\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at fg{\bookcover at fgsecond@back}\fi
-%% {fgsecond}{spine}
-\ifx\bookcover at fgsecond@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at fg{\bookcover at fgsecond@spine}\fi
-%% {fgsecond}{front}
-\ifx\bookcover at fgsecond@front\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at fg{\bookcover at fgsecond@front}\fi
-%% {fgsecond}{front flap}
-\ifx\bookcover at fgsecond@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth}
- \bookcover at fg{\bookcover at fgsecond@frontflap}\fi\fi
-%% {fgfirst}{back flap}
-\ifx\bookcover at fgfirst@backflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth}
- \bookcover at partwidth{\flapwidth}
- \bookcover at fg{\bookcover at fgfirst@backflap}\fi\fi
-%% {fgfirst}{back}
-\ifx\bookcover at fgfirst@back\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at fg{\bookcover at fgfirst@back}\fi
-%% {fgfirst}{spine}
-\ifx\bookcover at fgfirst@spine\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth}
- \bookcover at partwidth{\spinewidth}
- \bookcover at fg{\bookcover at fgfirst@spine}\fi
-%% {fgfirst}{front}
-\ifx\bookcover at fgfirst@front\@empty\else
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at partwidth{\coverwidth}
- \bookcover at fg{\bookcover at fgfirst@front}\fi
-%% {fgfirst}{front flap}
-\ifx\bookcover at fgfirst@frontflap\@empty\else\ifdim\flapwidth>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+2\coverwidth+\spinewidth}
- \bookcover at partwidth{\flapwidth}
- \bookcover at fg{\bookcover at fgfirst@frontflap}\fi\fi
-%% {fgfirst}{above front} = {fgfirst}{remark} in v1.0
-\ifx\bookcover at fgfirst@abovefront\@empty\else\ifdim\marklength>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at ypos{0mm}
- \bookcover at partwidth{\coverwidth}
- \bookcover at partheight{\marklength}
- \bookcover at remark{\bookcover at fgfirst@abovefront}\fi\fi
-%% {fgfirst}{below front}
-\ifx\bookcover at fgfirst@belowfront\@empty\else\ifdim\marklength>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth+\coverwidth+\spinewidth}
- \bookcover at ypos{\marklength+2\bleedwidth+\coverheight}
- \bookcover at partwidth{\coverwidth}
- \bookcover at partheight{\marklength}
- \bookcover at remark{\bookcover at fgfirst@belowfront}\fi\fi
-%% {fgfirst}{above back}
-\ifx\bookcover at fgfirst@aboveback\@empty\else\ifdim\marklength>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at ypos{0mm}
- \bookcover at partwidth{\coverwidth}
- \bookcover at partheight{\marklength}
- \bookcover at remark{\bookcover at fgfirst@aboveback}\fi\fi
-%% {fgfirst}{below back}
-\ifx\bookcover at fgfirst@belowback\@empty\else\ifdim\marklength>0mm
- \bookcover at xpos{\marklength+\bleedwidth+\flapwidth}
- \bookcover at ypos{\marklength+2\bleedwidth+\coverheight}
- \bookcover at partwidth{\coverwidth}
- \bookcover at partheight{\marklength}
- \bookcover at remark{\bookcover at fgfirst@belowback}\fi\fi
-%% marks
-\bookcover at marks
-%% trimming
-\ifbookcover at trimmed\bookcover at trimming\fi
-%% new book cover
-\mbox{}\newpage\bookcover at reset}
\endinput
%%
%% End of file `bookcover.cls'.
More information about the tex-live-commits
mailing list.