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/figsize/README | 57 ++++ macros/latex/contrib/figsize/epsfig.eps | 506 +++++++++++++++++++++++++++++++ macros/latex/contrib/figsize/figsize.pdf | Bin 0 -> 124517 bytes macros/latex/contrib/figsize/figsize.sty | 61 ++++ macros/latex/contrib/figsize/figsize.tex | 394 ++++++++++++++++++++++++ 5 files changed, 1018 insertions(+) create mode 100644 macros/latex/contrib/figsize/README create mode 100644 macros/latex/contrib/figsize/epsfig.eps create mode 100644 macros/latex/contrib/figsize/figsize.pdf create mode 100644 macros/latex/contrib/figsize/figsize.sty create mode 100644 macros/latex/contrib/figsize/figsize.tex (limited to 'macros/latex/contrib/figsize') diff --git a/macros/latex/contrib/figsize/README b/macros/latex/contrib/figsize/README new file mode 100644 index 0000000000..95bd153598 --- /dev/null +++ b/macros/latex/contrib/figsize/README @@ -0,0 +1,57 @@ + This is the README file for FigSize, + a LaTeX2e package for automatic graphics sizing + + Copyright (C) 2002 Anthony A. Tanbakuchi + atanbakuchi@hotmail.com + + +* Copyright +=========== + +This file is part of FigSize. + +FigSize may be distributed and/or modified under the conditions of +the LaTeX Project Public License, either version 1.1 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.1 or later is part of all distributions of LaTeX version +1999/06/01 or later. + +FigSize consists of the following files: + +- README (this file) +- figsize.sty +- figsize.tex +- figsize.pdf +- epsfig.eps + + +* Description +============= + +The FigSize package enables automatic sizing of graphics, +especially when including graphics with the graphicx package. The +user only has to specify the number of graphics that should fit to +a page or fraction there of and the package will dynamically +calculate the correct graphics sizes relative to the page size. +Thus, graphics can be auto-sized to fill a whole page or fraction +and manual changes of graphic sizes are never needed when changing +document layouts! Finally, the package's dynamic lengths can be +used to allow other document element sizes to be dynamic. + +* Changes +========= + +None yet! + + +* Installation +============== + + To install the package, please follow these steps: + +- Copy the figsize.file somewhere that TeX can find it. + +Thats it! + +The other files contain the documentation in various formats. diff --git a/macros/latex/contrib/figsize/epsfig.eps b/macros/latex/contrib/figsize/epsfig.eps new file mode 100644 index 0000000000..7000ae8ee3 --- /dev/null +++ b/macros/latex/contrib/figsize/epsfig.eps @@ -0,0 +1,506 @@ +%!PS-Adobe-2.0 EPSF-1.2 +%%Creator: MATLAB, The Mathworks, Inc. +%%Title: C:\WINNT\Profiles\tanbakuc\Desktop\Reports\Defect Correction\UniformDistNoiseDetectPlot.eps +%%CreationDate: 07/09/ 1 09:04:21 +%%DocumentNeededFonts: Helvetica +%%DocumentProcessColors: Cyan Magenta Yellow Black +%%Pages: 1 +%%BoundingBox: 61 200 556 600 +%%EndComments + +%%BeginProlog + +% MathWorks dictionary +/MathWorks 160 dict begin + +% definition operators +/bdef {bind def} bind def +/ldef {load def} bind def +/xdef {exch def} bdef +/xstore {exch store} bdef + +% operator abbreviations +/c /clip ldef +/cc /concat ldef +/cp /closepath ldef +/gr /grestore ldef +/gs /gsave ldef +/mt /moveto ldef +/np /newpath ldef +/cm /currentmatrix ldef +/sm /setmatrix ldef +/rc {rectclip} bdef +/rf {rectfill} bdef +/rm /rmoveto ldef +/rl /rlineto ldef +/s /show ldef +/sc {setcmykcolor} bdef +/sr /setrgbcolor ldef +/sg /setgray ldef +/w /setlinewidth ldef +/j /setlinejoin ldef +/cap /setlinecap ldef + +% page state control +/pgsv () def +/bpage {/pgsv save def} bdef +/epage {pgsv restore} bdef +/bplot /gsave ldef +/eplot {stroke grestore} bdef + +% orientation switch +/portraitMode 0 def +/landscapeMode 1 def + +% coordinate system mappings +/dpi2point 0 def + +% font control +/FontSize 0 def +/FMS { + /FontSize xstore %save size off stack + findfont + [FontSize 0 0 FontSize neg 0 0] + makefont + setfont + }bdef + +/ISOLatin1Encoding where +{pop +/WindowsLatin1Encoding 256 array bdef +ISOLatin1Encoding WindowsLatin1Encoding copy pop +/.notdef/.notdef/quotesinglbase/florin/quotedblbase/ellipsis/dagger/daggerdbl +/circumflex/perthousand/Scaron/guilsinglleft/OE/.notdef/.notdef/.notdef +/.notdef/quoteleft/quoteright/quotedblleft/quotedblright/bullet/endash/emdash +/tilde/trademark/scaron/guilsinglright/oe/.notdef/.notdef/Ydieresis +WindowsLatin1Encoding 128 32 getinterval astore pop} +{/WindowsLatin1Encoding StandardEncoding bdef} ifelse + +/reencode { +exch dup where +{pop load} {pop StandardEncoding} ifelse +exch +dup 3 1 roll +findfont dup length dict begin + { 1 index /FID ne {def}{pop pop} ifelse } forall + /Encoding exch def + currentdict +end +definefont pop +} bdef + +/isroman { +findfont /CharStrings get +/Agrave known +} bdef + +/FMSR { +3 1 roll 1 index +dup isroman +{reencode} {pop pop} ifelse +exch FMS +} bdef + +/csm { + 1 dpi2point div -1 dpi2point div scale + neg translate + landscapeMode eq {90 rotate} if + } bdef + +% line types: solid, dotted, dashed, dotdash +/SO { [] 0 setdash } bdef +/DO { [.5 dpi2point mul 4 dpi2point mul] 0 setdash } bdef +/DA { [6 dpi2point mul] 0 setdash } bdef +/DD { [.5 dpi2point mul 4 dpi2point mul 6 dpi2point mul 4 dpi2point mul] 0 setdash } bdef + +% macros for lines and objects +/L { + lineto + stroke + } bdef +/MP { + 3 1 roll moveto + 1 sub {rlineto} repeat + } bdef +/AP { + {rlineto} repeat + } bdef +/PP { + closepath eofill + } bdef +/DP { + closepath stroke + } bdef +/MR { + 4 -2 roll moveto + dup 0 exch rlineto + exch 0 rlineto + neg 0 exch rlineto + closepath + } bdef +/FR { + MR stroke + } bdef +/PR { + MR fill + } bdef +/L1i { + { currentfile picstr readhexstring pop } image + } bdef + +/tMatrix matrix def +/MakeOval { + newpath + tMatrix currentmatrix pop + translate scale + 0 0 1 0 360 arc + tMatrix setmatrix + } bdef +/FO { + MakeOval + stroke + } bdef +/PO { + MakeOval + fill + } bdef + +/PD { + currentlinecap 1 setlinecap 3 1 roll 2 copy moveto lineto stroke setlinecap + } bdef + +/FA { + newpath + tMatrix currentmatrix pop + translate scale + 0 0 1 5 -2 roll arc + tMatrix setmatrix + stroke + } bdef +/PA { + newpath + tMatrix currentmatrix pop + translate 0 0 moveto scale + 0 0 1 5 -2 roll arc + closepath + tMatrix setmatrix + fill + } bdef + +/FAn { + newpath + tMatrix currentmatrix pop + translate scale + 0 0 1 5 -2 roll arcn + tMatrix setmatrix + stroke + } bdef +/PAn { + newpath + tMatrix currentmatrix pop + translate 0 0 moveto scale + 0 0 1 5 -2 roll arcn + closepath + tMatrix setmatrix + fill + } bdef + +/vradius 0 def +/hradius 0 def +/lry 0 def +/lrx 0 def +/uly 0 def +/ulx 0 def +/rad 0 def + +/MRR { + /vradius xdef + /hradius xdef + /lry xdef + /lrx xdef + /uly xdef + /ulx xdef + newpath + tMatrix currentmatrix pop + ulx hradius add uly vradius add translate + hradius vradius scale + 0 0 1 180 270 arc + tMatrix setmatrix + lrx hradius sub uly vradius add translate + hradius vradius scale + 0 0 1 270 360 arc + tMatrix setmatrix + lrx hradius sub lry vradius sub translate + hradius vradius scale + 0 0 1 0 90 arc + tMatrix setmatrix + ulx hradius add lry vradius sub translate + hradius vradius scale + 0 0 1 90 180 arc + tMatrix setmatrix + closepath + } bdef +/FRR { + MRR stroke } bdef +/PRR { + MRR fill } bdef + +/MlrRR { + /lry xdef + /lrx xdef + /uly xdef + /ulx xdef + /rad lry uly sub 2 div def + newpath + tMatrix currentmatrix pop + ulx rad add uly rad add translate + rad rad scale + 0 0 1 90 270 arc + tMatrix setmatrix + lrx rad sub lry rad sub translate + rad rad scale + 0 0 1 270 90 arc + tMatrix setmatrix + closepath + } bdef +/FlrRR { + MlrRR stroke } bdef +/PlrRR { + MlrRR fill } bdef + +/MtbRR { + /lry xdef + /lrx xdef + /uly xdef + /ulx xdef + /rad lrx ulx sub 2 div def + newpath + tMatrix currentmatrix pop + ulx rad add uly rad add translate + rad rad scale + 0 0 1 180 360 arc + tMatrix setmatrix + lrx rad sub lry rad sub translate + rad rad scale + 0 0 1 0 180 arc + tMatrix setmatrix + closepath + } bdef +/FtbRR { + MtbRR stroke } bdef +/PtbRR { + MtbRR fill } bdef + +currentdict end def +%%EndProlog + +%%BeginSetup +MathWorks begin + +0 cap + +end +%%EndSetup + +%%Page: 1 1 +%%BeginPageSetup +%%PageBoundingBox: 61 200 556 600 +MathWorks begin +bpage +%%EndPageSetup + +%%BeginObject: obj1 +bplot + +/dpi2point 12 def +portraitMode 0216 7344 csm + + 527 135 5932 4798 MR c np +85 dict begin %Colortable dictionary +/c0 { 0 0 0 sr} bdef +/c1 { 1 1 1 sr} bdef +/c2 { 1 0 0 sr} bdef +/c3 { 0 1 0 sr} bdef +/c4 { 0 0 1 sr} bdef +/c5 { 1 1 0 sr} bdef +/c6 { 1 0 1 sr} bdef +/c7 { 0 1 1 sr} bdef +c0 +1 j +1 sg + 0 0 6919 5187 PR +6 w +0 4226 5361 0 0 -4226 899 4615 4 MP +PP +-5361 0 0 4226 5361 0 0 -4226 899 4615 5 MP stroke +4 w +DO +0 sg + 899 4615 mt 899 389 L + 899 389 mt 899 389 L +1665 4615 mt 1665 389 L +1665 389 mt 1665 389 L +2431 4615 mt 2431 389 L +2431 389 mt 2431 389 L +3197 4615 mt 3197 389 L +3197 389 mt 3197 389 L +3962 4615 mt 3962 389 L +3962 389 mt 3962 389 L +4728 4615 mt 4728 389 L +4728 389 mt 4728 389 L +5494 4615 mt 5494 389 L +5494 389 mt 5494 389 L +6260 4615 mt 6260 389 L +6260 389 mt 6260 389 L + 899 4615 mt 6260 4615 L +6260 4615 mt 6260 4615 L + 899 4145 mt 6260 4145 L +6260 4145 mt 6260 4145 L + 899 3676 mt 6260 3676 L +6260 3676 mt 6260 3676 L + 899 3206 mt 6260 3206 L +6260 3206 mt 6260 3206 L + 899 2737 mt 6260 2737 L +6260 2737 mt 6260 2737 L + 899 2267 mt 6260 2267 L +6260 2267 mt 6260 2267 L + 899 1798 mt 6260 1798 L +6260 1798 mt 6260 1798 L + 899 1328 mt 6260 1328 L +6260 1328 mt 6260 1328 L + 899 859 mt 6260 859 L +6260 859 mt 6260 859 L + 899 389 mt 6260 389 L +6260 389 mt 6260 389 L +SO +6 w + 899 389 mt 6260 389 L + 899 4615 mt 6260 4615 L +6260 4615 mt 6260 389 L + 899 4615 mt 899 389 L + 899 4615 mt 6260 4615 L + 899 4615 mt 899 389 L + 899 4615 mt 899 4561 L + 899 389 mt 899 443 L +%%IncludeResource: font Helvetica +/Helvetica /WindowsLatin1Encoding 120 FMSR + + 866 4761 mt +(0) s +1665 4615 mt 1665 4561 L +1665 389 mt 1665 443 L +1515 4761 mt +(0.005) s +2431 4615 mt 2431 4561 L +2431 389 mt 2431 443 L +2315 4761 mt +(0.01) s +3197 4615 mt 3197 4561 L +3197 389 mt 3197 443 L +3047 4761 mt +(0.015) s +3962 4615 mt 3962 4561 L +3962 389 mt 3962 443 L +3846 4761 mt +(0.02) s +4728 4615 mt 4728 4561 L +4728 389 mt 4728 443 L +4578 4761 mt +(0.025) s +5494 4615 mt 5494 4561 L +5494 389 mt 5494 443 L +5378 4761 mt +(0.03) s +6260 4615 mt 6260 4561 L +6260 389 mt 6260 443 L +6110 4761 mt +(0.035) s + 899 4615 mt 953 4615 L +6260 4615 mt 6206 4615 L + 798 4659 mt +(0) s + 899 4145 mt 953 4145 L +6260 4145 mt 6206 4145 L + 698 4189 mt +(0.5) s + 899 3676 mt 953 3676 L +6260 3676 mt 6206 3676 L + 798 3720 mt +(1) s + 899 3206 mt 953 3206 L +6260 3206 mt 6206 3206 L + 698 3250 mt +(1.5) s + 899 2737 mt 953 2737 L +6260 2737 mt 6206 2737 L + 798 2781 mt +(2) s + 899 2267 mt 953 2267 L +6260 2267 mt 6206 2267 L + 698 2311 mt +(2.5) s + 899 1798 mt 953 1798 L +6260 1798 mt 6206 1798 L + 798 1842 mt +(3) s + 899 1328 mt 953 1328 L +6260 1328 mt 6206 1328 L + 698 1372 mt +(3.5) s + 899 859 mt 953 859 L +6260 859 mt 6206 859 L + 798 903 mt +(4) s + 899 389 mt 953 389 L +6260 389 mt 6206 389 L + 698 433 mt +(4.5) s + 899 389 mt 6260 389 L + 899 4615 mt 6260 4615 L +6260 4615 mt 6260 389 L + 899 4615 mt 899 389 L +gs 899 389 5362 4227 MR c np +/c8 { 0.000000 0.500000 0.400000 sr} bdef +c8 +-766 0 -766 0 -766 0 -765 0 -766 0 -766 0 -766 0 -766 0 +-766 0 -766 0 0 0 766 0 766 0 766 0 766 1409 766 0 +766 0 765 0 766 -235 766 0 766 -939 0 -235 899 4615 23 MP +PP +0 sg +0 0 -766 0 -766 0 -766 0 -765 0 -766 0 -766 0 -766 0 +-766 0 -766 0 -766 0 0 0 766 0 766 0 766 0 766 1409 +766 0 766 0 765 0 766 -235 766 0 766 -939 0 -235 899 4615 24 MP stroke +/c9 { 1.000000 1.000000 0.400000 sr} bdef +c9 +-766 939 -766 0 -766 235 -765 0 -766 0 -766 0 -766 -1409 -766 0 +-766 0 -766 0 0 0 766 0 766 0 766 0 766 2817 766 235 +766 0 765 470 766 0 766 469 766 0 0 -3756 899 4380 23 MP +PP +0 sg +0 0 -766 939 -766 0 -766 235 -765 0 -766 0 -766 0 -766 -1409 +-766 0 -766 0 -766 0 0 0 766 0 766 0 766 0 766 2817 +766 235 766 0 765 470 766 0 766 469 766 0 0 -3756 899 4380 24 MP stroke +gr + +2994 4904 mt +(Image Noise Variance) s + 643 3038 mt -90 rotate +(Standard Deviations) s +90 rotate +2802 294 mt +(Efficiency of Defect Detection) s +1915 2388 mt +(100% Defect Detection Region ) s + +end + +eplot +%%EndObject + +epage +end + +showpage + +%%Trailer +%%EOF diff --git a/macros/latex/contrib/figsize/figsize.pdf b/macros/latex/contrib/figsize/figsize.pdf new file mode 100644 index 0000000000..b7d41c497f Binary files /dev/null and b/macros/latex/contrib/figsize/figsize.pdf differ diff --git a/macros/latex/contrib/figsize/figsize.sty b/macros/latex/contrib/figsize/figsize.sty new file mode 100644 index 0000000000..ac4d7475d9 --- /dev/null +++ b/macros/latex/contrib/figsize/figsize.sty @@ -0,0 +1,61 @@ +%% FIGSIZE +%% Package to dynamically size figures relative to the page +%% size. +%% +%% USER COMMANDS +%% \usepackage{figsize} +%% If option distort is present then the included images will +%% be allowed to have different x & y scaling. Otherwise +%% the aspect ratio will be kept. +%% +%% \SetFigLayout[extra lines of space to add]{rows}{cols} +%% To set the sizes of graphics relative to the page size in a +%% cell of a matrix with rows and cols specified. Optional +%% integers can be specified to increase the space allowed for +%% captions. If a value of 8 is placed, then 8 extra lines of +%% caption text will be allowed for. +%% +%% \includegraphics{file} +%% To include the graphics with the current most size settings. +%% +%% +%% Anthony Tanbakuchi +%% Mar.18.2002 +%% +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{figsize}[2002/03/18 v0.1 FigSize sizes graphics for graphicx package] +\RequirePackage{calc}[1998/07/07] + +%\RequirePackage[tight]{subfigure}[2002/01/01] +\RequirePackage{subfigure} + + +\RequirePackage{graphicx}[1999/01/01] +\RequirePackage{ifthen}[1994/06/01] + + %The new includegraphics command to automatically size figure + \let\Oldincludegraphics\includegraphics + \renewcommand{\includegraphics}[2][width=\figwidth, totalheight=\figheight, keepaspectratio]{\Oldincludegraphics[#1]{#2}} + + + +\newlength{\figwidth} +\newlength{\figheight} + + +\newcommand{\SetFigLayout}[3][0]{\setlength{\figheight}{\textheight}% +%\addtolength{\figheight}{-0.1\textheight}% 10% for the bottom caption +%\addtolength{\figheight}{-1.4cm}% for caption text 1 line +\addtolength{\figheight}{-\baselineskip-\parskip}% for caption text 1 line +\addtolength{\figheight}{-\abovecaptionskip}% +\addtolength{\figheight}{-\belowcaptionskip}% +\setlength{\figheight}{\figheight / #2}% +\addtolength{\figheight}{(-\baselineskip-\parskip) * (#2-1)}% for subcaption 1 line +\addtolength{\figheight}{-\baselineskip * #1}% %For additional optional spacing +% +\setlength{\figwidth}{\textwidth}% +\ifthenelse{#3 > 1}{\addtolength{\figwidth}{-0.05\textwidth}}{}% 5% space if multiple cols +\setlength{\figwidth}{\figwidth / #3}% +} + +\endinput diff --git a/macros/latex/contrib/figsize/figsize.tex b/macros/latex/contrib/figsize/figsize.tex new file mode 100644 index 0000000000..f0139b84c1 --- /dev/null +++ b/macros/latex/contrib/figsize/figsize.tex @@ -0,0 +1,394 @@ +\documentclass{article} +\usepackage{figsize} + + +\title{The FigSize Package} +\author{Anthony A. Tanbakuchi \\{\small atanbakuchi@hotmail.com} \\ v0.1 last revised 2002/3/18} +\date{} + +\parskip=12pt +\parindent=0pt +\begin{document} +\maketitle +\begin{abstract} +The FigSize package enables automatic sizing of graphics, +especially when including graphics with the graphicx package. The +user only has to specify the number of graphics that should fit to +a page or fraction there of and the package will dynamically +calculate the correct graphics sizes relative to the page size. +Thus, graphics can be auto-sized to fill a whole page or fraction +and manual changes of graphic sizes are never needed when changing +document layouts! Finally, the package's dynamic lengths can be +used to allow other document element sizes to be dynamic. +\end{abstract} + +\section{Usage} + +Perhaps the best way to see how this package works is to skip to +the examples section. However, below is a more general +explanation of the package and its use. + +Loading the package: + + \verb"\loadpackage{figsize}"\\ + +Next, to allow the FigSize package to dynamically define widths +and heights for the graphic simply specify the desired layout +using, + + + \verb"\SetFigLayout[]{}{}". + +Where you specify the number of rows and columns of graphics that +should fit to a page. Optionally, if you have a long caption you +can tell the package how many extra lines of text that should be +allowed for on the page as well. + +Then, just include the graphic using the command from the graphicx +package (which is just the advanced version of the graphics +package), + +\verb"\includegraphics{filename}"\footnote{For a detailed +explanation on how to use the graphics package and the +$\backslash$includegraphics command see the guide to using +graphics with \LaTeX. Found online at +http://www.ctan.org/tex-archive/help/Catalogue/entries/grfguide.html?} + +Thus, if one issues the command \verb"\SetFigLayout{2}{1}" the +algorithm knows that any graphics inserted after this point with +the command \verb"\includegraphics{...}" should be sized so that +two high by one wide will fit on a page. + +When \verb"\SetFigLayout{}{}" is issued the package redefines two +new page relative lengths \verb"\figwidth" and \verb"\figheight". +Then, \verb"\includegraphics{...}" is redefined to by default have +optional parameters set to \\ + \verb"[width=\figwidth, totalheight=\figheight, keepaspectratio]". + +By default, this package makes the assumption that figures should +be resized while keeping their aspect ratio. This may not be the +desired effect, to remove this effect insert figures using,\\ + \verb"\includegraphics[width=\figwidth, totalheight=\figheight]{...}"\\ +\noindent Further, one can utilize all the optional facilities +provided by the \verb"\includegraphics{...}" command, simply use +the format,\\ + \verb"\includegraphics[width=\figwidth, totalheight=\figheight, ]{...}" + +Moreover, one can use the new dynamic widths \verb"\figwidth" and +\verb"\figheight" for other types of environments like tables, +pictures, and so on. + +\section{Package Requirements} +When the FigSize package is loaded it loads the +\textbf{subfigure}, \textbf{graphicx}, \textbf{ifthen}, and +\textbf{calc} packages. These packages must already exist on the +\LaTeX system for the FigSize package to work properly. + +\section{Examples} + +The best way to see how this package works is through examples. +The next few examples illustrate common uses for the FigSize +package. + +The following code sets the size of the graphics so that 4 rows by +3 columns of them fit to a page. The result is shown in Figure +\ref{fig:1} and \ref{fig:1b}. + +\begin{verbatim} +\begin{figure} +\SetFigLayout{3}{3} + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} \\ + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} \\ + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{ + \includegraphics[angle=45, width=\figwidth, + totalheight=\figheight, keepaspectratio]{epsfig}} + + \caption{This is where your caption text goes. No + optional parameters.}\label{fig:1} +\end{figure} + +\begin{figure} +\SetFigLayout{3}{3} + \subfigure[A subfigure.]{ + \includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{ + \includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{ + \includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} \\ + \subfigure[A subfigure.]{ + \includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{ + \includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{ + \includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} \\ + \subfigure[A subfigure.]{ + \includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{ + \includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{ + \includegraphics[angle=45, width=\figwidth, + totalheight=\figheight]{epsfig}} + + \caption{This is where your caption text goes. + Optional parameters causing the aspect ratio to be + disregarded.}\label{fig:1b} +\end{figure} +\end{verbatim} + + +\begin{figure} +\SetFigLayout{3}{3} + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} \\ + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} \\ + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics[angle=45, width=\figwidth, totalheight=\figheight, keepaspectratio]{epsfig}} + \caption{This is where your caption text goes. No + optional parameters.}\label{fig:1} +\end{figure} + +\begin{figure} +\SetFigLayout{3}{3} + \subfigure[A subfigure.]{\includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} \\ + \subfigure[A subfigure.]{\includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} \\ + \subfigure[A subfigure.]{\includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics[width=\figwidth, totalheight=\figheight]{epsfig}} + \hfill + \subfigure[A subfigure.]{\includegraphics[angle=45, width=\figwidth, totalheight=\figheight]{epsfig}} + \caption{This is where your caption text goes. + Optional parameters causing the aspect ratio to be + disregarded.}\label{fig:1b} +\end{figure} + +The following code produces a graphic occupying the whole page +(maximally). The result is shown in Figures \ref{fig:2} and +\ref{fig:2b}. + +\begin{verbatim} +\begin{figure} + \SetFigLayout{1}{1} + {\includegraphics{epsfig}} + \caption{A graphic meant to occupy a whole page. Note + that the aspect ratio is respected so the graphic + can only occupy the whole text width.} +\end{figure} +\end{verbatim} + +\begin{figure} +\SetFigLayout{1}{1} {\includegraphics{epsfig}} + \caption{A graphic meant to occupy a whole page. Note + that the aspect ratio is respected so the graphic + can only + occupy the whole text width.}\label{fig:2} +\end{figure} + +\begin{verbatim} +\begin{figure} + \SetFigLayout{1}{1} + {\includegraphics[% + width=\figwidth, totalheight=\figheight]{epsfig}} + \caption{Now the graphic occupies the whole page because + we manually specified the parameters to the + include graphics command which omitted keepaspectratio.} +\end{figure} +\end{verbatim} + +\begin{figure} +\SetFigLayout{1}{1} {\includegraphics[width=\figwidth, +totalheight=\figheight]{epsfig}} + \caption{Now the graphic occupies the whole page because + we manually specified the parameters to the + include graphics command which omitted keepaspectratio.}\label{fig:2b} +\end{figure} + + +The next figure is sized such that only two graphics occupy at +most half of the page, allowing for document text to flow onto the +rest of the page. The result is shown in Figure \ref{fig:3}. + +\begin{verbatim} +\begin{figure} + \centering + \SetFigLayout[3]{2}{2} + \subfigure[]{\includegraphics{epsfig}} \hfill + \subfigure[]{\includegraphics{epsfig}} +\end{figure} +\end{verbatim} +\ +\begin{figure} + \centering + \SetFigLayout[3]{2}{2} + \subfigure[]{\includegraphics{epsfig}} \hfill + \subfigure[]{\includegraphics{epsfig}} + \caption{This is where your caption text goes.}\label{fig:3} +\end{figure} + + + +The following code is an example of including a full size graphic +with a long caption. The option 5 tells the algorithm to leave +space for 5 extra lines of caption text. Without providing +telling the algorithm that the caption is expected to take at most +5 extra lines than the one allowed an over full box would occur on +the page. +\begin{verbatim} + +\begin{figure} + \SetFigLayout[5]{1}{1} + {\includegraphics[% + width=\figwidth, totalheight=\figheight]{epsfig}} + \caption{This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes.} +\end{figure} +\end{verbatim} + +\begin{figure} +\SetFigLayout[5]{1}{1} {\includegraphics[% + width=\figwidth, totalheight=\figheight]{epsfig}} + \caption{This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes. + This is where your caption text goes.}\label{fig:4} +\end{figure} + +Figure \ref{fig:5} shows how you can mix and match the sizes +relative graphic sizes. + +\begin{verbatim} +\begin{figure} + \centering + \SetFigLayout[3]{2}{2} + \subfigure[]{\includegraphics{epsfig}} \hfill + \subfigure[]{\includegraphics{epsfig}} + %Now change the size mid way + \SetFigLayout[3]{2}{1} + \subfigure[]{\includegraphics{epsfig}} + \caption{This is where your caption text goes.} +\end{figure} +\end{verbatim} + +\begin{figure} + \centering + \SetFigLayout[3]{2}{2} + \subfigure[]{\includegraphics{epsfig}} \hfill + \subfigure[]{\includegraphics{epsfig}} + \SetFigLayout[3]{2}{1} + \subfigure[]{\includegraphics{epsfig}} + \caption{This is where your caption text goes.}\label{fig:5} +\end{figure} + +Finally, we can utilize the \verb"\figwidth" and \verb"\figheight" +commands for other environments like tables as shown in Table +\ref{tab:1}. The code that produced the tables was, + +\begin{verbatim} +\begin{table} + \caption{Two tables that are half page width}\label{tab:1} + \SetFigLayout{1}{2} +\begin{tabular*}{\figwidth}{ccc} +\hline + A & B & C \\ \hline + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + \hline + \end{tabular*} + \hfill +\begin{tabular*}{\figwidth}{ccc} +\hline + A & B & C \\ \hline + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + \hline + \end{tabular*} + +\end{table} +\end{verbatim} + + + +\begin{table} + \caption{Two tables that are half page width}\label{tab:1} + \SetFigLayout{1}{2} +\begin{tabular*}{\figwidth}{ccc} +\hline + A & B & C \\ \hline + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + \hline + \end{tabular*} + \hfill +\begin{tabular*}{\figwidth}{ccc} +\hline + A & B & C \\ \hline + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + 555 & 111 & 333 \\ + \hline + \end{tabular*} + +\end{table} + + + +\section{Closing} +If you like this package, find bugs, or just have useful comments +please let the me know at atanbakuchi@hotmail.com. Please note +that I am not a \TeX hack, just someone who had a wish for this +type of package and managed to find a solution. +\end{document} -- cgit v1.2.3