16

I would like to be able to create a page like the following:

enter image description here

I am using PDFLaTeX, by the way.

I tried playing around with the minipage environments, but while I get somewhere, there are always issues. My plan of attack was to create two minipages, one with the gray background and one with the black background and then add text and pictures where they need to be. I realize that the cover page, does not need to be in LaTeX, but at this point, after all the time I spent trying to make it happen, I just want to see it on paper. I ran in all sorts of problems: cannot center the pictures, cannot fit the pictures, title page get pushed to page 2, and a few more.

I wonder if anyone has any words of wisdom or practical tips that could help me achieve my goal.

Alternatively, I would be happy using the page created using paint.net and that I attached as a picture and import it in my LaTeX titlepage. But, even doing this, I ran in quite a few troubles and it never looks as I would like it to.

Thank you in advance for any act of kindness...

Maurice

My "code" is

\documentclass[10pt]{book}  
\usepackage{color}  
\usepackage{xcolor}  

\begin{document}  
\pagestyle{empty}  
\begin{titlepage}  

\colorbox{gray}{\begin{minipage}[t]{0.15\textwidth}  
\offinterlineskip  
\begin{center}  
\includegraphics[scale=0.40]{Doob_4a.jpg} \\  
..........................  
\includegraphics[scale=0.40]{Poisson_4a.jpg}\\  
\end{center}  
\end{minipage}}  
\colorbox{black}{\begin{minipage}[t]{0.85\textwidth}  
\begin{center}  
\vbox{ \hbox{{\huge {\bf \textcolor{white}{PROBABILITY THEORY}}}}
       \vskip 10pt \noindent
       \hbox{{\Large{\bf \textcolor{white}{A Modern Comprehensive Course}}}}
     }  
\vskip .25cm \noindent  
\textcolor{white}{\hrule}  
\textcolor{white}{\hrule}  
\vskip .5cm \noindent  
{\large \textcolor{white}{XXXXX YYYYYY}}  
\vskip 2.75cm  
\includegraphics[scale=0.70]{BM3d.png}  
\vskip 2.5cm  
{\large \textcolor{white}{Occult Sciences Publishing}}  
\end{center}  
\end{minipage}}  

\end{titlepage}  

\end{document}  

My issues are:

  1. The title page gets pushed to page 2;
  2. The minipages are not even; and
  3. Ideally, I would also like not to have any space between the gray and black ... Still not great looking, but at least feasible.
5
  • Welcome to TeX.SX!! Some people take exception to questions of the form "Please draw this for me". You will get more help if you post some code showing what you have tried and give a minimal working example.
    – user30471
    Feb 7, 2016 at 1:43
  • Although this should be feasible in regular LaTeX, you may want to have a look at the TikZ library. It is primarily used to create diagram; however, it also support placing elements are absolute coordinates on a page which may be easier.
    – JP-Ellis
    Feb 7, 2016 at 2:05
  • 1
    Wouldn't it make more sense to compose this page in gimp and then just attach it to the top of the pdf output from the tex code -using something like pdftk.
    – DBS
    Feb 7, 2016 at 2:25
  • Yes, DBS, you are right... Besides, that is the only way to achieve some kind of recognized professional quality when using so much graphics and colors. But at this point it is a personal challenge.
    – Maurice
    Feb 7, 2016 at 2:33
  • 1
    Don't create it in the same file as your book, though. Even if you do it in LaTeX. Either create it and input the code or, more straightforward, create a separate PDF and include that as its own page. That way you can set the margins etc. however you like and not worry about them being different. (Covers aren't meant to be laid out in the same way as pages inside the book, so the usual reasons to keep everything together are reversed in this case.)
    – cfr
    Feb 7, 2016 at 3:22

5 Answers 5

13

Something like this? Note that the images on the left are not all the same width because the images I used have different proportions. Provided yours have the same height:width ratio, they will match in width.

\documentclass[letterpaper]{article}
\usepackage[scale=1]{geometry}
\usepackage{tikz,calc}
\usetikzlibrary{positioning,calc}
\setlength\parindent{0pt}
\begin{document}
\begin{tikzpicture}
  \fill [black] (current page.north east) rectangle (current page.south west);
  \fill [gray] (current page.north west) rectangle ([xshift=50mm]current page.south west);
  \node (person 0) [anchor=south, inner sep=0pt] at ([xshift=25mm,yshift=-10mm]current page.north west) {};
  \foreach \i [count=\ino, remember=\ino as \j (initially 0)] in {example-image-9x16,example-image-golden-upright,example-image-9x16,example-image-golden-upright,example-image-9x16,example-image-golden-upright,example-image-9x16,example-image-golden-upright,example-image-9x16,example-image-golden-upright,example-image-9x16,example-image-golden-upright,example-image-9x16}
  \node (person \ino) [anchor=north, inner sep=0pt] at (person \j.south) {\includegraphics[height=\paperheight/13-20mm/13] {\i} };
  \node (title) [anchor=south, font=\Huge\bfseries, text=white] at ([xshift=25mm,yshift=-50mm]current page.north) {PROBABILITY THEORY};
  \node (subtitle) [below=5mm of title.south, anchor=north, text=white, font=\LARGE\bfseries] {A Modern Comprehensive Course};
  \path [line width=1pt, draw=white] ([yshift=-5mm]title.west |- subtitle.south) coordinate (a) -- ([yshift=-5mm]title.east |- subtitle.south) coordinate (b) ([xshift=2.5mm,yshift=-2.5mm]a) -- ([xshift=-2.5mm,yshift=-2.5mm]b) coordinate (c);
  \node at ($(title.center |- c)!1/2!(current page.south -| title.center)$) {\includegraphics[height=.5\paperheight] {tiger}};
