%%
%% This is file `graphicxbox.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% graphicxbox.dtx  (with options: `copyright,package')
%% 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% aeb_envelope.sty package,          2014-01-10        %%
%% Copyright (C) 2014  D. P. Story                      %%
%%   dpstory@acrotex.net                                %%
%%   storyd@owc.edu                                     %%
%%                                                      %%
%% This program can redistributed and/or modified under %%
%% the terms of the LaTeX Project Public License        %%
%% Distributed from CTAN archives in directory          %%
%% macros/latex/base/lppl.txt; either version 1 of the  %%
%% License, or (at your option) any later version.      %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{graphicxbox}
 [2014/01/10 v1.0 Provides graphic backgrounds for parboxes (dps)]
\@ifpackageloaded{graphicxsp}{}
    {%
        \@ifpackageloaded{graphicx}{}
        {%
            \PackageError{graphicxbox}{%
             Neither the graphicx nor graphicxsp packages are loaded.}%
            {Load the graphicx or graphicxsp package before this one.}%
        }%
    }
\newcommand{\graphicxbox}[2][]{\graphicx@b@x\relax{#1}{#2}}
\newcommand{\fgraphicxbox}[2][]{\fgraphicx@box{#1}{#2}}
\def\fgraphicx@box#1#2{\@ifnextchar[{\fgraphicx@@box{#1}{#2}}%
    {\fgraphicx@@box{#1}{#2}[]}}
\def\fgraphicx@@box#1#2[#3]#4{%
    \graphicx@b@x{\fboxsep\z@\color#1{#2}\fbox}{#3}{#4}}
\long\def\graphicx@b@x#1#2#3#4{\leavevmode
    \setbox\z@\hbox{\kern\fboxsep{\set@color#4}\kern\fboxsep}%
    \dimen@\ht\z@\advance\dimen@\fboxsep\ht\z@\dimen@
    \dimen@\dp\z@\advance\dimen@\fboxsep\dp\z@\dimen@
    {%\color@block{\wd\z@}{\ht\z@}{\dp\z@}%
    \dimen@\dp\z@\advance\dimen@\ht\z@
    \edef\gfxb@totalheight{\the\dimen@}%
    {#1{\lower\dp\z@\rlap{%
        \includegraphics[#2,width=\wd\z@,height=\gfxb@totalheight]{#3}}%
     \box\z@}}}%
}
\endinput
%%
%% End of file `graphicxbox.sty'.
