summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2017-03-14 21:51:28 +0000
committerKarl Berry <karl@freefriends.org>2017-03-14 21:51:28 +0000
commitd8b72356da66172cbf65bea41e6d41eddb6226b0 (patch)
tree48c6762cf7533865808c3b68d781940f72b47a69 /Master
parentd1c70ab27326385145a9d77d021834269f4d81a2 (diff)
titlepic (14mar17)
git-svn-id: svn://tug.org/texlive/trunk@43497 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/latex/titlepic/README13
-rw-r--r--Master/texmf-dist/doc/latex/titlepic/README.md18
-rw-r--r--Master/texmf-dist/doc/latex/titlepic/titlepic-manual.pdfbin60128 -> 122875 bytes
-rw-r--r--Master/texmf-dist/doc/latex/titlepic/titlepic-manual.tex23
-rw-r--r--Master/texmf-dist/tex/latex/titlepic/titlepic.sty92
5 files changed, 90 insertions, 56 deletions
diff --git a/Master/texmf-dist/doc/latex/titlepic/README b/Master/texmf-dist/doc/latex/titlepic/README
deleted file mode 100644
index dbe4c98b89d..00000000000
--- a/Master/texmf-dist/doc/latex/titlepic/README
+++ /dev/null
@@ -1,13 +0,0 @@
-The titlepic package allows you to place a picture on the
-title page (cover page) of a LaTeX document.
-
-Example of usage:
-\usepackage[cc]{titlepic}
-\usepackage{graphicx}
-\titlepic{\includegraphics[width=\textwidth]{picture.png}}
-
-Note: the package currently only works with the document
-classes article, report and book.
-
-Author: Thomas ten Cate
-License: Public Domain \ No newline at end of file
diff --git a/Master/texmf-dist/doc/latex/titlepic/README.md b/Master/texmf-dist/doc/latex/titlepic/README.md
new file mode 100644
index 00000000000..b1c19b8720a
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/titlepic/README.md
@@ -0,0 +1,18 @@
+The `titlepic` package for LaTeX
+================================
+
+The titlepic package allows you to place a picture on the
+title page (cover page) of a LaTeX document.
+
+Example of usage:
+
+ \usepackage[cc]{titlepic}
+ \usepackage{graphicx}
+ \titlepic{\includegraphics[width=\textwidth]{picture.png}}
+
+Note: the package currently only works with the document
+classes article, report and book.
+
+Author: Thomas ten Cate
+License: Public Domain
+Source: https://github.com/ttencate/titlepic
diff --git a/Master/texmf-dist/doc/latex/titlepic/titlepic-manual.pdf b/Master/texmf-dist/doc/latex/titlepic/titlepic-manual.pdf
index 63a02124aba..cf9bec69038 100644
--- a/Master/texmf-dist/doc/latex/titlepic/titlepic-manual.pdf
+++ b/Master/texmf-dist/doc/latex/titlepic/titlepic-manual.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/titlepic/titlepic-manual.tex b/Master/texmf-dist/doc/latex/titlepic/titlepic-manual.tex
index dec9ff4100e..d8e5d2a37b6 100644
--- a/Master/texmf-dist/doc/latex/titlepic/titlepic-manual.tex
+++ b/Master/texmf-dist/doc/latex/titlepic/titlepic-manual.tex
@@ -18,8 +18,11 @@
}
\title{\LaTeX{} \texttt{titlepic} Manual}
-\author{Thomas ten Cate\thanks{\texttt{<ttencate@gmail.com>}}}
-\date{August 5, 2008}
+\author{
+ Thomas ten Cate\thanks{\texttt{<ttencate@gmail.com>}} \\
+ with contributions from \\
+ Denis Bitouz\'e}
+\date{March 14, 2017}
\titlepic{\placeholder{\textwidth}{0.75\textwidth}} % This is the magic command!
\begin{document}
@@ -30,14 +33,15 @@
In \LaTeX, there is by default no way to put a picture on the title page or cover page that is produced by \verb$\maketitle$. Surprisingly, no package seemed to exist for this either, which is why I put together this very simple package named \verb$titlepic$.
-\textbf{Note:} \verb$titlepic$ only works with the default document classes \verb$article$, \verb$report$ and \verb$book$.
+\textbf{Note:} \verb$titlepic$ only works with the default document classes \verb$article$, \verb$report$ and \verb$book$. However, it works both with the \verb$titlepage$ and \verb$notitlepage$ document class options.
\section{Installation}
-There are two ways to install the package:
+There are several ways to install the package:
\begin{itemize}
\item Simply drop \verb$titlepic.sty$ in the same directory as your \verb$.tex$ source document. This is the easiest option for casual use.
\item Put \verb$titlepic.sty$ somewhere in your \verb$texmf$ tree and rehash. The details depend on your \TeX{} distribution. This gives you a system-wide installation.
+ \item Install it from \TeX{} Live or MiK\TeX.
\end{itemize}
\section{Usage}
@@ -54,8 +58,6 @@ Include the package as normal, with:
\verb$\usepackage{graphicx}$
\end{quote}
-\textbf{Note:} when you use the \verb$article$ document class, be sure to pass it the \verb$titlepage$ option (\verb$\documentclass[titlepage]{article}$), because articles do not have a title page by default.
-
Then, along with the usual \verb$\title$, \verb$\author$ and \verb$\date$, put a command like the following:
\begin{quote}
@@ -84,10 +86,10 @@ There are three optional arguments that control the vertical layout of the title
Here is a full example of what your document could look like.
\begin{verbatim}
-% Be sure to pass titlepage to the article class
+% Pass titlepage to the article class
\documentclass[titlepage]{article}
-% Centre the picture and the title vertically with cc
+% Centre the picture and the title vertically with cc (only works with titlepage mode)
\usepackage[cc]{titlepic}
% For \includegraphics
@@ -109,4 +111,9 @@ Here is a full example of what your document could look like.
\end{document}
\end{verbatim}
+\section{Contributing}
+
+Contributions are welcome! Send a pull request on GitHub here:\\
+\verb$https://github.com/ttencate/titlepic$
+
\end{document}
diff --git a/Master/texmf-dist/tex/latex/titlepic/titlepic.sty b/Master/texmf-dist/tex/latex/titlepic/titlepic.sty
index 974885c8998..2aca230a8d4 100644
--- a/Master/texmf-dist/tex/latex/titlepic/titlepic.sty
+++ b/Master/texmf-dist/tex/latex/titlepic/titlepic.sty
@@ -1,17 +1,18 @@
% titlepic.sty is a LaTeX package to show a picture on the cover produced by \maketitle.
% By Thomas ten Cate <ttencate@gmail.com>. Free software, no warranty of any kind.
-%
+%
% Version history:
+% 1.2: works without titlepage as well
% 1.1: now more self-contained, comes with a PDF manual
% 1.0: first release
-%
+%
% -----------------------------------------------------------------------------
% No idea whether it works on older LaTeXes.
\NeedsTeXFormat{LaTeX2e}
% Package identification and version number.
-\ProvidesPackage{titlepic}[2009/08/03 1.1 Package to display a picture on the title page]
+\ProvidesPackage{titlepic}[2017/03/14 1.2 Package to display a picture on the title page]
% Declare the options.
\DeclareOption{tt}{\gdef\@tptopspace{}\gdef\@tpsepspace{\vskip 3em}}
@@ -28,41 +29,62 @@
% If a title page was requested from the document class (article/report/book),
% override \maketitle to show our picture.
\if@titlepage
-\renewcommand\maketitle{
- \begin{titlepage}%
- \let\footnotesize\small
- \let\footnoterule\relax
- \let \footnote \thanks
- \@tptopspace%
+ \renewcommand\maketitle{
+ \begin{titlepage}%
+ \let\footnotesize\small
+ \let\footnoterule\relax
+ \let \footnote \thanks
+ \@tptopspace%
+ \begin{center}%
+ {\LARGE \@title \par}%
+ \vskip 3em%
+ {\large
+ \lineskip .75em%
+ \begin{tabular}[t]{c}%
+ \@author
+ \end{tabular}\par%
+ }%
+ \vskip 1.5em%
+ {\large \@date \par}% % Set date in \large size.
+ \end{center}\par
+ \@tpsepspace%
+ {\centering\@titlepic\par}
+ \vfil
+ \@thanks
+ \end{titlepage}%
+ \setcounter{footnote}{0}%
+ \global\let\thanks\relax
+ \global\let\maketitle\relax
+ \global\let\@thanks\@empty
+ \global\let\@author\@empty
+ \global\let\@date\@empty
+ \global\let\@title\@empty
+ \global\let\@titlepic\@empty
+ \global\let\title\relax
+ \global\let\author\relax
+ \global\let\date\relax
+ \global\let\and\relax
+ \global\let\titlepic\relax
+ }
+\else
+ \def\@maketitle{%
+ \newpage
+ \null
+ \vskip 2em%
\begin{center}%
+ \let \footnote \thanks
{\LARGE \@title \par}%
- \vskip 3em%
+ \vskip 1.5em%
{\large
- \lineskip .75em%
- \begin{tabular}[t]{c}%
+ \lineskip .5em%
+ \begin{tabular}[t]{c}%
\@author
- \end{tabular}\par%
- }%
- \vskip 1.5em%
- {\large \@date \par}% % Set date in \large size.
- \end{center}\par
- \@tpsepspace%
+ \end{tabular}\par}%
+ \vskip 1em%
+ {\large \@date}%
+ \end{center}%
+ \vskip .5em%
{\centering\@titlepic\par}
- \vfil
- \@thanks
- \end{titlepage}%
- \setcounter{footnote}{0}%
- \global\let\thanks\relax
- \global\let\maketitle\relax
- \global\let\@thanks\@empty
- \global\let\@author\@empty
- \global\let\@date\@empty
- \global\let\@title\@empty
- \global\let\@titlepic\@empty
- \global\let\title\relax
- \global\let\author\relax
- \global\let\date\relax
- \global\let\and\relax
- \global\let\titlepic\relax
-}
+ \par
+ \vskip 1.5em}
\fi