\end{tikzpicture}
\end{document}

tiger of probability theory

Use

\usepackage{pdfpages}
...
\includepdf{<filename>}

if you wish to include it in your main document. (This seems odd since it presumably shouldn't be numbered, for example. But if you need it, you can do it.)

EDIT

I initially tried to use only images from the standard TeX distributions. Since nobody else is restricting themselves to that, I figure I might as well play, too. Here's a version which relies more on parameters to set the cover up. The basic code is the same. The only difference really is that some settings are no longer hard-coded. Probably not useful for a cover page, but perhaps handy in similar contexts where several pictures with the same structure might be used.

I'll keep the tiger, though. Standard or not....

\documentclass[letterpaper]{article}
\usepackage[scale=1]{geometry}
\usepackage{tikz,calc}
\usetikzlibrary{positioning,calc}
\setlength\parindent{0pt}
\newlength\coverscratch
\setlength\coverscratch{10mm}
\newlength\coverborder
\setlength\coverborder{30mm}
\tikzset{%
  cover border left/.store in=\coverborderleft,
  cover border right/.store in=\coverborderright,
  cover border top/.store in=\coverbordertop,
  cover border bottom/.store in=\coverborderbottom,
  cover border images/.store in=\coverborderimages,
  cover sample image/.code={%
    \settowidth{\coverscratch}{\includegraphics[height=\paperheight/\coverborderimages-\coverbordertop/\coverborderimages-\coverborderbottom/\coverborderimages]{#1}}%
    \setlength{\coverborder}{\coverborderleft+\coverborderright+\coverscratch}%
  },
  cover border image/.style={%
    anchor=north,
    inner sep=0pt,
    node contents={\includegraphics[height=\paperheight/\coverborderimages-\coverbordertop/\coverborderimages-\coverborderbottom/\coverborderimages]{#1}},
  },
  cover title drop/.store in=\covertitledrop,
  % make sure everything has a default
  cover border left=10mm,
  cover border right=10mm,
  cover border top=2.5mm,
  cover border bottom=2.5mm,
  cover border images=13,
  cover sample image={example-image-golden-upright},
  cover title drop=50mm,
}
\begin{document}
\begin{tikzpicture}
  [
    cover border top=5mm,
    cover border bottom=5mm,
    cover border left=7.5mm,
    cover border right=7.5mm,
    cover sample image={people/Charles_Darwin},% best to set this last to ensure correct values are used
  ]
  \fill [black] (current page.north east) rectangle (current page.south west);
  \fill [gray] (current page.north west) rectangle ([xshift=\coverborder]current page.south west);
  \node (person 0) [anchor=south, inner sep=0pt] at ([xshift=.5*\coverborder,yshift=-\coverbordertop]current page.north west) {};
  \foreach \i [count=\ino, remember=\ino as \j (initially 0)] in {Albert_Einstein,Carl_Sagan,Charles_Darwin,Marie_Curie,Niels_Bohr,Nikola_Tesla,Richard_Feynman,Steven_Hawking,Stimpson_J,Albert_Einstein,Carl_Sagan,Charles_Darwin,Marie_Curie}
  \node (person \ino) at (person \j.south) [cover border image={people/\i}];
  \node (title) [anchor=south, font=\Huge\bfseries, text=white] at ([xshift=.5*\coverborder,yshift=-\covertitledrop]current page.north) {PROBABILITY THEORY};
  \node (subtitle) [below=5mm of title.south, anchor=north, text=white, font=\LARGE\bfseries] {A Modern Comprehensive Course};
  \path [line width=1pt, draw=white] ([yshift=-5mm]title.west |- subtitle.south) coordinate (a) -- ([yshift=-5mm]title.east |- subtitle.south) coordinate (b) ([xshift=2.5mm,yshift=-2.5mm]a) -- ([xshift=-2.5mm,yshift=-2.5mm]b) coordinate (c);
  \node at ($(title.center |- c)!1/2!(current page.south -| title.center)$) {\includegraphics[height=.5\paperheight] {tiger}};
\end{tikzpicture}
\end{document}

cover with parameters

5
  • If I miscounted the number of people, change 13 to whatever is appropriate. Your images will also probably end up wider, so I tried to allow for that.
    – cfr
    Feb 7, 2016 at 4:02
  • Tigers as famous probabilists would be better.:-) But +1, of course.
    – Kola B.
    Feb 7, 2016 at 4:03
  • @KolaB. I only remembered the tiger at the last minute. Plus, I guess it is better to have rectangular things for the examples on the left?
    – cfr
    Feb 7, 2016 at 4:04
  • It was only a suggestion, that they are tigers of mathematics. :-)
    – Kola B.
    Feb 7, 2016 at 4:08
  • Excellent... The tiger will be for another time, for my notes for the algebra course, for instance. Thank you for your help, cfr
    – Maurice
    Feb 7, 2016 at 7:25
10

You may also try the textpos-package. It has a good manual, and is easy to learn, even if you learn by trial and error. If you like me is not skilled in Tikz, maybe you find textpos easier to use.

I have made the cover page, but you will have to link to your own files. Probably, you should harmonise the high and width of all picture in an external program, and use keepaspectratio=true instead of a explicit width (I fixed high and width just to save time). As you see, I made a grid consisting of thirteen vertical and twelve horizontal modules. To have the border around the faces, I reduced the hight of the picture slightly. Each picture of the persons now occupy one vertical module, less the fraction of a millimetre.

You will also find that I created the dark gray and the black background as boxes occupying the whole page. Using grid modules make it easy to change paper size, because the grid is set up relative to the page height and width. Thereafter, you just overlay the two ‘background’ boxes with new boxes containing the text and the graphics. texpos are compatible with calc so it is also easy to calculate relative positions.

\documentclass{book}
\usepackage[absolute]{textpos}
\usepackage{calc,color,xcolor,graphicx}

\TPGrid[0mm,0mm]{12}{13}

\textblockorigin{0mm}{0mm} % start everything near the top-left corner
\setlength{\parindent}{0pt}

\begin{document}
\begin{textblock}{2}(0,0)
\textblockcolour{darkgray}
\parbox[0][13\TPVertModule][0]{2\TPHorizModule}{text}
\end{textblock}

\begin{textblock}{10}(2,0)
\textblocklabel{block two}
\textblockcolour{black}
\parbox[0][13\TPVertModule][0]{10\TPHorizModule}{text}
\end{textblock}

\begin{textblock}{8}[0.5,0.5](7,2)
\textblockcolour{black}
\centering\textcolor{white}{\Huge\bfseries PROBABILITY THEORY}\par\bigskip
\textcolor{white}{\huge A Modern Comprehensive Course}\par\medskip
\textcolor{white}{\rule{6.5\TPHorizModule}{1pt}}\par\vspace{-0.5\baselineskip}
\textcolor{white}{\rule{6.5\TPHorizModule}{1pt}}
\end{textblock}

\begin{textblock}{1.5}(0.4,0.1)
\textblockcolour{darkgray}
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{homer-simpson}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{Marge_Simpson}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{lisa-simpson}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{Apu}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{barney-gumble}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{homer-simpson}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{Marge_Simpson}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{lisa-simpson}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{Apu}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{barney-gumble}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{homer-simpson}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{Marge_Simpson}\par
\includegraphics[width=1.5\TPHorizModule, height=1\TPVertModule-0.65mm]{lisa-simpson}\par

\end{textblock}


\begin{textblock}{8}[0.5,0.5](7,7)
\textblockcolour{black}
\centering
\includegraphics[width=1.5\TPHorizModule, width=7\TPHorizModule]{everybody}\par
\end{textblock}

\end{document}

enter image description here

1
  • Nice ;). I wonder if the tiger is better or worse at probability than Homer?
    – cfr
    Feb 7, 2016 at 20:36
7

Here's an example using images from my own computer. You can use your own.

\documentclass[10pt]{book}  
\usepackage{graphicx}
\usepackage{tikz}
\usetikzlibrary{calc}
\newcommand\myhoffset{0.75in}
\newcommand\mytitlesep{1.00cm}
\newcommand\portraitscalefactor{85/100}
\newcommand\portraitheight{\dimexpr1in*\portraitscalefactor}
\newcommand\portraitwidth{\dimexpr1in*\portraitscalefactor}
\newcommand\portraitvoffset{\dimexpr\paperheight-1in*\portraitscalefactor*12\relax/2}
\begin{document}  
\pagestyle{empty}
\begin{tikzpicture}[remember picture,overlay]

  %% creating the  black background
  \fill[black] (current page.north west) rectangle (current page.south east);
  %% gray sidebar
  \fill[gray]  (current page.north west) rectangle ($(current page.south west)+(\myhoffset*2,0)$);

  %% setting up the title
  \node[white,scale=3.0] (title) at ($(current page.north)+(\myhoffset,-2in)$) {\textbf{PROBABILITY THEORY}};
  \node[white,scale=2.0] (subtitle) at ($(title.south)+(0,-\mytitlesep)$) {\textbf{A Modern Comprehensive Course}};

  %% double line below title
  \begin{scope}[transform canvas={yshift=-\dimexpr\mytitlesep*2+1ex},
                my y shift/.style={yshift=-5pt}]
  \draw[line width=1.5pt,white]             (title.south west) --             (title.south east);
  \draw[line width=1.5pt,white] ([my y shift]title.south west) -- ([my y shift]title.south east);
  \end{scope}

  %% the main feature picture
  \node at ($(current page.center)+(\myhoffset,-\dimexpr\mytitlesep*3+0.25in)$) 
        {\includegraphics[width=4in]{images/shantideva}};

  %% the side portraits
  \foreach \mypic [count=\myn from 0] in {%%
                                          chick,
                                          demon,
                                          no_you_cant,
                                          cameraman,
                                          chick,
                                          demon,
                                          no_you_cant,
                                          cameraman,
                                          chick,
                                          demon,
                                          no_you_cant,
                                          cameraman}
  {
    \node at ($(current page.north west)+(0.75in,-\dimexpr\portraitvoffset+\portraitheight/2+\portraitheight*\myn\relax)$) 
          {\includegraphics[width=\portraitwidth,height=\portraitheight]{images/\mypic.png}};
  }
\end{tikzpicture}
\end{document}  

enter image description here

2
  • Sweet.. Thank you! I will try to follow your lead.
    – Maurice
    Feb 7, 2016 at 7:26
  • (+1) for the parametisation. Any point in loading color and xcolor? tikz loads xcolor and graphicx also.
    – cfr
    Feb 7, 2016 at 14:24
4

Not there are always issues with minipages. If fact, I found this the easiest approach for this type of cover.

I left a MWE as the first page of the book document, since this would be suitable when the goal is the own PDF instead of the hard copy.

(Sorry, no scientists nor tigers here, I found only landscapes and a pussycat in the image-gallery directory of TeX Live)

\documentclass[a4paper]{book}
\usepackage[margin=0cm]{geometry}
\usepackage{array,xcolor,colortbl,calc}
\parindent0pt\parskip0pt
\usepackage{graphicx}
\graphicspath{{/usr/local/texlive/2015/texmf-dist/doc/latex/image-gallery/}}
\title{Probability Theory}
\author{Fran Kens Tein}
\date{\today} 
\begin{document}
\fboxsep0pt\fboxrule0pt
\fcolorbox{gray}{gray}{
\begin{minipage}[c][29.7cm][c]{5cm}
\centering
\includegraphics[width=3cm]{pic001}
\includegraphics[width=3cm]{pic002}
\includegraphics[width=3cm]{pic004}
\includegraphics[width=3cm]{pic005}
\includegraphics[width=3cm]{pic006}
\includegraphics[width=3cm]{pic007}
\includegraphics[width=3cm]{pic008}
\includegraphics[width=3cm]{pic009}
\includegraphics[width=3cm]{pic010}
\includegraphics[width=3cm]{pic011}
\includegraphics[width=3cm]{pic012}
\includegraphics[width=3cm]{pic014}
\end{minipage}}%
\fcolorbox{black}{black}{
\begin{minipage}[c][29.7cm][c]{16cm}
\centering
\color{white}
\bfseries
\resizebox{12cm}{!}{PROBABILITY THEORY}
\vskip 1cm 
\resizebox{11cm}{!}{A Modern Comprehensive Course}
\vskip 1cm 
\rule{12cm}{2pt}
\rule{12cm}{2pt}
\vskip 1cm 
\includegraphics[width=12cm]{pic021}
\end{minipage}}
\frontmatter
\newgeometry{margin=1in}
\maketitle
\mainmatter
\chapter{Introduction}
Lore ipsum ...
\end{document}

mwe

2
  • Hmm... didn't know these were in TL. The tiger is in TL somewhere in EPS format. The scientists, not so much. (But nor are the Simpsons, are they?) Your cover is surely more approachable than mine!
    – cfr
    Feb 9, 2016 at 2:34
  • @Fran The simplest, and therefore the best, solution, in my opinion.
    – Sveinung
    Feb 9, 2016 at 9:59
1
  1. For me title page comes in the first page itself.
  2. Minipages are even when the first minipage width as {0.18\textwidth} and the second one as {0.85\textwidth}.
  3. Between the two minipages environments write the command \hspace{-0.3cm}and execute the code you will the desired result.
0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .