From e0c6872cf40896c7be36b11dcc744620f10adf1d Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Mon, 2 Sep 2019 13:46:59 +0900 Subject: Initial commit --- macros/latex/contrib/captcont/Makefile | 90 +++ macros/latex/contrib/captcont/README | 34 + macros/latex/contrib/captcont/captcont.dtx | 1073 ++++++++++++++++++++++++++++ macros/latex/contrib/captcont/captcont.ins | 57 ++ macros/latex/contrib/captcont/captcont.pdf | Bin 0 -> 130931 bytes macros/latex/contrib/captcont/test.tex | 288 ++++++++ 6 files changed, 1542 insertions(+) create mode 100644 macros/latex/contrib/captcont/Makefile create mode 100644 macros/latex/contrib/captcont/README create mode 100644 macros/latex/contrib/captcont/captcont.dtx create mode 100644 macros/latex/contrib/captcont/captcont.ins create mode 100644 macros/latex/contrib/captcont/captcont.pdf create mode 100644 macros/latex/contrib/captcont/test.tex (limited to 'macros/latex/contrib/captcont') diff --git a/macros/latex/contrib/captcont/Makefile b/macros/latex/contrib/captcont/Makefile new file mode 100644 index 0000000000..ddcc2404b2 --- /dev/null +++ b/macros/latex/contrib/captcont/Makefile @@ -0,0 +1,90 @@ +PACKAGE = captcont +######################################################################## +## LaTeX2e Makefile +## +## Update the following defines for your local configuration, +## +CONTRIB = /usr/local/lib/texmf/tex/contrib +## +DVIPS = dvips +GZIP = gzip +LATEX = latex +MAKEINDEX = makeindex +######################################################################## +## make [all] Generates the style (.sty) file and the +## documentation (.ps). If you don't have the +## required MAKEINDEX (along with `gglo.ist' and +## `gind.ist'), then change the first dependency +## of "all" from "fullps" to "ps" below. +## make [un]install Install or uninstall the style (.sty) file from +## the CONTRIB area. +## make [very]clean Clean out various auxillary files. "veryclean" +## cleans out more stuff. +######################################################################## +## make dvi Generate the *.dvi version of the documentation. +## make [full]ps Generate the documentation. The "fullps" version +## adds the change log and the cross-references. +## make idx Generate the change log and the cross-references +## (for fullps -- requires MAKEINDEX). +## make sty Generate the style (.sty) file. +######################################################################## +## make test Run test file(s) +## make distribtion Builds a distribution (.tar.gz) file. +######################################################################## + +all: fullps test clean + +install: sty + cp $(PACKAGE).sty $(CONTRIB) +uninstall: ; rm $(CONTRIB)/$(PACKAGE).sty +clean: ; -rm -f *.dvi *.log *.aux *.lof *.lot *.toc + -rm -f *.idx *.ind *.glo *.gls *.ilg *~ +veryclean: clean + -rm -f *.sty *.cls *.ps *.gz *pk *.cfg + + +dvi: $(PACKAGE).dvi +fullps: dvi idx ps +idx: $(PACKAGE).ind $(PACKAGE).gls + $(LATEX) $(PACKAGE).dtx +ps: $(PACKAGE).ps +sty: $(PACKAGE).sty + +distribution: ; mkdir $(PACKAGE) + cp -p README Makefile $(PACKAGE) + cp -p $(PACKAGE).dtx $(PACKAGE).ins $(PACKAGE) + cp -p test*.tex $(PACKAGE) + tar -cvf $(PACKAGE).tar ./$(PACKAGE) + rm -rf $(PACKAGE) + $(GZIP) -9 $(PACKAGE).tar + +$(PACKAGE).aux: $(PACKAGE).dtx $(PACKAGE).sty + $(LATEX) $(PACKAGE).dtx + +$(PACKAGE).dvi: $(PACKAGE).dtx $(PACKAGE).sty $(PACKAGE).aux + $(LATEX) $(PACKAGE).dtx + $(LATEX) $(PACKAGE).dtx + $(LATEX) $(PACKAGE).dtx + +$(PACKAGE).glo: $(PACKAGE).dtx $(PACKAGE).sty + $(LATEX) $(PACKAGE).dtx + +$(PACKAGE).gls: $(PACKAGE).glo + $(MAKEINDEX) -s gglo.ist -o $(PACKAGE).gls $(PACKAGE).glo + +$(PACKAGE).idx: $(PACKAGE).dtx $(PACKAGE).sty + $(LATEX) $(PACKAGE).dtx + +$(PACKAGE).ind: $(PACKAGE).idx + $(MAKEINDEX) -s gind.ist $(PACKAGE).idx + +$(PACKAGE).ps: $(PACKAGE).dvi + $(DVIPS) -o $(PACKAGE).ps $(PACKAGE).dvi + +$(PACKAGE).sty: $(PACKAGE).dtx $(PACKAGE).ins + $(LATEX) $(PACKAGE).ins + +test: $(PACKAGE).sty + $(LATEX) test.tex + $(LATEX) test.tex + $(DVIPS) -o test.ps test.dvi diff --git a/macros/latex/contrib/captcont/README b/macros/latex/contrib/captcont/README new file mode 100644 index 0000000000..66efe63f51 --- /dev/null +++ b/macros/latex/contrib/captcont/README @@ -0,0 +1,34 @@ +README +------ + +This directory contains version 2.0 of the captcont package. +Use `make' to extract the captcont package and run the local test. + +MANIFEST: +--------- +Makefile UNIX makefile to extract the captcont package + and related material. +README This file. +captcont.dtx The documented captcont package. +captcont.ins The captcont package installation file. + + +FILES AFTER `make': +------------------- +Makefile UNIX makefile to extract the captcont package + and related material. +README This file. +captcont.dtx The documented captcont package. +captcont.ins The captcont package installation file. +captcont.ps Captcont package documentation. +captcont.sty The captcont package +ltxdoc.cfg Configuration file to print change history and + index on the captcont package documentation. +test.ps Results of the test program. +test.tex Test: Regular and continued tables and figures. + +NOTES: +------ + +To verify the results of the test, compare with the tests found at +http://www.cs.cmu.edu/~sdc/latex/captcont.20/ diff --git a/macros/latex/contrib/captcont/captcont.dtx b/macros/latex/contrib/captcont/captcont.dtx new file mode 100644 index 0000000000..18841a3a05 --- /dev/null +++ b/macros/latex/contrib/captcont/captcont.dtx @@ -0,0 +1,1073 @@ +% \iffalse % captcont.dtx +% Retain figure/table number across multiple pages and provide correct +% output to List-of-Figures or List-of-Tables files. +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% Copyright (C) 1997-2002 Steven Douglas Cochran +% +% The captcont package is free software; it may be distributed under the +% conditions of the LaTeX Project Public License, either version 1.2 of +% this license or (at your option) any later version. The latest version +% of this license is in: +% http://www.latex-project.org/lppl.txt +% and version 1.2 or later is part of all distributions of LaTeX version +% 1999/09/03 or later. +% +% The captcont package is distributed in the hope that it will be +% useful, but WITHOUT ANY WARRANTY; without even the implied warranty +% of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +% LaTeX Project Public License for more details. +% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%% @LaTeX-style-file{ +%% author = "Steven Douglas Cochran", +%% version = "2.0", +%% date = "2002/02/14", +%% time = "11:59:17", +%% filename = "captcont.sty", +%% address = "Digital Mapping Laboratory, School of Computer Science +%% Carnegie-Mellon University, 5000 Forbes Avenue +%% Pittsburgh, PA 15213-3890, USA", +%% telephone = "+1 412.268.5654", +%% fax = "+1 412.268.5576", +%% email = "sdc+@CS.CMU.EDU (Internet)", +%% codetable = "ISO/ASCII", +%% keywords = "LaTeX, caption, float, figure, table, subfigure", +%% supported = "yes", +%% abstract = "LaTeX package for providing support for retaining +%% a figure or table number across several float +%% environments---usually over several pages. It +%% also allows control over the contents of the +%% List-of-Figures and the List-of-Tables pages." +%% } +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% +%<*driver> +\NeedsTeXFormat{LaTeX2e}[1994/12/01] +\ProvidesFile{subfigure.dtx} +\documentclass{ltxdoc} +\usepackage{captcont}[2002/01/23] +\usepackage[TABTOPCAP,tight]{subfigure}[2002/01/23] +\setlength\hfuzz{100pt} +\setlength\vfuzz{100pt} +\clubpenalty=10000 +\widowpenalty=10000 +\displaywidowpenalty=5000 +\brokenpenalty=5000 +\begin{document} + \DocInput{captcont.dtx} +\end{document} +% +% +%<*ltxdoc> +\AtBeginDocument{ +% \OnlyDescription % comment out for implementation details + \EnableCrossrefs + \RecordChanges + \CodelineIndex} +\AtEndDocument{ + \PrintChanges + \PrintIndex} +% +% +% \fi +% +% \catcode`\^=14 ^^A We will use a ^ for a comment rather than ^^A. +% \newcommand*{\Lopt}[1]{\textsf{#1}} ^ Package options +% \newcommand*{\Lfile}[1]{\texttt{#1}} ^ File names +% \newcommand*{\Lpack}[1]{\textsf{#1}} ^ Package names +% \newcommand*{\Lenv}[1]{\texttt{#1}} ^ Environment names +% \newcommand*{\Lcount}[1]{\textsl{\small#1}} ^ Counter names +% \newcommand*{\Lif}[1]{\textsc{\bf#1}} ^ \if names +% ^ NOTE: Hacks added to make the final format are marked ``^finalhack''. +% +% \changes{v1.0}{11 Oct 1996}{Initial revision.} +% +% \DoNotIndex{\@ehd,\@firstofone,\@for,\@gobble,\@ifundefined,\@latex@error} +% \DoNotIndex{\@ne,\@undefined,\addcontentsline,\addtolength,\advance,\alph} +% \DoNotIndex{\begingroup,\bfseries,\bgroup,\box,\csname,\DeclareOption} +% \DoNotIndex{\def,\do,\egroup,\else,\endcsname,\endgroup,\ExecuteOption} +% \DoNotIndex{\ExecuteOptions,\expandafter,\fi,\footnotesize,\gdef,\hbox} +% \DoNotIndex{\global,\hfil,\ifdim,\ifnum,\ifx,\ignorespaces,\itshape} +% \DoNotIndex{\Large,\large,\leavevmode,\let,\long,\mdseries,\multiply} +% \DoNotIndex{\NeedsTeXFormat,\newcommand,\newcounter,\newif,\noexpand} +% \DoNotIndex{\normalsize,\par,\parbox,\ProcessOptions,\protect} +% \DoNotIndex{\ProvidesPackage,\relax,\renewcommand,\rmfamily,\sbox} +% \DoNotIndex{\scriptsize,\scshape,\setbox,\setcounter,\setlength,\sffamily} +% \DoNotIndex{\slshape,\small,\space,\string,\strut,\ttfamily,\tw@,\typeout} +% \DoNotIndex{\undefined,\upshape,\usebox,\vbox,\vskip,\vtop,\wd,\xdef} +% \DoNotIndex{\z@skip,\@dblarg,\@ifstar,\@nameuse,\@parboxrestore} +% \DoNotIndex{\@setminipage,\edef,\if@minipage,\m@ne,\numberline} +% \DoNotIndex{\providecommand,\refstepcounter,\@makecaption,\@captype} +% \DoNotIndex{\@currentlabel} +% +% \CheckSum{156} +% +% ^ This command creates a rectangular box to represent +% ^ a figure in the examples given in this paper. +% \newcommand{\figbox}[1]{% +% \fbox{^ +% \vbox to 15mm{^ +% \vfil +% \hbox{^ +% \space +% #1^ +% \space}^ +% \vfil}}} +% +% ^ Allow a little more freedom in typesetting floats. +% \setcounter{topnumber}{8} +% \def\topfraction{.8} +% \setcounter{bottomnumber}{8} +% \def\bottomfraction{.8} +% \setcounter{totalnumber}{8} +% \def\textfraction{.2} +% \def\floatpagefraction{.8} +% \setcounter{dbltopnumber}{8} +% \def\dbltopfraction{.8} +% \def\dblfloatpagefraction{.8} +% +% ^ Add some space above any footnotes. +% \skip\footins=1.5\baselineskip +% +% ^ Make the \fbox stay just inside the box it "surrounds". +% \fboxsep=-\fboxrule +% +% ^ Make the subcaption label be centered. +% \subfiglabelskip=0pt +% +% \makeatletter +% +% ^ Create an EXAMPLE float environment. +% ^ NOTE: This is not complete --- just enough for this paper. +% \newcounter{example} +% \renewcommand\theexample{\@arabic\c@example} +% \def\fps@example{tbp} +% \def\ftype@example{3} +% \def\ext@example{loe} +% \def\fnum@example{\examplename~\theexample} +% \newenvironment{example} +% {\@float{example}} +% {\end@float} +% \newcommand\examplename{Example} +% +% ^ This command switches the caption type. +% \newcommand{\setcaptype}[1]{\renewcommand{\@captype}{#1}} +% +% \makeatother +% +% \def\docdate{2002/02/14} +% \def\fileversion{v2.0} +% \def\filedate{2002/01/23} +% \def\filename{captcont.dtx} +% +% \title{The \Lpack{captcont} Package\footnote{This paper documents +% the \Lpack{captcont} package v\fileversion, last revised \filedate.}} +% \author{Steven Douglas Cochran\\[5pt] +% Digital Mapping Laboratory, School of Computer Science \\ +% Carnegie-Mellon University, 5000 Forbes Avenue \\ +% Pittsburgh, PA 15213--3890, USA\\[5pt] +% \texttt{sdc+@cs.cmu.edu}} +% \date{\docdate} +% +% \maketitle +% +% \begin{abstract} +% \noindent +% This article documents the \LaTeX\ package `\Lpack{captcont}', which +% provides support for retaining a figure or caption number across +% several float environments---usually over several pages. It allows +% control over the contents of the List-of-Figures and the +% List-of-Tables pages. It should be compatible with all other packages +% that modify or extend the float environment and with the +% \Lpack{subfigure} package \cite{Coch02} in particular. +%\end{abstract} +% +% \tableofcontents +% +% \newpage +% \section{Introduction} +% \enlargethispage{12pt} ^finalhack +% +% The \Lpack{captcont} package provides support for figures and tables +% that continue or span two or more pages, but cannot be easily handled +% by another mechanism such as the \Lpack{longtable} package \cite{Carl00} +% or the \Lpack{supertabular} environment \cite{Braa-Jurr99}. The reason +% for this is usually that the figure or table is made up of multiple +% small parts. Therefore this package is typically used in conjunction +% the \Lpack{subfigure} package\cite{Coch02}. +% +% This \LaTeXe\ package replaces the older \LaTeX2.09 style fragment +% written by Anonymous. This is a complete re-implementation of the +% older style so that the List-of-Figures, List-of-Tables and the +% |\pageref| command have the correct page numbers. +% +% \section{The User Interface} +% +% To use this package place +% \begin{quote} +% |\usepackage|\oarg{options}\{captcont\} +% \end{quote} +% +% \noindent +% in the preamble of your document. The supported options are shown in +% table~\ref{tab:options}.\footnote{If the \Lpack{subfigure} package is +% also loaded, then the \Lpack{subfigure} package options override +% these.} This package redefines the |\caption| command and defines +% three new commands to work with it. The new commands act very similar +% to the caption, but control when the \Lcount{figure} or \Lcount{table} +% counter is incremented and whether or not the caption text shows up in +% the List-of-Figures or List-of-Tables pages. The commands are: +% +% \begin{tabbing} +% \qquad \=|\captcont|* \=\oarg{lst\_entry} \=\marg{caption}\kill +% \>|\caption| \>\oarg{lst\_entry} \>\marg{caption}\\ +% \>|\caption|* \>\oarg{lst\_entry} \>\marg{caption}\\ +% \>|\captcont| \>\oarg{lst\_entry} \>\marg{caption}\\ +% \>|\captcont|* \>\oarg{lst\_entry} \>\marg{caption} +% \end{tabbing} +% \noindent +% The |\captcont| and |\captcont|* commands do not increment the +% \Lcount{figure} or \Lcount{table} counters and the |\captcont|* and +% |\caption|* commands do not print to the List-of-Figures or +% List-of-Tables. +% +% If the caption proceeds the figure ({\it i.e.\/}, \Lopt{figtopcap} or +% \Lopt{tabtopcap}), then for a series of \Lenv{float} environments that +% are to be considered as one \Lenv{figure} or \Lenv{table}, you begin +% the first with a |\caption| or |\caption*| and use |\captcont| or +% |\captcont*| in each of the the following ones. If the caption +% follows the figure ({\it i.e.\/}, \Lopt{figbotcap} or +% \Lopt{tabbotcap}), then you do just the opposite and use |\captcont| +% or |\captcont*| on each of the series of \Lenv{float} environments +% that are to be considered as one \Lenv{figure} or \Lenv{table}, the +% use a |\caption| or |\caption*| on the very last one. +% +% \begin{table} +% \caption{\Lpack{captcont} package options.} +% \label{tab:options} +% \DeleteShortVerb{\|} +% \centering +% \begin{tabular}{l|l} +% \hline +% \multicolumn{1}{c|}{\bf Option} +% & \multicolumn{1}{c}{\bf Description} \\ +% \hline +% \Lopt{figbotcap} & The figure caption follows the figure (default).\\ +% \Lopt{figtopcap} & The figure caption precedes the figure.\\ \hline +% \Lopt{tabbotcap} & The table caption follows the figure.\\ +% \Lopt{tabtopcap} & The table caption precedes the figure (default).\\ +% \hline +% \end{tabular} +% \MakeShortVerb{\|} +% \end{table} +% +% \section{Examples} +% +% Four examples are given below of the use of the \Lpack{captcont} +% package. The ``figures'' in each are drawn using the following command +% which creates a small box representing a figure in the example output +% and centers provided text in the box. The height of the box is fixed +% at 15mm and the width varies with the provided text. +% \newpage ^finalhack +% +% \begin{verbatim} +% \newcommand{\figbox}[1]{% +% \fbox{% Frame the box to make the ``figure'' +% \vbox to 15mm{% Make it 15mm tall +% \vfil Vertically center this next \hbox +% \hbox{% +% \space +% #1% Add the supplied text with spaces +% \space}% +% \vfil}}} +% \end{verbatim} +% +% \subsection{Two Continued Figures} +% +% Example~\ref{ex:one} shows the case of a set of three pages containing +% parts of one figure. In this case the author desires that the caption +% of each page shows up in the List-of-Figures page. The |\caption| +% follows the figure body, so we use the |\captcont| command on the +% inital pages and the |\caption| on the last. +% +% \begin{verbatim} +% \listoffigures +% ... +% \begin{figure}[p] +% \figbox{Figure~\ref{fig:ex1-1}, part 1, page \pageref{fig:ex1-1}} +% \captcont{Figure one.} +% \label{fig:ex1-1} +% \end{figure} +% \begin{figure}[p] +% \figbox{Figure~\ref{fig:ex1-1}, part 2, page \pageref{fig:ex1-2}} +% \captcont{Figure one. (cont)} +% \label{fig:ex1-2} +% \end{figure} +% \begin{figure}[p] +% \figbox{Figure~\ref{fig:ex1-1}, part 3, page \pageref{fig:ex1-3}} +% \caption{Figure one. (cont)} +% \label{fig:ex1-3} +% \end{figure} +% \end{verbatim} +% +% \begin{example} +% \setcaptype{figure}^ +% \centering +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \begin{minipage}{2.1in}^ +% \vspace{.1in}^ +% \section*{ List of Figures} +% \contentsline{figure}{\numberline{1}^ +% {\ignorespaces Figure one.}}{2}^ +% \contentsline{figure}{\numberline{1}^ +% {\ignorespaces Figure one. (cont)}}{3}^ +% \contentsline{figure}{\numberline{1}^ +% {\ignorespaces Figure one. (cont)}}{4}^ +% \hspace{40pt}\dots +% \vspace{21pt}^ +% \end{minipage}^ +% \end{minipage}}^ +% \quad +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \figbox{Figure~\ref{fig:ex1-1}, part 1, page 2.}^ +% \vspace{-5pt}^ +% \captcont{Figure one.}^ +% \label{fig:ex1-1}^ +% \vspace{10pt}^ +% -2- +% \vspace{.1in}^ +% \end{minipage}}\\[.1in] +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \figbox{Figure~\ref{fig:ex1-2}, part 2, page 3.}^ +% \vspace{-5pt}^ +% \captcont{Figure one. (cont)}^ +% \label{fig:ex1-2}^ +% \vspace{10pt}^ +% -3- +% \vspace{.1in}^ +% \end{minipage}}^ +% \quad +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \figbox{Figure~\ref{fig:ex1-3}, part 3, page 4.}^ +% \vspace{-5pt}^ +% \caption{Figure one. (cont)}^ +% \label{fig:ex1-3}^ +% \vspace{10pt}^ +% -4- +% \vspace{.1in}^ +% \end{minipage}}^ +% \setcaptype{example}^ +% \caption{Four pages showing a continued figure with +% List-of-Figures entries for each.} +% \label{ex:one} +% \end{example} +% +% \newpage ^finalhack +% Often, however, you do not want the continued captions to appear in +% the List-of-Figures. Therefore the starred forms of the commands are +% available to suppress the addition of the caption text to the +% List-of-Figures, as shown in example~\ref{ex:two} where only the +% first caption appears. +% +% \begin{verbatim} +% \listoffigures +% ... +% \begin{figure}[p] +% \figbox{Figure~\ref{fig:ex2-1}, part 1, page \pageref{fig:ex2-1}} +% \captcont{Figure two.} +% \label{fig:ex2-1} +% \end{figure} +% \begin{figure}[p] +% \figbox{Figure~\ref{fig:ex2-1}, part 2, page \pageref{fig:ex2-2}} +% \captcont*{Figure one. (cont)} +% \label{fig:ex2-2} +% \end{figure} +% \begin{figure}[p] +% \figbox{Figure~\ref{fig:ex2-1}, part 3, page \pageref{fig:ex2-3}} +% \caption*{Figure one. (cont)} +% \label{fig:ex2-3} +% \end{figure} +% \end{verbatim} +% +% \begin{example}^ +% \setcaptype{figure}^ +% \centering +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \begin{minipage}{2.1in}^ +% \vspace{.1in}^ +% \section*{ List of Figures} +% \hspace{40pt}\dots +% \vspace{3pt}^ +% \contentsline{figure}{\numberline{2}^ +% {\ignorespaces Figure two.}}{5}^ +% \hspace{40pt}\dots +% \vspace{30pt}^ +% \end{minipage}^ +% \end{minipage}}^ +% \quad +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \figbox{Figure~\ref{fig:ex2-1}, part 1, page 5.}^ +% \vspace{-5pt}^ +% \captcont{Figure two.}^ +% \label{fig:ex2-1}^ +% \vspace{10pt}^ +% -5- +% \vspace{.1in}^ +% \end{minipage}}\\[.1in] +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \figbox{Figure~\ref{fig:ex2-2}, part 2, page 6.}^ +% \vspace{-5pt}^ +% \captcont*{Figure two. (cont)}^ +% \label{fig:ex2-2}^ +% \vspace{10pt}^ +% -6- +% \vspace{.1in}^ +% \end{minipage}}^ +% \quad +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \figbox{Figure~\ref{fig:ex2-3}, part 3, page 7.}^ +% \vspace{-5pt}^ +% \caption*{Figure two. (cont)}^ +% \label{fig:ex2-3}^ +% \vspace{10pt}^ +% -7- +% \vspace{.1in}^ +% \end{minipage}}^ +% \setcaptype{example}^ +% \caption{Four pages showing a continued figure with +% List-of-Figures entries for the first page only.} +% \label{ex:two} +% \end{example} +% +% \subsection{A Continued Series of Subfigures} +% +% Example~\ref{ex:three} shows the interaction of the \Lpack{contcapt} and +% the \Lpack{subfigure} packages. When the \Lpack{subfigure} package is +% also loaded, it overrides any options given with this package (it +% doesn't matter if it is loaded before or after the \Lpack{captcont} +% package). For this and the following example, we assume that the +% \Lpack{subfigure} package was loaded with the options +% [\Lopt{FIGBOTCAP},\Lopt{TABTOPCAP}]; therefore, for continued figures +% and tables, we {\bf end} the series of continued figures and we {\bf +% begin} the series of continued tables with with a |\caption| or +% |\caption*| command. The rest of the figure or tables parts use +% either the |\captcont| or the |\captcont*| command. +% +% \begin{example}^ +% \setcaptype{figure}^ +% \centering +% \leavevmode +% \small +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \subfigure[]{\figbox{Subfigure 1A}}^ +% \quad +% \subfigure[]{\figbox{Subfigure 1B}}\\ +% \subfigure[]{\figbox{Subfigure 1C}}^ +% \quad +% \subfigure[]{\figbox{Subfigure 1D}}\\ +% \vspace{-5pt}^ +% \caption{This is a simple figure.}^ +% \label{fig:ex3-1}^ +% \vspace{10pt}^ +% -8- +% \vspace{.1in}^ +% \end{minipage}}^ +% \quad +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \subfigure[]{\figbox{Subfigure 2A}}^ +% \quad +% \subfigure[]{\figbox{Subfigure 2B}}\\ +% \subfigure[]{\figbox{Subfigure 2C}}^ +% \quad +% \subfigure[]{\figbox{Subfigure 2D}}\\ +% \vspace{-5pt}^ +% \captcont{This is a continued figure.} +% \label{fig:ex3-2a}^ +% \vspace{10pt}^ +% -9- +% \vspace{.1in}^ +% \end{minipage}}\\[.1in] +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \subfigure[]{\figbox{Subfigure 2E}}^ +% \quad +% \subfigure[]{\figbox{Subfigure 2F}}\\ +% \subfigure[]{\figbox{Subfigure 2G}}^ +% \quad +% \subfigure[]{\figbox{Subfigure 2H}}^ +% \vspace{-5pt}^ +% \hfil\parbox{2.1in}{^ +% \captcont*{This is a continued figure (cont.)} +% }\\ +% \label{fig:ex3-2b}^ +% \vspace{10pt}^ +% -10- +% \vspace{.1in}^ +% \end{minipage}}^ +% \quad +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \vspace{.1in}^ +% \subfigure[]{\figbox{Subfigure 2I}}^ +% \quad +% \subfigure[]{\figbox{Subfigure 2J}}\\ +% \subfigure[]{\figbox{Subfigure 2K}}^ +% \quad +% \subfigure[]{\figbox{Subfigure 2L}} +% \vspace{-5pt}^ +% \hfil\parbox{2.1in}{^ +% \caption*{This is a continued figure (cont.)} +% }\\ +% \label{fig:ex3-2c} +% \vspace{10pt}^ +% -11- +% \vspace{.1in}^ +% \end{minipage}}^ +% \setcaptype{example}^ +% \caption{Four pages showing a regular figure with four subfigures +% and a continued figure composed of twelve subfigures.} +% \label{ex:three} +% \end{example} +% +% \begin{verbatim} +% \begin{figure}[p]% +% \begin{center}% +% \subfigure[]{\figbox{Subfigure 1A}}% +% \quad +% \subfigure[]{\figbox{Subfigure 1B}}\\ +% \subfigure[]{\figbox{Subfigure 1C}}% +% \quad +% \subfigure[]{\figbox{Subfigure 1D}}% +% \end{center}% +% \caption{This is a simple figure.} +% \label{fig:ex3-1} +% \end{figure} +% \end{verbatim} +% +% \newpage ^finalhack +% \enlargethispage{12pt} ^finalhack +% +% \begin{verbatim} +% \begin{figure}[p]% +% \begin{center}% +% \subfigure[]{\figbox{Subfigure 2A}}% +% \quad +% \subfigure[]{\figbox{Subfigure 2B}}\\ +% \subfigure[]{\figbox{Subfigure 2C}}% +% \quad +% \subfigure[]{\figbox{Subfigure 2D}}% +% \end{center}% +% \captcont{This is a continued figure.} +% \label{fig:ex3-2a} +% \end{figure} +% \end{verbatim} +% +% \begin{verbatim} +% \begin{figure}[p]% +% \begin{center}% +% \subfigure[]{\figbox{Subfigure 2E}}% +% \quad +% \subfigure[]{\figbox{Subfigure 2F}}\\ +% \subfigure[]{\figbox{Subfigure 2G}}% +% \quad +% \subfigure[]{\figbox{Subfigure 2H}}% +% \end{center}% +% \captcont*{This is a continued figure (cont.)} +% \label{fig:ex3-2b} +% \end{figure} +% +% \begin{figure}[p]% +% \begin{center}% +% \subfigure[]{\figbox{Subfigure 2I}}% +% \quad +% \subfigure[]{\figbox{Subfigure 2J}}\\ +% \subfigure[]{\figbox{Subfigure 2K}}% +% \quad +% \subfigure[]{\figbox{Subfigure 2L}}% +% \end{center}% +% \caption*{This is a continued figure (cont.)} +% \label{fig:ex3-2c} +% \end{figure} +% \end{verbatim} +% +% Here only the first two captions (for figures~\ref{fig:ex3-1} and +% \ref{fig:ex3-2a}) appear in the List-of-Tables. The correct figure +% and page numbers are generated by any |\label| commands for later use +% with |\ref| or |\pageref|. When the \Lpack{subfigure} package is +% loaded this goes for the \cmd{\subref} command also. +% +% \subsection{A Continued Series of Subtables} +% +% Example~\ref{ex:four} also shows the interaction of the \Lpack{contcapt} +% and \Lpack{subfigure} packages. Here the \Lpack{table} environment is +% used along with the \Lopt{TABTOPCAP} option which insures that the +% numbering for the subtables is correct when the |\caption| preceeds +% them rather than following them. As mentioned above, we use the +% |\caption| or |\caption*| command for the first \Lenv{float} environment +% and the |\captcont| or |\captcont*| command for the continued +% \Lenv{float}'s. +% +% \begin{example}^ +% \setcaptype{table}^ +% \centering +% \leavevmode +% \small +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \caption{This is a simple table.}^ +% \label{tab:One}^ +% \vspace{4pt}^ +% \subtable[\label{tab:OneA}]{\figbox{Subtable 1A}}^ +% \quad +% \subtable[\label{tab:OneB}]{\figbox{Subtable 1B}}\\ +% \subtable[\label{tab:OneC}]{\figbox{Subtable 1C}}^ +% \quad +% \subtable[\label{tab:OneD}]{\figbox{Subtable 1D}}\par +% \vspace{10pt}^ +% -12- +% \vspace{.1in}^ +% \end{minipage}}^ +% \quad +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \caption{This is a continued table.}^ +% \vspace{4pt}^ +% \subtable[]{\figbox{Subtable 2A}}^ +% \quad +% \subtable[]{\figbox{Subtable 2B}}\\ +% \subtable[]{\figbox{Subtable 2C}}^ +% \quad +% \subtable[]{\figbox{Subtable 2D}}\par +% \vspace{10pt}^ +% -13- +% \vspace{.1in}^ +% \end{minipage}}\\[.1in] +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \hfil\parbox{2.1in}{^ +% \captcont*{This is a continued table (cont.)}^ +% }\\ +% \vspace{4pt}^ +% \subtable[]{\figbox{Subtable 2E}}^ +% \quad +% \subtable[]{\figbox{Subtable 2F}}\\ +% \subtable[]{\figbox{Subtable 2G}}^ +% \quad +% \subtable[]{\figbox{Subtable 2H}}\par +% \vspace{10pt}^ +% -14- +% \vspace{.1in}^ +% \end{minipage}}^ +% \quad +% \fbox{^ +% \begin{minipage}{2.3in}^ +% \centering +% \hfil\parbox{2.1in}{^ +% \captcont*{This is a continued table (cont.)}^ +% }\\ +% \vspace{4pt}^ +% \subtable[]{\figbox{Subtable 2I}}^ +% \quad +% \subtable[]{\figbox{Subtable 2J}}\\ +% \subtable[]{\figbox{Subtable 2K}}^ +% \quad +% \subtable[]{\figbox{Subtable 2L}}\par +% \vspace{10pt}^ +% -15- +% \vspace{.1in}^ +% \end{minipage}}^ +% \setcaptype{example}^ +% \caption{Four pages showing a regular table with four subtables +% and a continued table composed of twelve subtables.} +% \label{ex:four} +% \end{example} +% +% \newpage ^finalhack +% \enlargethispage{12pt} ^finalhack +% +% \begin{verbatim} +% \begin{table}[p]% +% \caption{This is a simple table.}% +% \label{tab:One}% +% \begin{center}% +% \subtable[\label{tab:OneA}]{\figbox{Subtable 1A}}% +% \quad +% \subtable[\label{tab:OneB}]{\figbox{Subtable 1B}}\\ +% \subtable[\label{tab:OneC}]{\figbox{Subtable 1C}}% +% \quad +% \subtable[\label{tab:OneD}]{\figbox{Subtable 1D}}% +% \end{center}% +% \end{table} +% +% \begin{table}[p]% +% \caption{This is a continued table.}% +% \label{tab:Two}% +% \begin{center}% +% \subtable[\label{tab:Two}]{\figbox{Subtable 2A}}% +% \quad +% \subtable[\label{tab:Two}]{\figbox{Subtable 2B}}\\ +% \subtable[\label{tab:Two}]{\figbox{Subtable 2C}}% +% \quad +% \subtable[\label{tab:Two}]{\figbox{Subtable 2D}}% +% \end{center}% +% \end{table} +% +% \begin{table}[p]% +% \captcont*{This is a continued table (cont.)}% +% \begin{center}% +% \subtable[\label{tab:Two}]{\figbox{Subtable 2E}}% +% \quad +% \subtable[\label{tab:Two}]{\figbox{Subtable 2F}}\\ +% \subtable[\label{tab:Two}]{\figbox{Subtable 2G}}% +% \quad +% \subtable[\label{tab:Two}]{\figbox{Subtable 2H}}% +% \end{center}% +% \end{table} +% +% \begin{table}[p]% +% \captcont*{This is a continued table (cont.)}% +% \begin{center}% +% \subtable[\label{tab:Two}]{\figbox{Subtable 2I}}% +% \quad +% \subtable[\label{tab:Two}]{\figbox{Subtable 2J}}\\ +% \subtable[\label{tab:Two}]{\figbox{Subtable 2K}}% +% \quad +% \subtable[\label{tab:Two}]{\figbox{Subtable 2L}}% +% \end{center}% +% \end{table} +% \end{verbatim} +% +% \clearpage ^finalhack +% +% \StopEventually{^ +% \newpage ^finalhack +% \section*{Acknowledgement} +% I wish to thank William 'bil' L. Kleb (w.l.kleb@larc.nasa.gov) for +% his willingness to proofread this document and his many valuable +% suggestions as to its improvement. +% +% \begin{thebibliography}{6}^ +% \bibitem{Coch02}^ +% Steven Douglas Cochran, +% \emph{The \Lpack{subfigure} Package}, +% 2002/02/14/. +% (Available from CTAN as file \texttt{subfigure.dtx}) +% \bibitem{Carl00}^ +% David Carlisle, +% \emph{The \Lpack{longtable} package}, +% 2000/10/22. +% (Available from CTAN as file \texttt{longtable.dtx}) +% \bibitem{Braa-Jurr99}^ +% Johannes Braams and Theo Jurriens, +% \emph{The \Lpack{supertabular} environment}, +% 1999/08/07. +% (Available from CTAN as file \texttt{supertabular.dtx}) +% \end{thebibliography}} +% +% \section{The Code} +% \iffalse +%<*package> +% \fi +% \subsection{Identification} +% +% We start off by checking that we are loading into \LaTeXe\ and +% announcing the name and version of this package. +% +% \begin{macrocode} +\NeedsTeXFormat{LaTeX2e}[1994/12/01] +\ProvidesPackage{captcont}[2002/02/14 v2.0 captcont package] +% \end{macrocode} +% +% \subsection{Declaration and Execution of the Options} +% +% \begin{macro}{\iffiguretopcap} +% \begin{macro}{\iftabletopcap} +% +% First we check if the flags \Lif{figuretopcap} and \Lif{tabletopcap} +% exist; if they are not present, than they are created. These are used +% to remember the options and are also the same internal |\if|'s used by +% the \Lpack{subfigure} package for this purpose and so we check if the +% \Lpack{subfigure} package has already been loaded (by the existance of +% the |\@subfloat| command and if so, then we entirely skip loading the +% options. +% +% However if the \Lpack{subfigure} package has not been loaded, we check +% for the options below and set the two |\if|'s accordingly. By default +% \Lif{figuretopcap} is set false and \Lif{tabletopcap} is set true. If +% the \Lpack{subfigure} package is loaded later, then it will override +% any settings made here! +% +% \begin{macrocode} +\@ifundefined{figuretopcaptrue}{\newif\iffiguretopcap}{} +\@ifundefined{tabletopcaptrue}{\newif\iftabletopcap}{} +\@ifundefined{@subfloat}{% + \DeclareOption{figbotcap}{\figuretopcapfalse} + \DeclareOption{figtopcap}{\figuretopcaptrue} + \DeclareOption{tabbotcap}{\tabletopcapfalse} + \DeclareOption{tabtopcap}{\tabletopcaptrue} + \ExecuteOptions{figbotcap,tabtopcap} + \ProcessOptions}{} +% \end{macrocode} +% \end{macro} +% \end{macro} +% +% \subsection{The Updated \cmd{\caption} Commands} +% +% \begin{macro}{\caption} +% \begin{macro}{\caption*} +% \begin{macro}{\cc@caption} +% +% First, we save the current |\caption| command as |\cc@caption|. Then +% we redefine |\caption| to check for a trailing `*' so that we can +% choose the regular caption (|\cc@caption|) for a special caption +% (|\cc@scaption|) that does not add a line to the ``List-of'' pages. +% +% \begin{macrocode} +\let\cc@caption=\caption +% \end{macrocode} +% +% \begin{macrocode} +\renewcommand{\caption}{% + \@ifstar\cc@scaption\cc@caption} +% \end{macrocode} +% +% \end{macro} +% +% \begin{macro}{\cc@scaption} +% \begin{macro}{\cc@@scaption} +% +% Next, we define the |\cc@scaption| and |\cc@@scaption| commands to do +% everything that the regular |\caption| command would have done, except +% for adding a line to the ``List-of'' pages. +% +% If |\@captype| is undefined, then write out an error and `eat' ({\it +% i.e.\/}, throw away) the argument(s). Otherwise, add one to the +% \Lcount{figure} or \Lcount{table} counter and define the +% |\@currentreference|, then call |\cc@@scaption| with the expanded +% arguments. +% +% Note that we allow an optional argument for the |\cc@@scaption| even +% though this will never be used. The reason for this is to allow the +% shift from |\caption| to |\caption*| or back, when deciding if +% something should or should not be shown in the ``List-of'' +% pages, to be done with just the addition or removal of the `*'. +% +% \begin{macrocode} +\newcommand{\cc@scaption}{% + \ifx\@captype\@undefined + \@latex@error{\noexpand\caption* outside float}\@ehd + \expandafter\@gobble + \else + \refstepcounter\@captype + \expandafter\@firstofone + \fi + {\@dblarg{\cc@@scaption\@captype}}} +% \end{macrocode} +% +% We add a |\par| to end the current horizontal list, then we normalize +% the paragraph setting parameters, however we call |\@setminipage| if +% the |\if@minipage| is still true to enable |\everypar| to make it +% false later. (This is the case if the |\caption| is not the first +% entry in the \Lenv{float}) environment. +% +% \begin{macrocode} +\long\def\cc@@scaption#1[#2]#3{% + \par + \begingroup + \@parboxrestore + \if@minipage + \@setminipage + \fi +% \end{macrocode} +% +% Next |\normalsize| is restored (we just assume something else was set) +% and we typeset the caption followed by another |\par|. Unlike the +% regular |\caption| command, we skipped adding a line to the +% List-of-Figures or List-of-Tables. +% +% \begin{macrocode} + \normalsize + \@makecaption{\@nameuse{fnum@#1}}{\ignorespaces #3}\par + \endgroup} +% \end{macrocode} +% +% \end{macro} +% \end{macro} +% \end{macro} +% \end{macro} +% +% \subsection{Work with the \cmd{\label}/\cmd{\ref} Mechanism} +% \begin{macro}{\ccset@currentlabel} +% +% We define this command to conditionally increment the \Lcount{figure} or +% \Lcount{table} counter according to the respective flag telling us if +% the |\caption| is normally placed before or after the figure or table. +% Then globally reset the \@currentlabel for use with the |\label| +% command. +% +% Note that this leaves the counter with a possibly incorrect setting, +% so this should be used within a group to limit it's scope. +% +% \begin{macrocode} +\newcommand{\ccset@currentlabel}[1]{% + \@nameuse{if\@captype topcap}\else + \advance\@nameuse{c@\@captype}\@ne + \fi + \global\edef\@currentlabel{% + \@nameuse{p@#1}\@nameuse{the#1}}} +% \end{macrocode} +% \end{macro} +% +% \subsection{The New Caption Continuation Commands} +% \enlargethispage{-12pt} ^ finalhack +% +% \begin{macro}{\captcont} +% \begin{macro}{\captcont*} +% +% The |\captcont| and |\captcont*| commands are just like the +% corresponding |\caption| and |\caption*| command, except that they do +% not cause the \Lcount{figure} or \Lcount{table} counters to be +% incremented. +% +% The first step is to check for a following `*' to decide if an entry +% on the ``List-of'' page is to be made. The `*' version does +% not add an entry. +% +% \begin{macrocode} +\newcommand{\captcont}{% + \@ifstar\cc@scaptcont\cc@captcont} +% \end{macrocode} +% +% \begin{macro}{\cc@captcont} +% \begin{macro}{\cc@scaptcont} +% +% Next, we define the |\cc@captcont| and |\cc@scaptcont| commands to check +% to insure that we are inside a \Lenv{float} environemnt. If not, then +% we report an error and exit. Otherwise we call the respective +% |\cc@@captcont| or |\cc@@scaptcont| command to finish the processing, +% without changing the current coutner value or updating the +% |\@currentreference| value. Those will be done locally, as necessary, +% in the following commands. +% +% Note that we have an optional argument for the |\cc@@scaptcont| even +% though this will never be used. The reason for this, as above, is to +% allow the shift from |\captcont| to |\captcont*| or back to be done +% with just the addition or removal of the `*' when deciding if +% something should or should not be shown in the ``List-of'' +% pages. +% +% \begin{macrocode} +\newcommand{\cc@captcont}{% + \ifx\@captype\@undefined + \@latex@error{\noexpand\captcont outside float}\@ehd + \expandafter\@gobble + \else + \expandafter\@firstofone + \fi + {\@dblarg{\cc@@captcont\@captype}}} +% \end{macrocode} +% +% \end{macro} +% +% \begin{macrocode} +\newcommand{\cc@scaptcont}{% + \ifx\@captype\@undefined + \@latex@error{\noexpand\captcont* outside float}\@ehd + \expandafter\@gobble + \else + \expandafter\@firstofone + \fi + {\@dblarg{\cc@@scaptcont\@captype}}} +% \end{macrocode} +% +% \end{macro} +% +% \begin{macro}{\cc@@captcont} +% \begin{macro}{\cc@@scaptcont} +% +% These two commands do the real work and finish up the ``captcont'' +% processing. They both insert a |\par| to finish off the prior +% horizontal list (if any) and then {\bf locally} update the +% \Lcount{figure} or \Lcount{table} counter (if necessary) and {\bf +% globally} set the |\@currentlabel| value using |\ccset@currentlabel|, +% defined above. +% +% The difference between them is that |\cc@@captcont| then writes to the +% ``List-of'' page, while |\cc@@scaptcont| does not. They both +% then finish just like the |\cc@@scaption| command, by resetting the +% paragraph and font parameters and then calling |\@makecaption| to +% typeset the caption followed by a |\par|. +% +% \begin{macrocode} +\long\def\cc@@captcont#1[#2]#3{% + \par + \begingroup + \ccset@currentlabel{#1}% + \addcontentsline{\@nameuse{ext@#1}}{#1}% + {\protect\numberline{\@nameuse{the#1}}{\ignorespaces #2}}% + \@parboxrestore + \if@minipage + \@setminipage + \fi + \normalsize + \@makecaption{\@nameuse{fnum@#1}}{\ignorespaces #3}\par + \endgroup} +% \end{macrocode} +% +% \end{macro} +% +% \begin{macrocode} +\long\def\cc@@scaptcont#1[#2]#3{% + \par + \begingroup + \ccset@currentlabel{#1}% + \@parboxrestore + \if@minipage + \@setminipage + \fi + \normalsize + \@makecaption{\@nameuse{fnum@#1}}{\ignorespaces #3}\par + \endgroup} +% \end{macrocode} +% \end{macro} +% \end{macro} +% \end{macro} +% +% \iffalse +% +% \fi +% +% \Finale +% diff --git a/macros/latex/contrib/captcont/captcont.ins b/macros/latex/contrib/captcont/captcont.ins new file mode 100644 index 0000000000..5f0fbe3f14 --- /dev/null +++ b/macros/latex/contrib/captcont/captcont.ins @@ -0,0 +1,57 @@ +%% +%% This is file `captcont.ins', the installation file for the +%% `captcont' package. +%% +%% Copyright (C) 1996-2002 Steven Douglas Cochran. +%% +%% The captcont package is free software; it may be distributed under the +%% conditions of the LaTeX Project Public License, either version 1.2 of +%% this license or (at your option) any later version. The latest version +%% of this license is in: +%% http://www.latex-project.org/lppl.txt +%% and version 1.2 or later is part of all distributions of LaTeX version +%% 1999/09/03 or later. +%% +%% The captcont package is distributed in the hope that it will be +%% useful, but WITHOUT ANY WARRANTY; without even the implied warranty +%% of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +%% LaTeX Project Public License for more details. +%% +\def\batchfile{captcont.ins} +\input docstrip.tex + +\keepsilent +\generateFile{ltxdoc.cfg}{t}{\from{captcont.dtx}{ltxdoc}} + +\preamble + +Copyright (C) 1996-2002 Steven Douglas Cochran. + +This file is NOT the source for captcont, because almost all comments +have been stripped from it. It is NOT the preferred form of captcont +for making modifications to it. + +Therefore you can NOT redistribute and/or modify THIS file. You can +however redistribute the complete source (captcont.dtx and +captcont.ins) and/or modify it under the terms of the LaTeX Project +Public License, either version 1.2 of this license or (at your option) +any later version. The latest version of this license is in: + http://www.latex-project.org/lppl.txt +and version 1.2 or later is part of all distributions of LaTeX version +1999/09/03 or later. + +The captcont package is distributed in the hope that it will be +useful, but WITHOUT ANY WARRANTY; without even the implied warranty +of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +LaTeX Project Public License for more details. + +\endpreamble +\generateFile{captcont.sty}{t}{\from{captcont.dtx}{package}} + +\Msg{***********************************************************} +\Msg{* To finish the installation you have to move the file} +\Msg{* `captcont.sty' into a directory searched by TeX.} +\Msg{*} +\Msg{* To produce the documentation run the file `captcont.dtx'} +\Msg{* through LaTeX.} +\Msg{***********************************************************} diff --git a/macros/latex/contrib/captcont/captcont.pdf b/macros/latex/contrib/captcont/captcont.pdf new file mode 100644 index 0000000000..af6f1a5ba0 Binary files /dev/null and b/macros/latex/contrib/captcont/captcont.pdf differ diff --git a/macros/latex/contrib/captcont/test.tex b/macros/latex/contrib/captcont/test.tex new file mode 100644 index 0000000000..d463613e61 --- /dev/null +++ b/macros/latex/contrib/captcont/test.tex @@ -0,0 +1,288 @@ +\documentclass{article} +%\usepackage{caption} +%\usepackage{caption2} +%\usepackage{ccaption} +\usepackage{captcont} +%\usepackage{caption} +%\usepackage{caption2} +%\usepackage{ccaption} +\usepackage[TABTOPCAP]{subfigure} +%\usepackage{caption} +%\usepackage{caption2} +%\usepackage{ccaption} + +\newcommand{\figbox}[1]{% + \fbox{% + \vbox to .6in{% + \vfil + \hbox to .8in{% + \hfil + #1% + \hfil}% + \vfil}}} +\newcommand{\bigfigbox}[1]{% + \fbox{% + \vbox to 6in{% + \vfil + \hbox to 4in{% + \hfil + #1% + \hfil}% + \vfil}}} +\makeatletter +\def\subfigtopskip{4pt} +\def\subfigbottomskip{4pt} +\def\subfigcapskip{2pt} +\subtabletopcaptrue + +\begin{document} + +\setcounter{lofdepth}{2} +\listoffigures +\clearpage +\setcounter{lotdepth}{2} +\listoftables +\clearpage + +First we test the regular figures. The first figure is +Figure~\ref{fig:First} on page \pageref{fig:First}. The second is +Figure~\ref{fig:SecondA} and appears on pages~\pageref{fig:SecondA}, +\pageref{fig:SecondB}, \pageref{fig:SecondC}, and \pageref{fig:SecondD}. + +\begin{figure}% + \begin{center}% + \bigfigbox{Regular figure 1}% + \end{center}% + \vspace{-10pt}% + \caption{Regular figure 1}% + \label{fig:First}% +\end{figure} + +\begin{figure}% + \begin{center}% + \bigfigbox{Continued figure 2A}% + \end{center}% + \vspace{-10pt}% + \captcont{Continued figure 2A}% + \label{fig:SecondA}% +\end{figure} + +\begin{figure}% + \begin{center}% + \bigfigbox{Continued figure 2B}% + \end{center}% + \vspace{-10pt}% + \captcont*{Continued figure 2B}% + \label{fig:SecondB}% +\end{figure} + +\begin{figure}% + \begin{center}% + \bigfigbox{Continued figure 2C}% + \end{center}% + \vspace{-10pt}% + \captcont*{Continued figure 2C}% + \label{fig:SecondC}% +\end{figure} + +\begin{figure}% + \begin{center}% + \bigfigbox{Continued figure 2D} + \end{center}% + \vspace{-10pt}% + \caption*{Continued figure 2D} + \label{fig:SecondD}% +\end{figure} + + +Then we test the regular tables. The first table is +Table~\ref{tab:First} on page \pageref{tab:First}. The second is +Table~\ref{tab:SecondA} and appears on pages~\pageref{tab:SecondA}, +\pageref{tab:SecondB}, \pageref{tab:SecondC}, and \pageref{tab:SecondD}. + +\begin{table}% + \caption{Regular table 1}% + \label{tab:First}% + \begin{center}% + \bigfigbox{Regular table 1}% + \end{center}% +\end{table} + +\begin{table}% + \caption{Continued table 2A}% + \label{tab:SecondA}% + \begin{center}% + \bigfigbox{Continued table 2A}% + \end{center}% +\end{table} + +\begin{table}% + \captcont*{Continued table 2B}% + \label{tab:SecondB}% + \begin{center}% + \bigfigbox{Continued table 2B}% + \end{center}% +\end{table} + +\begin{table}% + \captcont*{Continued table 2C}% + \label{tab:SecondC}% + \begin{center}% + \bigfigbox{Continued table 2C}% + \end{center}% +\end{table} + +\begin{table}% + \captcont*{Continued table 2D} + \label{tab:SecondD}% + \begin{center}% + \bigfigbox{Continued table 2D} + \end{center}% +\end{table} + +Next we look at the subfigures in a simple figure. They are +Figures~\ref{fig:sub1A}, \ref{fig:sub1B}, \ref{fig:sub1C}, and +\ref{fig:sub1D}, which are part of Figure~\ref{fig:sub1} on +page~\pageref{fig:sub1}. + +The continued subfigures are contained in three parts. The first is +Figure~\ref{fig:sub21} on page~\pageref{fig:sub21} which contains the +Subfigures~\ref{fig:sub2A}, \ref{fig:sub2B}, \ref{fig:sub2C}, and +\ref{fig:sub2D}. +The second is +Figure~\ref{fig:sub22} on page~\pageref{fig:sub22} which contains the +Subfigures~\ref{fig:sub2E}, \ref{fig:sub2F}, \ref{fig:sub2G}, and +\ref{fig:sub2H}. +The third is +Figure~\ref{fig:sub23} on page~\pageref{fig:sub23} which contains the +Subfigures~\ref{fig:sub2I}, \ref{fig:sub2J}, \ref{fig:sub2K}, and +\ref{fig:sub2L}. + +\begin{figure}% + \begin{center}% + \subfigure[\label{fig:sub1A}]{\figbox{Subfigure 1A}}% + \hspace{10pt}% + \subfigure[\label{fig:sub1B}]{\figbox{Subfigure 1B}}\\ + \subfigure[\label{fig:sub1C}]{\figbox{Subfigure 1C}}% + \hspace{10pt}% + \subfigure[\label{fig:sub1D}]{\figbox{Subfigure 1D}}% + \end{center}% + \vspace{-10pt}% + \caption{This is a simple figure.}% + \label{fig:sub1}% +\end{figure} + +\begin{figure}% + \begin{center}% + \subfigure[\label{fig:sub2A}]{\figbox{Subfigure 2A}}% + \hspace{10pt}% + \subfigure[\label{fig:sub2B}]{\figbox{Subfigure 2B}}\\ + \subfigure[\label{fig:sub2C}]{\figbox{Subfigure 2C}}% + \hspace{10pt}% + \subfigure[\label{fig:sub2D}]{\figbox{Subfigure 2D}}% + \end{center}% + \vspace{-10pt}% + \captcont{This is a continued figure.}% + \label{fig:sub21}% +\end{figure} + +\begin{figure}% + \begin{center}% + \subfigure[\label{fig:sub2E}]{\figbox{Subfigure 2E}}% + \hspace{10pt}% + \subfigure[\label{fig:sub2F}]{\figbox{Subfigure 2F}}\\ + \subfigure[\label{fig:sub2G}]{\figbox{Subfigure 2G}}% + \hspace{10pt}% + \subfigure[\label{fig:sub2H}]{\figbox{Subfigure 2H}}% + \end{center}% + \vspace{-10pt}% + \captcont*{This is a continued figure (cont.)}% + \label{fig:sub22}% +\end{figure} + +\begin{figure}% + \begin{center}% + \subfigure[\label{fig:sub2I}]{\figbox{Subfigure 2I}}% + \hspace{10pt}% + \subfigure[\label{fig:sub2J}]{\figbox{Subfigure 2J}}\\ + \subfigure[\label{fig:sub2K}]{\figbox{Subfigure 2K}}% + \hspace{10pt}% + \subfigure[\label{fig:sub2L}]{\figbox{Subfigure 2L}}% + \end{center}% + \vspace{-10pt}% + \caption*{This is a continued figure (cont.)}% + \label{fig:sub23}% +\end{figure} + +Next we look at the subtables in a simple table environment. They are +Tables~\ref{tab:sub1A}, \ref{tab:sub1B}, \ref{tab:sub1C}, and +\ref{tab:sub1D}, which are part of Table~\ref{tab:sub1} on +page~\pageref{tab:sub1}. + +The continued subtables are contained in three parts. The first is +Table~\ref{tab:sub21} on page~\pageref{tab:sub21} which contains the +Subtables~\ref{tab:sub2A}, \ref{tab:sub2B}, \ref{tab:sub2C}, and +\ref{tab:sub2D}. +The second is +Table~\ref{tab:sub22} on page~\pageref{tab:sub22} which contains the +Subtables~\ref{tab:sub2E}, \ref{tab:sub2F}, \ref{tab:sub2G}, and +\ref{tab:sub2H}. +The third is +Table~\ref{tab:sub23} on page~\pageref{tab:sub23} which contains the +Subtables~\ref{tab:sub2I}, \ref{tab:sub2J}, \ref{tab:sub2K}, and +\ref{tab:sub2L}. + +\begin{table}% + \caption{This is a simple table.}% + \label{tab:sub1}% + \begin{center}% + \subtable[\label{tab:sub1A}]{\figbox{Subtable 1A}}% + \hspace{10pt}% + \subtable[\label{tab:sub1B}]{\figbox{Subtable 1B}}\\ + \subtable[\label{tab:sub1C}]{\figbox{Subtable 1C}}% + \hspace{10pt}% + \subtable[\label{tab:sub1D}]{\figbox{Subtable 1D}}% + \end{center}% +\end{table} + +\begin{table}% + \caption{This is a continued table.}% + \label{tab:sub21}% + \begin{center}% + \subtable[\label{tab:sub2A}]{\figbox{Subtable 2A}}% + \hspace{10pt}% + \subtable[\label{tab:sub2B}]{\figbox{Subtable 2B}}\\ + \subtable[\label{tab:sub2C}]{\figbox{Subtable 2C}}% + \hspace{10pt}% + \subtable[\label{tab:sub2D}]{\figbox{Subtable 2D}}% + \end{center} +\end{table} + +\begin{table}% + \captcont*{This is a continued table (cont.)}% + \label{tab:sub22}% + \begin{center}% + \subtable[\label{tab:sub2E}]{\figbox{Subtable 2E}}% + \hspace{10pt}% + \subtable[\label{tab:sub2F}]{\figbox{Subtable 2F}}\\ + \subtable[\label{tab:sub2G}]{\figbox{Subtable 2G}}% + \hspace{10pt}% + \subtable[\label{tab:sub2H}]{\figbox{Subtable 2H}}% + \end{center}% +\end{table} + +\begin{table}% + \captcont*{This is a continued table (cont.)}% + \label{tab:sub23}% + \begin{center}% + \subtable[\label{tab:sub2I}]{\figbox{Subtable 2I}}% + \hspace{10pt}% + \subtable[\label{tab:sub2J}]{\figbox{Subtable 2J}}\\ + \subtable[\label{tab:sub2K}]{\figbox{Subtable 2K}}% + \hspace{10pt}% + \subtable[\label{tab:sub2L}]{\figbox{Subtable 2L}}% + \listsubcaptions + \end{center}% +\end{table} + +\end{document} -- cgit v1.2.3