From 200c32dca65937f664a864f70aaede2217c129dc Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Fri, 10 Jan 2014 23:25:57 +0000 Subject: graphicxbox (10jan14) git-svn-id: svn://tug.org/texlive/trunk@32630 c570f23f-e606-0410-a88d-b1316a301751 --- .../tex/latex/graphicxbox/graphicxbox.sty | 52 ++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 Master/texmf-dist/tex/latex/graphicxbox/graphicxbox.sty (limited to 'Master/texmf-dist/tex/latex/graphicxbox') diff --git a/Master/texmf-dist/tex/latex/graphicxbox/graphicxbox.sty b/Master/texmf-dist/tex/latex/graphicxbox/graphicxbox.sty new file mode 100644 index 00000000000..415e0d9c1e0 --- /dev/null +++ b/Master/texmf-dist/tex/latex/graphicxbox/graphicxbox.sty @@ -0,0 +1,52 @@ +%% +%% 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'. -- cgit v1.2.3