summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/floatrow/sample-longtable.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/doc/latex/floatrow/sample-longtable.tex')
-rw-r--r--Master/texmf-dist/doc/latex/floatrow/sample-longtable.tex198
1 files changed, 80 insertions, 118 deletions
diff --git a/Master/texmf-dist/doc/latex/floatrow/sample-longtable.tex b/Master/texmf-dist/doc/latex/floatrow/sample-longtable.tex
index 10195f2fe28..8430d32f269 100644
--- a/Master/texmf-dist/doc/latex/floatrow/sample-longtable.tex
+++ b/Master/texmf-dist/doc/latex/floatrow/sample-longtable.tex
@@ -10,7 +10,8 @@
% and ``Finishing of table 1.'' (Is that correct English form?)
\begin{filecontents}{s-longtable.tex}
\begin{longtable}{@{}lll}
-\caption{The ISOGRK3 entity set and more more more more more more more more more more more more more more more more more more text}\\
+\caption{The ISOGRK3 entity set and more more more more more more more more more
+ more more more more more more more more more text}\\
\bfseries Entity&\bfseries Unicode Name&\bfseries Unicode\\ \hline
\endfirsthead
\LTcontcaption{}\\
@@ -221,33 +222,33 @@ zeta & SMALL LETTER ZETA & 03B6\\
\advance\evensidemargin-.25in
\advance\oddsidemargin-.25in
+\usepackage[labelsep=newline]{caption}
\usepackage{floatrow}
+\providecommand\floatsetup[2][]{}
\usepackage{array,fr-longtable}
-\usepackage[labelsep=newline]{caption}
\floatsetup[longtable]{font={small,sf},LTcapwidth=table,margins=centering,
captionskip=5pt}
-\captionsetup[longtable]{font={small,rm}}
+\captionsetup[longtable]{font=small}
-\DeclareCaptionLabelFormat{LTrightlabelcont}%
- {\rightline{\bothIfFirst{#1}{ }#2\ContTable}}
-\DeclareCaptionLabelFormat{labelcont}%
- {\rightline{\bothIfFirst{\ContTable}{ }#2}}
-%
-% Then define text for continued/finished table head, \ldots
-\newcommand\ContTable{}
+\DeclareCaptionLabelFormat{labelcontI}%
+ {\rightline{\bothIfFirst{#1}{ }#2 (\emph{continued})}}
+\DeclareCaptionLabelFormat{labelfinI}%
+ {\rightline{\bothIfFirst{#1}{ }#2 (\emph{finished})}}
+
+\DeclareCaptionLabelFormat{labelcontIII}%
+ {\rightline{\emph{Continuation of \tablename} #2}}
+\DeclareCaptionLabelFormat{labelfinIII}%
+ {\rightline{\emph{Finishing of \tablename} #2}}
%
-% caption for continued head, \ldots
+% Caption for continued head, \ldots
\newcommand\LTcontcaptionI[1]{%
- \noalign{\gdef\ContTable{\captioncontinued}}
- \caption[]{#1}}
+ \captionsetup{labelformat=labelcontI}\caption[]{#1}}
%
-% and caption for finished head. (At the |\lastfoot| definition the |\ContTable|
-% must be defined as empty).
+% and caption for finished head.
\newcommand\LTfincaptionI[1]{%
- \noalign{\gdef\ContTable{\captionfinished}}
- \caption[]{#1}}
+ \captionsetup{labelformat=labelfinI}\caption[]{#1}}
%
-% caption for continued head, \ldots
+% Caption for continued head, \ldots
\newcommand\LTcontcaptionII{%
\caption[]{\emph{Continued}}}
%
@@ -255,24 +256,13 @@ zeta & SMALL LETTER ZETA & 03B6\\
\newcommand\LTfincaptionII{%
\caption[]{\emph{Finished}}}
%
-% caption for continued head, \ldots
+% Caption for continued head, \ldots
\newcommand\LTcontcaptionIII[1]{%
- \noalign{\gdef\ContTable{\emph{Continuation of \tablename}}}
- \caption[]{#1}}
+ \captionsetup{labelformat=labelcontIII}\caption[]{#1}}
%
-% and caption for finished head. (At the |\lastfoot| definition the
-% |\ContTable| must be defined as empty).
+% and caption for finished head.
\newcommand\LTfincaptionIII[1]{%
- \noalign{\gdef\ContTable{\emph{Finishing of \tablename}}}
- \caption[]{#1}}
-
-%
-% The examples of continued and finished heads.
-\newcommand\captioncontinued{. \emph{Continued}}
-\newcommand\captionfinished{. \emph{Finished}}
-
-%
-% Then define text for continued/finished table head, \ldots
+ \captionsetup{labelformat=labelfinIII}\caption[]{#1}}
\begin{document}
@@ -286,71 +276,48 @@ The common settings:
\begin{quote}\obeylines\parskip0pt
\verb|\floatsetup[longtable]{font={small,sf},LTcapwidth=table,|
\verb| margins=centering,captionskip=5pt}|
-\verb|\captionsetup[longtable]{font={small,rm}}|
+\verb|\captionsetup[longtable]{font=small}|
+\end{quote}
+Here table font family settings are different from caption. The version 3.1 of
+\textsf{caption} package solves this problem.
+But for the version 3.0q you ought restore Roman family settings |rm|.
+
+
+\section{Variant~I}
+
+For the first variant the following label format was defined:
+\begin{quote}\obeylines\parskip0pt
+\verb|\DeclareCaptionLabelFormat{labelcontI}%|
+\verb| {\rightline{\bothIfFirst{#1}{ }#2 (\emph{continued})}}|
+\verb|\DeclareCaptionLabelFormat{labelfinI}%|
+\verb| {\rightline{\bothIfFirst{#1}{ }#2 (\emph{finished})}}|
\end{quote}
-Here table font family settings are different from caption. In this case
-font family settings were loaded in both setups.
The body of long table is written in following way:
\begin{quote}\obeylines\parskip0pt
\verb|\begin{longtable}{@{}lll}|
\verb|\caption{The ISOGRK3 entity set and more more more more more more|
-\verb| more more more more more more more more more more more text}\\|
-\verb| \bfseries Entity&\bfseries Unicode Name&\bfseries Unicode\\|
+\verb| more more more more more more more more more more more text}\\|
+\verb| \bfseries Entity &\bfseries Unicode Name&\bfseries Unicode\\|
\verb|\hline|
\verb|\endfirsthead|
-\verb|\LTcontcaption{}\\|
-\verb| \bfseries Entity&\bfseries Unicode Name&\bfseries Unicode\\|
+\verb|\captionsetup{labelformat=labelcontI}\caption[]{}\\|
+\verb| \bfseries Entity &\bfseries Unicode Name&\bfseries Unicode\\|
\verb|\hline|
\verb|\endhead|
-\verb|\LTfincaption{}\\|
-\verb| \bfseries Entity&\bfseries Unicode Name&\bfseries Unicode\\|
+\verb|\captionsetup{labelformat=labelfinI}\caption[]{}\\|
+\verb| \bfseries Entity &\bfseries Unicode Name&\bfseries Unicode\\|
\verb|\hline|
\verb|\endlasthead|
\verb| \hline \multicolumn{3}{@{}r@{}}{\emph{Continued on next page}}|
\verb|\endfoot|
-\verb| \hline \multicolumn{3}{@{}r@{}}{\emph{Finished on next page}}|
+\verb| \hline \multicolumn{3}{@{}r@{}}{\emph{Finished on next page}}|
\verb|\endprelastfoot|
-\verb|\noalign{\gdef\Continued{}\gdef\ContTable{}}|
\verb| \hline|
\verb|\endlastfoot|
\end{quote}
-At the \verb|\lastfoot| set definitions of macros \verb|\Continued| and
-\verb|\ContTable| globally emptied.
-
-Besides of \verb|\endlasthead| command defined by \textsf{fr-longtable} package for
-last head of table and \verb|\endprelastfoot|---for foot before last, there are
-defined two special commands for captions: \verb|\LTcontcaption|---for continued pages
-and \verb|\LTfincaption| for finishing page in this sample file. In the three examples
-below they are defined in different way.
-
-\section{Variant~I}
-
-For the first variant defined the label format \texttt{LTrightlabelcont}
-(it will be defined for long table in group):
-\begin{quote}\obeylines\parskip0pt
-\verb|\DeclareCaptionLabelFormat{LTrightlabelcont}%|
-\verb| {\rightline{\bothIfFirst{#1}{ }#2\ContTable}}|
-\end{quote}
-
-These definitions are loaded in \verb|\LTcontcaption| and \verb|\LTfincaption| macros:
-caption for continued head:
-\begin{quote}\obeylines\parskip0pt
-\verb|\newcommand\LTcontcaption[1]{%|
-\verb| \noalign[]{\gdef\ContTable{\captioncontinued}}|
-\verb| \caption{#1}}|
-\end{quote}
-and caption for finished head:
-\begin{quote}\obeylines\parskip0pt
-\verb|\newcommand\LTfincaption[1]{%|
-\verb| \noalign[]{\gdef\ContTable{\captionfinished}}|
-\verb| \caption{#1}}|
-\end{quote}
-The \verb|\captioncontinued| and \verb|\captionfinished| commands define words
-``Continued'' and ``Finished'' consequently.
\begingroup
-\captionsetup[longtable]{labelformat=LTrightlabelcont}
\floatsetup[longtable]{font={Large,sf}}
%\def\LTlastpage{5}
\let\LTcontcaption\LTcontcaptionI
@@ -362,47 +329,32 @@ The \verb|\captioncontinued| and \verb|\captionfinished| commands define words
\clearpage
\section{Variant~II}
-For the second there
-are loaded definitions of \verb|\LTcontcaption| and \verb|\LTfincaption| macros:
-caption for continued head:
-\begin{quote}\obeylines\parskip0pt
-\verb|\newcommand\LTcontcaption{%|
-\verb| \caption[]{\emph{Continued}}}|
-\end{quote}
-and caption for finished head:
-\begin{quote}\obeylines\parskip0pt
-\verb|\newcommand\LTfincaption{%|
-\verb| \caption[]{\emph{Finished}}}|
-\end{quote}
-The words
-``Continued'' and ``Finished'' defined in \verb|\LTcontcaption| and \verb|\LTfincaption|
-macros.
-
-You may see that usage of \verb|\LTcontcaption| and \verb|\LTfincaption| is rather unnecessary. And preamble of \textsf{longtable} could be
+You may see that usage of \verb|labelformat| key here is unnecessary.
+And preamble of the \textsf{longtable} looks like:
\begin{quote}\obeylines\parskip0pt
\verb|\begin{longtable}{@{}lll}|
\verb|\caption{The ISOGRK3 entity set and more more more more more more|
-\verb| more more more more more more more more more more more text}\\|
-\verb| \bfseries Entity&\bfseries Unicode Name&\bfseries Unicode\\|
+\verb| more more more more more more more more more more more text}\\|
+\verb| \bfseries Entity &\bfseries Unicode Name&\bfseries Unicode\\|
\verb|\hline|
\verb|\endfirsthead|
\verb|\caption[]{\emph{Continued}}\\|
-\verb| \bfseries Entity&\bfseries Unicode Name&\bfseries Unicode\\|
+\verb| \bfseries Entity &\bfseries Unicode Name&\bfseries Unicode\\|
\verb|\hline|
\verb|\endhead|
\verb|\caption[]{\emph{Finished}}\\|
-\verb| \bfseries Entity&\bfseries Unicode Name&\bfseries Unicode\\|
+\verb| \bfseries Entity &\bfseries Unicode Name&\bfseries Unicode\\|
\verb|\hline|
\verb|\endlasthead|
\verb| \hline \multicolumn{3}{@{}r@{}}{\emph{Continued on next page}}|
\verb|\endfoot|
-\verb| \hline \multicolumn{3}{@{}r@{}}{\emph{Finished on next page}}|
+\verb| \hline \multicolumn{3}{@{}r@{}}{\emph{Finished on next page}}|
\verb|\endprelastfoot|
-\verb|\noalign{\gdef\Continued{}\gdef\ContTable{}}|
\verb| \hline|
\verb|\endlastfoot|
\end{quote}
+
\begingroup
\captionsetup[table]{labelsep=period,singlelinecheck=no}
%\def\LTlastpage{5}
@@ -415,29 +367,39 @@ You may see that usage of \verb|\LTcontcaption| and \verb|\LTfincaption| is rath
\clearpage
\section{Variant~III}
-For the first variant defined the label format \texttt{LTrightlabelcont}
-(it will be defined for long table in group):
+For the last variant the following label format was defined in preamble:
\begin{quote}\obeylines\parskip0pt
-\verb|\DeclareCaptionLabelFormat{labelcont}%|
-\verb| {\rightline{\bothIfFirst{\ContTable}{ }#2}}|
+\verb|\DeclareCaptionLabelFormat{labelcontIII}%|
+\verb| {\rightline{\emph{Continuation of \tablename} #2}}|
+\verb|\DeclareCaptionLabelFormat{labelfinIII}%|
+\verb| {\rightline{\emph{Finishing of \tablename} #2}}|
\end{quote}
-There are definitions of \verb|\LTcontcaption| and \verb|\LTfincaption| macros:
-caption for continued head:
-\begin{quote}\obeylines\parskip0pt
-\verb|\newcommand\LTcontcaptionIII[1]{%|
-\verb| \noalign{\gdef\ContTable{\emph{Continuation of \tablename}}}|
-\verb| \caption[]{#1}}|
-\end{quote}
-and caption for finished head:
+The body of long table is written in following way:
\begin{quote}\obeylines\parskip0pt
-\verb|\newcommand\LTfincaptionIII[1]{%|
-\verb| \noalign{\gdef\ContTable{\emph{Finishing of \tablename}}}|
-\verb| \caption[]{#1}}|
+\verb|\begin{longtable}{@{}lll}|
+\verb|\caption{The ISOGRK3 entity set and more more more more more more|
+\verb| more more more more more more more more more more more text}\\|
+\verb| \bfseries Entity &\bfseries Unicode Name&\bfseries Unicode\\|
+\verb|\hline|
+\verb|\endfirsthead|
+\verb|\captionsetup{labelformat=labelcontIII}\caption[]{}\\|
+\verb| \bfseries Entity &\bfseries Unicode Name&\bfseries Unicode\\|
+\verb|\hline|
+\verb|\endhead|
+\verb|\captionsetup{labelformat=labelfinIII}\caption[]{}\\|
+\verb| \bfseries Entity &\bfseries Unicode Name&\bfseries Unicode\\|
+\verb|\hline|
+\verb|\endlasthead|
+\verb| \hline \multicolumn{3}{@{}r@{}}{\emph{Continued on next page}}|
+\verb|\endfoot|
+\verb| \hline \multicolumn{3}{@{}r@{}}{\emph{Finished on next page}}|
+\verb|\endprelastfoot|
+\verb| \hline|
+\verb|\endlastfoot|
\end{quote}
\begingroup
-\captionsetup[table]{labelformat=labelcont}
\floatsetup[longtable]{font={scriptsize,sf}}
%\def\LTlastpage{5}
\let\scriptsize\tiny
@@ -452,4 +414,4 @@ and caption for finished head:
\listoftables
\end{document}
-\endinput \ No newline at end of file
+\endinput \ No newline at end of file