Author: F. Bosisio
E-mail:
fbosisio@bigfoot.com
CTAN location:
macros/latex/contrib/bosisio
This package provides some commands to make the use of graphic files in LaTeX simpler.
It declares the ``Figure'' environment (capitalized!) and the two commands ``\graphfile'' and ``\graphfile*''. Combining this commands, it is possible to include graphic files in a LaTeX document very simply.
This package uses the ``\includegraphics*'' command defined in the standard graphics package. Moreover, it uses the package subfigure when the subfigure option is specified, and the float package if the AllowH option is used.
At now, two options are available: ``subfigure'' and ``AllowH''.
The ``subfigure'' option allow the use of sub-figures inside a Figure environment, in order to place multiple pictures in a single LaTeX figure (cfr. the subfigure standard package).
The ``AllowH'' option allow the use of the ``H'' float specifier for the Figure environment, in order to place the figure exaclty where the command is placed (cfr. the float standard package).
The ``Figure'' environment (capitalized!) is somewhat different from the standard LaTeX ``figure'' environment: besides an optional argument used to specify the placement parameters (which now defaults to ``[htbp]''), it has a mandatory agrument specifying the ``caption'' and another optional argument, used as a ``label'' for cross-referencies:
\begin{Figure}[<htbpH>]{<caption>}[<label>] ... \end{Figure}
The use of the ``H'' specifier (i.e. ``I want my float here!'') is possible only if the ``AllowH'' option has been specified.
Inside the ``Figure'' environment, are available the commands:
\graphfile[<width>]{<file>}[<sub-caption>] \graphfile*[<heigth>]{<file>}[<sub-caption>]
Moreover, since the ``*-form'' of ``\includegraphics'' is used, the regions outside the bounding-box of postscript files are not drawn.
Another advantage of the combined use of the ``Figure'' environment and the ``\graphfile'' commands is that the picture is automatically centered horizontally, so no ``\centering'' or similar declartion is required.
\begin{Figure}[<htbpH>]{<caption>}[<label>] \graphfile[<width>]{<file>} \end{Figure}
If you want to include more than one file in a single figure, you may specify the ``subfigure'' option, which includes the subfigure package and provides the authomatic placement of a sub-caption below each picture.
If the ``subfigure'' option is not specified, multiple graphs are still allowed but no sub-caption will appear.
\graphfile[<width_1>]{<file_1>}[<sub-caption_1>] ... \graphfile[<width_N>]{<file_N>}[<sub-caption_N>]
Each individual caption is printed preceded by a bracketed letter, which is the sub-figure counter and is printed even if no caption is specified. Using only a series of ``\graphfile[...]{...}[...]'' commands inside a ``Figure'' environment provides an equal spacing beetween the pictures and around them, without the need for any extra command.
Finally, if a ``<label>'' was specified as the last optional argument to the ``Figure'' environment, you can reference to each individual sub-figure by the labels ``<label>:a'', ``<label>:b'', and so on, without the need for declaring them.
\begin{Figure}[<htbpH>]{<caption>}[<label>] \graphfile[<width_1>]{<file_1>}[<sub-caption_1>] \graphfile[<width_2>]{<file_2>}[<sub-caption_2>] : : \end{Figure}