summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-09-19 21:14:03 +0000
committerKarl Berry <karl@freefriends.org>2016-09-19 21:14:03 +0000
commit9d70d77474dea5d4290597aae2685af2b3566b80 (patch)
treee358e7a43bbdbde7363adbabc6b6c7ec15a34670
parenta28e9e88eda14395c0681874294edc28f6d3bb47 (diff)
attachfile (19sep16)
git-svn-id: svn://tug.org/texlive/trunk@42099 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/bibtex/bib/attachfile/attachfile.bib31
-rw-r--r--Master/texmf-dist/doc/latex/attachfile/README2
-rw-r--r--Master/texmf-dist/doc/latex/attachfile/attachfile.pdfbin359230 -> 361030 bytes
-rw-r--r--Master/texmf-dist/source/latex/attachfile/attachfile.dtx51
-rw-r--r--Master/texmf-dist/source/latex/attachfile/attachfile.ins4
-rw-r--r--Master/texmf-dist/tex/latex/attachfile/attachfile.sty20
6 files changed, 83 insertions, 25 deletions
diff --git a/Master/texmf-dist/bibtex/bib/attachfile/attachfile.bib b/Master/texmf-dist/bibtex/bib/attachfile/attachfile.bib
new file mode 100644
index 00000000000..7b02e3a6bf4
--- /dev/null
+++ b/Master/texmf-dist/bibtex/bib/attachfile/attachfile.bib
@@ -0,0 +1,31 @@
+@Book{PDFRef,
+ author = {{Adobe Systems Incorporated}},
+ title = {{PDF} Reference Version~1.6},
+ publisher = {Adobe Press},
+ year = 2004,
+ key = {PDF},
+ edition = {Fifth},
+ month = dec # {~3,},
+ note = {ISBN~\mbox{0321304748}. Available from \url{http://partners.adobe.com/public/developer/en/pdf/PDFReference16.pdf}}
+}
+
+@Unpublished{MediaTypes,
+ author = {{Internet Assigned Numbers Authority}},
+ title = {{MIME} Media Types},
+ note = {Available from \url{http://www.iana.org/assignments/media-types/}},
+ key = {IANA}
+}
+
+@TechReport{Freed1996,
+ author = {N. Freed and N. Borenstein},
+ title = {{M}ultipurpose {I}nternet {M}ail {E}xtensions {(MIME)}
+ Part Two: Media Types},
+ institution = {Internet Engineering Task Force (IETF),
+ Network Working Group},
+ year = 1996,
+ type = {Request for Comments (RFC)},
+ number = 2046,
+ month = nov,
+ note = {Available from
+ \url{http://www.rfc-editor.org/rfc/rfc2046.txt}}
+}
diff --git a/Master/texmf-dist/doc/latex/attachfile/README b/Master/texmf-dist/doc/latex/attachfile/README
index 0cffa125924..bdb0c118f63 100644
--- a/Master/texmf-dist/doc/latex/attachfile/README
+++ b/Master/texmf-dist/doc/latex/attachfile/README
@@ -21,7 +21,7 @@ attach files and customize their appearance in the enclosing document.
Copyright and license
---------------------
-Copyright (C) 2015 Scott Pakin <scott+af@pakin.org>
+Copyright (C) 2016 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.3c of this
diff --git a/Master/texmf-dist/doc/latex/attachfile/attachfile.pdf b/Master/texmf-dist/doc/latex/attachfile/attachfile.pdf
index 3a89c5b9af1..71aae83516a 100644
--- a/Master/texmf-dist/doc/latex/attachfile/attachfile.pdf
+++ b/Master/texmf-dist/doc/latex/attachfile/attachfile.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/attachfile/attachfile.dtx b/Master/texmf-dist/source/latex/attachfile/attachfile.dtx
index d66e72726d1..2f53a881420 100644
--- a/Master/texmf-dist/source/latex/attachfile/attachfile.dtx
+++ b/Master/texmf-dist/source/latex/attachfile/attachfile.dtx
@@ -1,6 +1,6 @@
% \iffalse meta-comment
%
-% Copyright (C) 2015 by Scott Pakin <scott+af@pakin.org>
+% Copyright (C) 2016 by Scott Pakin <scott+af@pakin.org>
% -------------------------------------------------------
%
% This file may be distributed and/or modified under the conditions of
@@ -22,7 +22,7 @@
%<package>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
%<package>\ProvidesPackage{attachfile}
%<*package>
- [2015/11/11 v1.8 PDF 1.3+ file attachment]
+ [2016/09/18 v1.9 PDF 1.3+ file attachment]
%</package>
%
%<*driver>
@@ -89,7 +89,7 @@
%<*package>
% \fi
%
-% \CheckSum{513}
+% \CheckSum{521}
%
% \CharacterTable
% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -838,23 +838,29 @@
% \acronym{PDF} files from \latex\ source,
% \pkgname{attachfile}~\fileversion\ supports only \pdflatex\ and
% \lualatex.
-%
+%
+% \item \lualatex~0.85 introduced incompatible changes in the set of
+% \acronym{PDF} primitives supported. Because \pkgname{attachfile}
+% does not yet provide explicit support for these new primitives,
+% documents will need to include a |\usepackage{luatex85}| line in
+% the preamble in order to build under \lualatex~0.85+.
+%
% \item \pkgname{attachfile} will not run unless the following
% \latex\ packages are installed: \pkgname{calc}, \pkgname{keyval},
% \pkgname{color}, \pkgname{hyperref}, and \pkgname{ifpdf}. (Most
% \tex\ distributions include all of these.)
-%
+%
% \item File attachments are a \acronym{PDF}~1.3 feature. They will
% not be visible in \acronym{PDF} viewers that don't support
% \acronym{PDF}~1.3. (Version~4.0 of \adobeacrobat is the first
% version of that program which does.)
-%
+%
% \item Even some viewers that purportedly support \acronym{PDF}~1.3
% don't support file attachments. As far as I can tell, very old
% versions of \adobeacrobatreader (the free, view-only version of
% \adobeacrobat) doesn't seem to support \emph{any} annotations
% except text annotations.
-%
+%
% \item Even some viewers that do support \acronym{PDF}~1.3 and file
% attachments don't support them under all circumstances. For
% instance, some Windows\smallreg\ versions of \adobeacrobat, when
@@ -862,16 +868,16 @@
% message\footnote{``Launching embedded files from within a browser
% environment is not allowed''.} when a file attachment icon is
% activated.
-%
+%
% \item Even in circumstances where file attachments are supported,
% the support may be flawed. For example, some
% Windows\smallreg\ versions of \adobeacrobat change a custom icon
% to the default icon when it's selected.
-%
-% Also, while file-attachment icons with custom appearances printed
+%
+% \item While file-attachment icons with custom appearances printed
% fine in older versions of \adobeacrobat, \adobe introduced a bug
-% circa \adobeacrobat~6.0 that prevents \pkgname{attachfile}'s icons
-% from printing. Unfortunately, because \adobeacrobat lacks
+% circa \adobeacrobat~6.0 that prevents \pkgname{attachfile}'s
+% icons from printing. Unfortunately, because \adobeacrobat lacks
% \pkgname{attachfile}'s ability to create custom appearances for
% file-attachment icons it's unlikely that this bug will ever get
% fixed. Nevertheless, please consider sending a bug report to
@@ -1227,15 +1233,15 @@
% \item It enables (generally older) \acronym{PDF} viewers that don't
% recognize the icon name to still display something meaningful.
% \end{enumerate}
+% \changes{v1.9}{2016/09/16}{Removed redundant \string\texttt{/Subtype
+% /Form} dictionary entries}
% \begin{macrocode}
\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
+ \immediate\pdfxform \atfi@appearancebox
\edef\atfi@appearanceobj{\the\pdflastxform}%
}
% \end{macrocode}
@@ -1275,6 +1281,8 @@
% \changes{v1.8}{2015/11/11}{Strip path names from included files.
% Mikkel Futtrup reported that path names often confuse PDF readers
% on tablets and smartphones}
+% \changes{v1.9}{2016/09/16}{Correctly handle filenames that lack an
+% extension}
% \begin{macrocode}
\DeclareRobustCommand{\atfi@insert@file@annot}[1]{%
\rule{0pt}{0pt}%
@@ -1284,7 +1292,11 @@
\def\noexpand\atfi@file{\atfi@file}%
}\next
\filename@parse{\atfi@file}%
- \edef\atfi@file{\filename@base.\filename@ext}%
+ \@ifundefined{filename@ext}{%
+ \edef\atfi@file{\filename@base}%
+ }{%
+ \edef\atfi@file{\filename@base.\filename@ext}%
+ }%
\ifatfi@appearance
% \end{macrocode}
% We currently use the same appearance for \textsf{N}ormal,
@@ -1349,10 +1361,17 @@
% within this group, embeds the corresponding file into the generated
% \acronym{PDF} file, and places an icon at the current location. Then,
% it ends the group, thereby restoring the original category codes.
+% \changes{v1.9}{2016/09/16}{Issue an error if the requested icon isn't found}
% \begin{macrocode}
\def\atfi@attachfile#1#2{%
\setkeys{AtFi}{#1}%
\atfi@embedfile{#2}%
+ \@ifundefined{atfi@acro\atfi@icon@icon}{%
+ \PackageError{attachfile}{Icon not found}{%
+ attachfile defines only the following icons:\MessageBreak
+ Graph, Paperclip, PushPin, Tag
+ }%
+ }{}%
\atfi@set@appearance{\csname atfi@acro\atfi@icon@icon\endcsname}%
\atfi@flags@to@int%
\atfi@insert@file@annot{#2}%
diff --git a/Master/texmf-dist/source/latex/attachfile/attachfile.ins b/Master/texmf-dist/source/latex/attachfile/attachfile.ins
index dd716e34daf..a53c52e6b7f 100644
--- a/Master/texmf-dist/source/latex/attachfile/attachfile.ins
+++ b/Master/texmf-dist/source/latex/attachfile/attachfile.ins
@@ -3,7 +3,7 @@
%% driver files from the doc files in this package when run through
%% LaTeX or TeX.
%%
-%% Copyright (C) 2015 Scott Pakin <scott+af@pakin.org>
+%% Copyright (C) 2016 Scott Pakin <scott+af@pakin.org>
%% -------------------------------------------------------
%%
%% This package may be distributed and/or modified under the
@@ -28,7 +28,7 @@
This is a generated file.
-Copyright (C) 2015 Scott Pakin <scott+af@pakin.org>
+Copyright (C) 2016 Scott Pakin <scott+af@pakin.org>
-------------------------------------------------------
This package may be distributed and/or modified under the
diff --git a/Master/texmf-dist/tex/latex/attachfile/attachfile.sty b/Master/texmf-dist/tex/latex/attachfile/attachfile.sty
index c7f110aade5..8ba926f85b3 100644
--- a/Master/texmf-dist/tex/latex/attachfile/attachfile.sty
+++ b/Master/texmf-dist/tex/latex/attachfile/attachfile.sty
@@ -8,7 +8,7 @@
%%
%% This is a generated file.
%%
-%% Copyright (C) 2015 Scott Pakin <scott+af@pakin.org>
+%% Copyright (C) 2016 Scott Pakin <scott+af@pakin.org>
%% -------------------------------------------------------
%%
%% This package may be distributed and/or modified under the
@@ -23,7 +23,7 @@
%%
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesPackage{attachfile}
- [2015/11/11 v1.8 PDF 1.3+ file attachment]
+ [2016/09/18 v1.9 PDF 1.3+ file attachment]
\RequirePackage{ifpdf}
\ifpdf
\else
@@ -145,9 +145,7 @@
\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
+ \immediate\pdfxform \atfi@appearancebox
\edef\atfi@appearanceobj{\the\pdflastxform}%
}
\DeclareRobustCommand{\atfi@flags@to@int}{%
@@ -169,7 +167,11 @@
\def\noexpand\atfi@file{\atfi@file}%
}\next
\filename@parse{\atfi@file}%
- \edef\atfi@file{\filename@base.\filename@ext}%
+ \@ifundefined{filename@ext}{%
+ \edef\atfi@file{\filename@base}%
+ }{%
+ \edef\atfi@file{\filename@base.\filename@ext}%
+ }%
\ifatfi@appearance
\def\atfi@appearance@dict{%
/AP <<
@@ -207,6 +209,12 @@
\def\atfi@attachfile#1#2{%
\setkeys{AtFi}{#1}%
\atfi@embedfile{#2}%
+ \@ifundefined{atfi@acro\atfi@icon@icon}{%
+ \PackageError{attachfile}{Icon not found}{%
+ attachfile defines only the following icons:\MessageBreak
+ Graph, Paperclip, PushPin, Tag
+ }%
+ }{}%
\atfi@set@appearance{\csname atfi@acro\atfi@icon@icon\endcsname}%
\atfi@flags@to@int%
\atfi@insert@file@annot{#2}%