summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty')
-rw-r--r--Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty47
1 files changed, 31 insertions, 16 deletions
diff --git a/Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty b/Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty
index e76fa1e8799..5933861a84d 100644
--- a/Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty
+++ b/Master/texmf-dist/tex/latex/hyperxmp/hyperxmp.sty
@@ -22,7 +22,7 @@
%%
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesPackage{hyperxmp}
- [2019/03/31 v4.0 Store hyperref metadata in XMP format]
+ [2019/04/05 v4.1 Store hyperref metadata in XMP format]
\edef\hyxmp@dq@code{\the\catcode`\"}
\catcode`\"=12
\def\hyxmp@driver{hpdftex}
@@ -108,6 +108,8 @@
\define@key{Hyp}{pdfisbn}{\hyxmp@pdfstringdef\@pdfisbn{#1}}
\def\@pdfbookedition{}
\define@key{Hyp}{pdfbookedition}{\hyxmp@pdfstringdef\@pdfbookedition{#1}}
+\def\@pdfpublisher{}
+\define@key{Hyp}{pdfpublisher}{\hyxmp@pdfstringdef\@pdfpublisher{#1}}
\def\@pdfvolumenum{}
\define@key{Hyp}{pdfvolumenum}{\hyxmp@pdfstringdef\@pdfvolumenum{#1}}
\def\@pdfissuenum{}
@@ -243,10 +245,10 @@
}%
\ifx\hyxmp@concated@metadata\@empty
\PackageWarningNoLine{hyperxmp}{%
-\jobname.tex did not specify any metadata to\MessageBreak
-include in the XMP packet.\space\space Please see the\MessageBreak
-hyperxmp documentation for instructions on how to\MessageBreak
-provide metadata values to hyperxmp}%
+ \jobname.tex did not specify any metadata to\MessageBreak
+ include in the XMP packet.\space\space Please see the\MessageBreak
+ hyperxmp documentation for instructions on how to\MessageBreak
+ provide metadata values to hyperxmp}%
\fi
}
\AtBeginDocument{%
@@ -278,18 +280,18 @@ provide metadata values to hyperxmp}%
}%
}%
{}%
- \hyxmp@at@end{%
\hyxmp@suppress@pdf@metadata
+ \hyxmp@at@end{%
\hyxmp@find@metadata
\hyxmp@embed@packet
}%
}{%
\PackageWarningNoLine{hyperxmp}{%
-\jobname.tex failed to include a\MessageBreak
-\string\usepackage\string{hyperref\string}
-in the preamble.\MessageBreak
-Consequently, all hyperxmp functionality will be\MessageBreak
-disabled}%
+ \jobname.tex failed to include a\MessageBreak
+ \string\usepackage\string{hyperref\string}
+ in the preamble.\MessageBreak
+ Consequently, all hyperxmp functionality will be\MessageBreak
+ disabled}%
}%
}
\newcommand*{\hyxmp@commas@to@list}[2]{%
@@ -405,7 +407,7 @@ disabled}%
\expandafter\hyxmp@xmp@to@pdf@date@vi\expandafter#4%
\fi
}
-\let\@hyxmp@gobbletwo=\@gobbletwo
+\let\hyxmp@gobbletwo=\@gobbletwo
\def\hyxmp@xmp@to@pdf@date@vi#1#2#3#4{%
#1#2%
\ifx#3+%
@@ -418,7 +420,7 @@ disabled}%
Z%
\fi
\ifx#3\relax
- \expandafter\@hyxmp@gobbletwo
+ \expandafter\hyxmp@gobbletwo
\fi
\@gobbletwo #4%
}
@@ -942,16 +944,29 @@ ______</dc:#2>^^J%
}%
\fi
}
+\newcommand{\hyxmp@singleton@dc}[3][Bag]{%
+ \@ifnotmtarg{#3}{%
+ \hyxmp@xmlify{#3}%
+ \hyxmp@add@to@xml{%
+______<dc:#2>^^J%
+________<rdf:#1>^^J%
+__________<rdf:li>\hyxmp@xmlified</rdf:li>^^J%
+________</rdf:#1>^^J%
+______</dc:#2>^^J%
+ }%
+ }
+}
\newcommand*{\hyxmp@dc@schema}{%
\hyxmp@add@simple{dc:format}{application/pdf}%
\hyxmp@rdf@dc[\ifHy@pdfa]{title}{\@pdftitle}%
\hyxmp@rdf@dc[\ifHy@pdfa]{description}{\@pdfsubject}%
\hyxmp@rdf@dc{rights}{\@pdfcopyright}%
+ \hyxmp@singleton@dc{publisher}{\@pdfpublisher}%
+ \hyxmp@singleton@dc[Seq]{date}{\hyxmp@today}%
+ \hyxmp@singleton@dc{language}{\@pdflang}%
+ \hyxmp@singleton@dc{type}{\@pdftype}%
\hyxmp@list@to@xml[\ifHy@pdfa]{creator}{Seq}{\hyxmp@pdfauthor}%
\hyxmp@list@to@xml{subject}{Bag}{\hyxmp@pdfkeywords}%
- \hyxmp@list@to@xml{date}{Seq}{\hyxmp@today}%
- \hyxmp@list@to@xml{language}{Bag}{\@pdflang}%
- \hyxmp@list@to@xml{type}{Bag}{\@pdftype}%
\ifx\@pdfsource\@empty
\else
\hyxmp@add@simple{dc:source}{\@pdfsource}%