texlive[63800] Master/texmf-dist: kdpcover (3jul22)
commits+karl at tug.org
commits+karl at tug.org
Sun Jul 3 22:57:54 CEST 2022
Revision: 63800
http://tug.org/svn/texlive?view=revision&revision=63800
Author: karl
Date: 2022-07-03 22:57:54 +0200 (Sun, 03 Jul 2022)
Log Message:
-----------
kdpcover (3jul22)
Modified Paths:
--------------
trunk/Master/texmf-dist/doc/latex/kdpcover/kdpcover.pdf
trunk/Master/texmf-dist/doc/latex/kdpcover/kdpcover.tex
trunk/Master/texmf-dist/tex/latex/kdpcover/kdpcover.cls
Modified: trunk/Master/texmf-dist/doc/latex/kdpcover/kdpcover.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/doc/latex/kdpcover/kdpcover.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/kdpcover/kdpcover.tex 2022-07-03 20:57:41 UTC (rev 63799)
+++ trunk/Master/texmf-dist/doc/latex/kdpcover/kdpcover.tex 2022-07-03 20:57:54 UTC (rev 63800)
@@ -27,6 +27,9 @@
% It's better not to use "pages" option here, but to let it calculate
% the size of your book from the PDF file. Just say "pdf=book.pdf" and it
% will be calculated automatically.
+%
+% To get rid of the black bar at the center of the page, just add
+% "barless" option here.
\documentclass[pages=200,6x9]{kdpcover}
\begin{document}
@@ -45,7 +48,7 @@
% Here we print the version and it will also add the date of the latest
% Git commit in the current directory. If it's not a Git repository,
% the date won't be printed.
-\putVersion{0.2.4}
+\putVersion{0.3.0}
% This prints the price, which is a good practice to mention, I believe.
\putPrice{\$0.00}
Modified: trunk/Master/texmf-dist/tex/latex/kdpcover/kdpcover.cls
===================================================================
--- trunk/Master/texmf-dist/tex/latex/kdpcover/kdpcover.cls 2022-07-03 20:57:41 UTC (rev 63799)
+++ trunk/Master/texmf-dist/tex/latex/kdpcover/kdpcover.cls 2022-07-03 20:57:54 UTC (rev 63800)
@@ -21,7 +21,7 @@
% SOFTWARE.
\NeedsTeXFormat{LaTeX2e}
-\ProvidesClass{kdpcover}[2022/01/09 0.2.4 Cover for Kindle Direct Publishing books]
+\ProvidesClass{kdpcover}[2022/07/03 0.3.0 Cover for Kindle Direct Publishing books]
\LoadClass{article}
\makeatletter
@@ -41,6 +41,8 @@
\DeclareOptionX{7x10}{\setlength\kdp at xsize{7in}\setlength\kdp at ysize{10in}}
\DeclareOptionX{8x10}{\setlength\kdp at xsize{8in}\setlength\kdp at ysize{10in}}
\DeclareOptionX{pages}{\renewcommand*\kdp at pages{#1}}
+\newif\ifkdp at barless
+\DeclareOptionX{barless}{\kdp at barlesstrue}
\DeclareOptionX{pdf}{%
\iexec[trace,quiet,stdout=kdpcover-pages-count.txt]{qpdf --show-npages #1 | tr -d '[[:space:]]' | \{ cat; echo \%; \}}%
\newread\kdp at pagescount%
@@ -75,12 +77,15 @@
\RequirePackage[absolute]{textpos}
\TPGrid{16}{16}
+\makeatletter
\newcommand\putSpine[2][kdpcover-signature]{%
- \begin{textblock}{2.4}[0.5,0](8,0)%
- \begin{tikzpicture}%
- \node [rectangle, inner sep=0em, fill=black, minimum width=2.4\TPHorizModule, minimum height=16\TPVertModule] at (0,0) {};
- \end{tikzpicture}%
- \end{textblock}%
+ \ifkdp at barless\else
+ \begin{textblock}{2.4}[0.5,0](8,0)%
+ \begin{tikzpicture}%
+ \node [rectangle, inner sep=0em, fill=black, minimum width=2.4\TPHorizModule, minimum height=16\TPVertModule] at (0,0) {};
+ \end{tikzpicture}%
+ \end{textblock}%
+ \fi
\begin{textblock}{1}[0.5,0](8,2)%
\begin{tikzpicture}%
\node [color=white, inner sep=0cm, outer sep=0cm, rotate=270, minimum height=\TPHorizModule] at (0,0) {
@@ -92,6 +97,7 @@
\centerline{\includegraphics[width=0.32in]{#1}}%
\end{textblock}%
}
+\makeatother
\newcommand\putPicture[1]{%
\begin{textblock}{4}(10,2)%
More information about the tex-live-commits
mailing list.