% (The MIT License)
%
% Copyright (c) 2021 Yegor Bugayenko
%
% Permission is hereby granted, free of charge, to any person obtaining a copy
% of this software and associated documentation files (the 'Software'), to deal
% in the Software without restriction, including without limitation the rights
% to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
% copies of the Software, and to permit persons to whom the Software is
% furnished to do so, subject to the following conditions:
%
% The above copyright notice and this permission notice shall be included in all
% copies or substantial portions of the Software.
%
% THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
% IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
% FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
% AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
% LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
% OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
% SOFTWARE.

\documentclass[pages=200,6x9]{kdpcover}
\begin{document}
% Here we put the vertical black spine line with two white elements
% inside: the text at the top and the logo at the bottom. Make sure
% the text is short enough so that it doesn't touch the logo. It's
% a good practice to mention the volume number at the end of the text,
% if you have more than one volume, e.g. "my book, vol. 1". I suggest
% using small caps in the text only.
\putSpine{kdpcover, a LaTeX class for KDP books}

% This one prints the volume picture. It is intentionally made large,
% in order to make it obvious.
\putVolume{1}

% 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.1}

% This prints the price, which is a good practice to mention, I believe.
\putPrice{\$0.00}

% This one prints the copyright short message with the year and the
% name of the autor.
\putCopyright{\the\year}{Yegor Bugayenko}

% Here we print the title of the book
\putTitle{kdpcover}

% Here we print the author.
\putAuthor{Yegor Bugayenko}

% Here we print the TL;DR paragraph, which summarizies the message
% of the entire book.
\putTLDR{I use this LaTeX class to design covers for my books published
by Kindle Direct Publishing; you also can do it, provided you like the layout and the style.}

% The picture.
\putPicture{cactus.pdf}

% This is the text on the back of the book, which usually I suggest
% to omit and keep the back empty and white.
\putBack{
    You need to either specify the number of pages
    in your PDF book, or provide the path to the PDF.
    In the latter case, the pages will be counted using
    "qpdf," which has to be installed:
    \newline\newline
    \char`\\documentclass[pages=200,pdf=book.pdf]\string{kdpcover\string}\newline
    \char`\\begin\string{document\string}\newline
    \char`\\putSpine\string{my book\string}\newline
    \char`\\end\string{document\string}
    \newline\newline
    See the file "kdpcover.tex" for a full example with all
    available commands and class options.
    \newline\newline
    Even more details you can find on GitHub:\newline
    https://github.com/yegor256/kdpcover
}
\end{document}