%%
%% This is file `attachfile.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% attachfile.dtx (with options: `package')
%%
%% This is a generated file.
%%
%% Copyright (C) 2006 Scott Pakin <scott+af@pakin.org>
%% -------------------------------------------------------
%%
%% This package may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
%% version 1.3b 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.3b or later is part of all distributions of
%% LaTeX version 2006/01/07 or later.
%%
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesPackage{attachfile}
[2006/03/28 v1.2a PDF 1.3+ file attachment]
\RequirePackage{ifpdf}
\ifpdf
\else
\PackageWarningNoLine{attachfile}{%
attachfile works _only_ with pdfLaTeX and _only_ in\MessageBreak
PDF-generating mode. For this run, placeholders will\MessageBreak
be substituted for all attachfile commands.}
\fi
\RequirePackage{keyval}
\RequirePackage{calc}
\RequirePackage{color}
\RequirePackageWithOptions{hyperref}
\newcommand{\atfi@acroGraph@data}{%
q 0.5 g 1.1133 0 20.7202 18.2754 re f 1 g 0 G 0 i 0.5 w 4 M
0.25 1.6453 20.145 17.7715 re B 0 g 2.7319 4.1367 3.9571
13.8867 re f 8.7031 4.1367 3.9571 9.8867 re f 14.7471 4.1367
3.9571 11.8867 re f \atfi@color@rgb\space rg 1.689 3.0938
3.9571 13.8867 re f 7.6602 3.0938 3.9571 9.8867 re f 13.7041
3.0938 3.9571 11.8867 re f Q
}
\DeclareRobustCommand{\atfi@acroGraph}{%
\raisebox{-1.5bp}{\parbox[b][20bp]{22bp}{%
\rule{0pt}{0pt}\pdfliteral{\atfi@acroGraph@data}}%
}%
}
\newcommand{\atfi@acroPaperclip@data}{%
q 0.75 G 0 i 2.5 w 1 J 4 M 1.9619 11.7559 m 1.9619 3.3037
1.9619 2.5059 v 1.9619 1.707 4.0947 1.25 y 7.4141 1.25 l 9.4292
1.8223 9.4292 3.3066 v 9.4292 4.79 9.4292 16.8945 y 9.7852
18.1514 8.481 18.1514 v 7.1768 18.1514 5.1616 18.1514 y 3.8574
17.9209 3.8574 16.8945 v 3.8574 15.8652 3.8574 6.6172 y 4.3325
5.418 5.1025 5.418 v 5.8726 5.418 6.5845 5.418 y 7.6812 5.6455
7.6812 6.4736 v 7.6812 7.3027 7.6812 11.5264 y S 0 G 1.2495
12.4404 m 1.2495 3.9883 1.2495 3.1895 v 1.2495 2.3906 3.3833
1.9326 y 6.7026 1.9326 l 8.7178 2.5068 8.7178 3.9902 v 8.7178
5.4736 8.7178 17.5781 y 9.0732 18.834 7.769 18.834 v 6.4653
18.834 4.4497 18.834 y 3.146 18.6055 3.146 17.5781 v 3.146
16.5498 3.146 7.3018 y 3.6201 6.1016 4.3911 6.1016 v 5.1611
6.1016 5.873 6.1016 y 6.9692 6.3301 6.9692 7.1572 v 6.9692
7.9863 6.9692 12.21 y S \atfi@color@rgb\space RG 1 w
1.2495 12.4404 m 1.2495 3.9883 1.2495 3.1895 v 1.2495 2.3906
3.3833 1.9326 y 6.7026 1.9326 l 8.7178 2.5068 8.7178 3.9902 v
8.7178 5.4736 8.7178 17.5781 y 9.0732 18.834 7.769 18.834 v
6.4653 18.834 4.4497 18.834 y 3.146 18.6055 3.146 17.5781 v
3.146 16.5498 3.146 7.3018 y 3.6201 6.1016 4.3911 6.1016 v
5.1611 6.1016 5.873 6.1016 y 6.9692 6.3301 6.9692 7.1572 v
6.9692 7.9863 6.9692 12.21 y S Q
}
\DeclareRobustCommand{\atfi@acroPaperclip}{%
\raisebox{-1.25bp}{\parbox[b][21bp]{12bp}{%
\rule{0pt}{0pt}\pdfliteral{\atfi@acroPaperclip@data}}%
}%
}
\newcommand{\atfi@acroPushPin@data}{%
q \atfi@color@rgb\space rg 0 G 1 w 1 6 m 11 6 l 11 13 l 12
13 l 14 11 l 21 11 l 22 12 l 23 12 l 23 2 l 22 2 l 21 3 l 14 3
l 12 1 l 11 1 l 11 6 l B 0.5 G 0 7 m 10 7 l 10 8 l 1 8 l S 1 G
12 12 m 14 10 l 22 10 l 22 11 l S Q
}
\DeclareRobustCommand{\atfi@acroPushPin}{%
\raisebox{-1.25bp}{\parbox[b][14bp]{24bp}{%
\rule{0pt}{0pt}\pdfliteral{\atfi@acroPushPin@data}}%
}%
}
\newcommand{\atfi@acroTag@data}{%
q 0.5 g 10.0542 14.9873 m 24.27 14.9873 l 25.252 14.0059 l
25.252 1.1455 l 24.1064 0 l 9.9609 0 l 6.0327 6.0088 l 6.0327
9.002 l 10.0542 14.9873 l 9.3994 9.376 m 8.5215 9.376 7.8096
8.5596 7.8096 7.5527 c 7.8096 6.5449 8.5215 5.7285 9.3994
5.7285 c 10.2778 5.7285 10.9897 6.5449 10.9897 7.5527 c 10.9897
8.5596 10.2778 9.376 9.3994 9.376 c h f
\atfi@color@rgb\space rg 0 G 0 i 0.5 w 4 M 1 j 8.5107
16.5313 m 22.7266 16.5313 l 23.7085 15.5488 l 23.7085 2.6895 l
22.563 1.543 l 8.4175 1.543 l 4.4893 7.5527 l 4.4893 10.5449 l
8.5107 16.5313 l 7.856 10.9199 m 6.978 10.9199 6.2661 10.1035
6.2661 9.0957 c 6.2661 8.0879 6.978 7.2715 7.856 7.2715 c
8.7344 7.2715 9.4463 8.0879 9.4463 9.0957 c 9.4463 10.1035
8.7344 10.9199 7.856 10.9199 c h B 1 w 12.3291 12.2656 m
21.1206 12.2656 l S 12.3291 9.1797 m 21.1206 9.1797 l S 12.3291
6.1875 m 21.1206 6.1875 l S 0 G 0.5 w 0 9.0488 m 6.2661 9.0957
l S 1.4028 5.2148 m 1.4028 9.6094 l 1.6831 10.6387 2.4316
10.6387 v 3.6475 10.6387 3.5542 9.0488 y S Q
}
\DeclareRobustCommand{\atfi@acroTag}{%
\raisebox{-1.6bp}{\parbox[b][17bp]{25bp}{%
\rule{0pt}{0pt}\pdfliteral{\atfi@acroTag@data}}%
}%
}
\def\atfi@temp@string{}
\DeclareRobustCommand{\atfi@pdfstringdef}[2]{%
\pdfstringdef\atfi@temp@string{#2}%
\edef#1{\atfi@temp@string}%
}
\newcounter{atfi@embedfileobj}
\DeclareRobustCommand{\atfi@embedfile}[1]{%
\immediate\pdfobj stream attr {
/Type /EmbeddedFile
\atfi@mimetype
} file {#1}%
\setcounter{atfi@embedfileobj}{\pdflastobj}%
}
\newlength{\atfi@appearancewidth}
\newlength{\atfi@appearanceheight}
\newlength{\atfi@appearancedepth}
\newcounter{atfi@appearanceobj}
\newsavebox{\atfi@appearancebox}
\DeclareRobustCommand{\atfi@set@appearance}[1]{%
\savebox{\atfi@appearancebox}{#1}%
\settowidth{\atfi@appearancewidth}{\usebox{\atfi@appearancebox}}%
\settoheight{\atfi@appearanceheight}{\usebox{\atfi@appearancebox}}%
\settodepth{\atfi@appearancedepth}{\usebox{\atfi@appearancebox}}%
\immediate\pdfxform attr {
/Subtype /Form
} \atfi@appearancebox
\setcounter{atfi@appearanceobj}{\pdflastxform}%
}
\newcounter{atfi@flags}
\DeclareRobustCommand{\atfi@flags@to@int}{%
\setcounter{atfi@flags}{0}%
\ifatfi@print
\addtocounter{atfi@flags}{4}%
\fi%
\ifatfi@zoom
\else
\addtocounter{atfi@flags}{8}%
\fi%
}
\DeclareRobustCommand{\atfi@insert@file@annot}[1]{%
\rule{0pt}{0pt}%
\atfi@pdfstringdef\atfi@file{#1}%
\ifatfi@appearance
\def\atfi@appearance@dict{%
/AP <<
/N \theatfi@appearanceobj\space 0 R
/R \theatfi@appearanceobj\space 0 R
/D \theatfi@appearanceobj\space 0 R
>>%
}%
\fi%
\pdfannot width \atfi@appearancewidth
height \atfi@appearanceheight
depth \atfi@appearancedepth {
/Subtype /FileAttachment
\atfi@icon\space
\atfi@color\space
\atfi@author\space
\atfi@date\space
\atfi@description\space
\atfi@subject\space
\atfi@appearance@dict\space
/F \theatfi@flags\space
/FS <<
/Type /Filespec
/F (\atfi@file)
/EF <<
/F \theatfi@embedfileobj\space 0 R
>>
>>
}%
\rule{0pt}{\atfi@appearanceheight}%
\rule[-\atfi@appearancedepth]{0pt}{\atfi@appearancedepth}%
\rule{\atfi@appearancewidth}{0pt}%
}
\def\atfi@attachfile#1#2{%
\setkeys{AtFi}{#1}%
\atfi@embedfile{#2}%
\atfi@set@appearance{\csname atfi@acro\atfi@icon@icon\endcsname}%
\atfi@flags@to@int%
\atfi@insert@file@annot{#2}%
\endgroup
}
\def\atfi@textattachfile#1#2{%
\endgroup
\atfi@textattachfile@i{#1}{#2}%
}
\def\atfi@textattachfile@i#1#2#3{%
\setkeys{AtFi}{#1}%
\atfi@embedfile{#2}%
\def\atfi@textcolor(##1 ##2 ##3)##4{%
\textcolor[rgb]{##1,##2,##3}{##4}}%
\atfi@set@appearance{%
\expandafter\atfi@textcolor\expandafter
(\atfi@color@rgb){#3\strut}}%
\atfi@flags@to@int
\atfi@insert@file@annot{#2}%
\endgroup
}
\bgroup
\lccode`\@=`\#
\lowercase{\gdef\atfi@pdf@slash{@2f}}
\egroup
\def\atfi@split@mimetype#1/#2/{%
\def\atfi@mime@type{#1}%
\def\atfi@mime@subtype{#2}%
}
\def\atfi@mimetype{}
\define@key{AtFi}{mimetype}{%
\atfi@pdfstringdef\atfi@mimetype{#1}%
\atfi@split@mimetype#1/%
\edef\atfi@mimetype{%
/Subtype /\atfi@mime@type\atfi@pdf@slash\atfi@mime@subtype
}%
}
\define@key{AtFi}{icon}{%
\def\atfi@icon{/Name /#1}%
\def\atfi@icon@icon{#1}%
}
\setkeys{AtFi}{icon=PushPin}
\define@key{AtFi}{color}{%
\def\atfi@color{/C [#1]}%
\def\atfi@color@rgb{#1}%
}
\setkeys{AtFi}{color=1 0.9255 0.7765}
\def\atfi@author{}
\define@key{AtFi}{author}[]{%
\edef\atfi@author{/T (#1)}%
}
\def\atfi@pad@ii#1{%
\ifnum#1>9
\the#1%
\else
0\the#1%
\fi%
}
\def\atfi@timezone{}
\define@key{AtFi}{timezone}{\def\atfi@timezone{#1}}
\edef\atfi@time{\time}
\newcounter{atfi@hours}
\setcounter{atfi@hours}{\atfi@time/60}
\newcounter{atfi@minutes}
\setcounter{atfi@minutes}{\atfi@time-\theatfi@hours*60}
\def\atfi@date{%
/M (D:\the\year%
\atfi@pad@ii\month%
\atfi@pad@ii\day%
\atfi@pad@ii\c@atfi@hours%
\atfi@pad@ii\c@atfi@minutes
00%
\atfi@timezone)%
}
\define@key{AtFi}{date}{%
\atfi@pdfstringdef\atfi@date{#1}%
\edef\atfi@date{/M (\atfi@date)}%
}
\def\atfi@description{}
\define@key{AtFi}{description}{%
\atfi@pdfstringdef\atfi@description{#1}%
\edef\atfi@description{/Contents (\atfi@description)}%
}
\def\atfi@subject{}
\define@key{AtFi}{subject}{%
\atfi@pdfstringdef\atfi@subject{#1}%
\edef\atfi@subject{/Subj (\atfi@subject)}%
}
\newif\ifatfi@print
\atfi@printtrue
\define@key{AtFi}{print}[true]{\csname atfi@print#1\endcsname}
\newif\ifatfi@zoom
\atfi@zoomtrue
\define@key{AtFi}{zoom}[true]{\csname atfi@zoom#1\endcsname}
\newif\ifatfi@appearance
\atfi@appearancetrue
\def\atfi@appearance@dict{}
\define@key{AtFi}{appearance}[true]{\csname atfi@appearance#1\endcsname}
\DeclareRobustCommand{\attachfilesetup}[1]{\setkeys{AtFi}{#1}}
\DeclareRobustCommand{\attachfile}[1][]{%
\begingroup
\let\do\@makeother
\dospecials
\catcode`\{=1\relax
\catcode`\}=2\relax
\atfi@attachfile{#1}%
}
\DeclareRobustCommand{\textattachfile}[1][]{%
\begingroup
\begingroup
\let\do\@makeother
\dospecials
\catcode`\{=1\relax
\catcode`\}=2\relax
\atfi@textattachfile{#1}%
}
\DeclareRobustCommand{\noattachfile}[1][]{%
\begingroup
\setkeys{AtFi}{#1}%
\ifatfi@print
\csname atfi@acro\atfi@icon@icon\endcsname
\else
\setbox0=\hbox{\csname atfi@acro\atfi@icon@icon\endcsname}%
\makebox[\wd0]{}%
\fi
\endgroup
}
\DeclareRobustCommand{\notextattachfile}[2][]{%
\begingroup
\setkeys{AtFi}{#1}%
\ifatfi@print
\def\atfi@textcolor(##1 ##2 ##3)##4{%
\textcolor[rgb]{##1,##2,##3}{##4}}%
\expandafter\atfi@textcolor\expandafter
(\atfi@color@rgb){#2\strut}%
\else
\setbox0=\hbox{#2\strut}%
\makebox[\wd0]{}%
\fi
\endgroup
}
\ifpdf
\else
\def\atfi@dummy@pushpin{%
\raisebox{-1.25bp}{\parbox[b][14bp]{24bp}{}}%
}
\DeclareRobustCommand{\textattachfile}[3][]{%
\notextattachfile[#1]{#3}%
}
\DeclareRobustCommand{\noattachfile}[1][]{%
\notextattachfile[#1]{\atfi@dummy@pushpin}%
}
\DeclareRobustCommand{\attachfile}[2][]{%
\noattachfile[#1]%
}
\fi
\endinput
%%
%% End of file `attachfile.sty'.