From d00f2929d26af30109b9c7f5909b584460b73978 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Fri, 5 Dec 2008 01:52:40 +0000 Subject: new latex package pdfx (4dec08) git-svn-id: svn://tug.org/texlive/trunk@11521 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/tex/latex/pdfx/pdfa-1b.xmp | 73 ++++++++++ Master/texmf-dist/tex/latex/pdfx/pdfx-1a.xmp | 55 ++++++++ Master/texmf-dist/tex/latex/pdfx/pdfx.sty | 201 +++++++++++++++++++++++++++ 3 files changed, 329 insertions(+) create mode 100644 Master/texmf-dist/tex/latex/pdfx/pdfa-1b.xmp create mode 100644 Master/texmf-dist/tex/latex/pdfx/pdfx-1a.xmp create mode 100644 Master/texmf-dist/tex/latex/pdfx/pdfx.sty (limited to 'Master/texmf-dist/tex/latex/pdfx') diff --git a/Master/texmf-dist/tex/latex/pdfx/pdfa-1b.xmp b/Master/texmf-dist/tex/latex/pdfx/pdfa-1b.xmp new file mode 100644 index 00000000000..a811614f18e --- /dev/null +++ b/Master/texmf-dist/tex/latex/pdfx/pdfa-1b.xmp @@ -0,0 +1,73 @@ +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%% +%% File: pdfa-1b.xmp +%% +%% Purpose: This is the engine of Elsevier XSL typesetting +%% packages. This file is complete with other model +%% class files and packages. +%% +%% Copyright (c) 2008, Focal Image (India) Pvt. Ltd., +%% Trivandrum +%% +%% This package is for the exclusive inhouse usage of +%% Focal Image (India) Pvt Ltd., Trivandrum, India, +%% River Valley Technologies, Trivandrum and Exeter, UK, +%% and their associates authorised by the copyright holder. +%% Copying, modifying and redistributing this package for +%% a price or free are expressly prohibited. +%% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +%% $Id: pdfa-1b.xmp,v 1.2 2008/06/24 10:31:38 cvr Exp cvr $ +%% +%% + + + + \xmpProducer + + + application/pdf + \xmpTitle + \xmpAuthor +\@ifundefined{xmpKeywords}{}{\xmpKeywords} + journal + \xmpOrg + \xmpOrg + \ifx\xmpJournalnumber\@empty\relax\else\xmpJournalnumber\fi + \ifx\xmpVolume\@empty\relax\else\xmpVolume\fi + \ifx\xmpIssue\@empty\relax\else\xmpIssue\fi + \ifx\xmpCoverDisplayDate\@empty\relax\else\xmpCoverDisplayDate\fi + \ifx\xmpCoverDate\@empty\relax\else\xmpCoverDate\fi + \ifx\xmpJournaltitle\@empty\relax\else\xmpJournaltitle\fi + \ifx\xmpFirstpage\@empty\relax\else\xmpFirstpage-\xmpLastpage\fi + \ifx\xmpFirstpage\@empty\relax\else\xmpFirstpage\fi + \ifx\xmpLastpage\@empty\relax\else\xmpLastpage\fi + \ifx\xmpDoi\@empty\relax\else\xmpDoi\fi + \ifx\xmpDoi\@empty\relax\elsehttp://dx.doi.org/\xmpDoi\fi + \ifx\xmpDoi\@empty\relax\elsedoi:\xmpDoi\fi + \ifx\xmpAuthoritativeDomain\@empty\relax\else\xmpAuthoritativeDomain\fi + 1 + B + \xmpCreatorTool + True + \convDate + \convDate + \convDate + +% +% uuid:\xmpdocid +% uuid:\xmpinstid +% + + +%% +%% End of pdfa-1b.xmp +%% +%% diff --git a/Master/texmf-dist/tex/latex/pdfx/pdfx-1a.xmp b/Master/texmf-dist/tex/latex/pdfx/pdfx-1a.xmp new file mode 100644 index 00000000000..f99175e832f --- /dev/null +++ b/Master/texmf-dist/tex/latex/pdfx/pdfx-1a.xmp @@ -0,0 +1,55 @@ + + + + + False + PDF/X-1:2001 + PDF/X-1a:2001 + + + \convDate + pdfTeX + \convDate + \convDate + + + pdfTeX + False + \xmpKeywords + + + application/pdf + + + \xmpTitle + + + + + \xmpSubject + + + + + \xmpAuthor + + + + + \xmpKeywords + + + + + uuid:\xmpdocid + uuid:\xmpinstid + + + + + diff --git a/Master/texmf-dist/tex/latex/pdfx/pdfx.sty b/Master/texmf-dist/tex/latex/pdfx/pdfx.sty new file mode 100644 index 00000000000..f10e9d98c93 --- /dev/null +++ b/Master/texmf-dist/tex/latex/pdfx/pdfx.sty @@ -0,0 +1,201 @@ +%% +%% This is file `pdfx.sty', +%% generated with the docstrip utility. +%% +%% The original source files were: +%% +%% pdfx.dtx (with options: `package') +%% +%% Copyright (c) 2008, CV Radhakrishnan , +%% Han The Thanh +%% +%% This file may be distributed and/or modified under the conditions +%% of the LaTeX Project Public License, either version 1.2 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.2 or later is part of all distributions of LaTeX +%% version 1999/12/01 or later. +%% +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{pdfx} + [2008/12/01 v1.1 PDF/X and PDF/A support (CVR/HTH)] + +\newif\ifpdfxonea \pdfxoneafalse +\newif\ifpdfaoneb \pdfaonebfalse + +\DeclareOption{a-1b}{\global\pdfaonebtrue} +\DeclareOption{x-1a}{\global\pdfxoneatrue} +\ProcessOptions + +\ifpdfxonea + \pdfminorversion=3 + \pdfpageattr{/MediaBox[0 0 595 793] + /BleedBox[0 0 595 793] + /TrimBox[25 20 570 773]} +\else + \pdfminorversion=4 +\fi +\def\hash{\expandafter\@gobble\string\#} +\def\amp{\expandafter\@gobble\string\&} +\def\xmpAmp{\amp\hash x0026;} +\def\TextCopyright{\amp\hash x00A9;} +\def\Title#1{\gdef\xmpTitle{#1}} + \let\xmpTitle\@empty +\def\Author#1{\gdef\xmpAuthor{#1}} + \let\xmpAuthor\@empty +\def\Keywords#1{\gdef\xmpKeywords{#1}} + \let\xmpKeywords\@empty + \let\xmpSubject\xmpKeywords +\def\Creator#1{\gdef\xmpCreator{#1}} + \def\xmpCreator{\@pdfcreator} +\def\Producer#1{\gdef\xmpProducer{#1}} + \def\xmpProducer{pdfTeX} +\def\Volume#1{\gdef\xmpVolume{#1}} + \let\xmpVolume\@empty +\def\Issue#1{\gdef\xmpIssue{#1}} + \let\xmpIssue\@empty +\def\CoverDisplayDate#1{\gdef\xmpCoverDisplayDate{#1}} + \let\xmpCoverDisplayDate\@empty +\def\CoverDate#1{\gdef\xmpCoverDate{#1}} + \let\xmpCoverDate\@empty +\def\Copyright#1{\gdef\xmpCopyright{#1}} + \let\xmpCopyright\@empty +\def\Doi#1{\gdef\xmpDoi{#1}} + \let\xmpDoi\@empty +\def\Lastpage#1{\gdef\xmpLastpage{#1}} + \let\xmpLastpage\@empty +\def\Firstpage#1{\gdef\xmpFirstpage{#1}} + \let\xmpFirstpage\@empty +\def\Journaltitle#1{\gdef\xmpJournaltitle{#1}} + \let\xmpJournaltitle\@empty +\def\Journalnumber#1{\gdef\xmpJournalnumber{#1}} + \let\xmpJournalnumber\@empty +\def\Org#1{\gdef\xmpOrg{#1}} + \let\xmpOrg\@empty +\def\CreatorTool#1{\gdef\xmpCreatorTool{#1}} + \def\xmpCreatorTool{\xmpProducer} +\def\AuthoritativeDomain#1{\gdef\xmpAuthoritativeDomain{#1}} + \let\xmpAuthoritativeDomain\@empty +\def\findUUID#1{\edef\tmpstring{\pdfmdfivesum{#1}} + \expandafter\eightofnine\tmpstring\end} +\def\eightofnine#1#2#3#4#5#6#7#8#9\end{% + \xdef\eightchars{#1#2#3#4#5#6#7#8} + \fouroffive#9\end} +\def\fouroffive#1#2#3#4#5\end{\xdef\ffourchars{#1#2#3#4} + \sfouroffive#5\end} +\def\sfouroffive#1#2#3#4#5\end{\xdef\sfourchars{#1#2#3#4} + \tfouroffive#5\end} +\def\tfouroffive#1#2#3#4#5\end{\xdef\tfourchars{#1#2#3#4} + \xdef\laststring{#5}} + +\def\uuid{\eightchars-% + \ffourchars-% + \sfourchars-% + \tfourchars-% + \laststring} + +\findUUID{\jobname.pdf} +\edef\xmpdocid{\uuid} +\findUUID{\pdfcreationdate} +\edef\xmpinstid{\uuid} +\InputIfFileExists{\jobname.xmpdata}{}{} +\RequirePackage{xmpincl} +\def\convertDate{\getYear} +{\catcode`\D=12 + \gdef\getYear D:#1#2#3#4{\edef\xYear{#1#2#3#4}\getMonth} +} +\def\getMonth#1#2{\edef\xMonth{#1#2}\getDay} +\def\getDay#1#2{\edef\xDay{#1#2}\getHour} +\def\getHour#1#2{\edef\xHour{#1#2}\getMin} +\def\getMin#1#2{\edef\xMin{#1#2}\getSec} +\def\getSec#1#2{\edef\xSec{#1#2}\getTZh} +\def\getTZh +#1#2{\edef\xTZh{#1#2}\getTZm} +\def\getTZm '#1#2'{% + \edef\xTZm{#1#2}% + \edef\convDate{\xYear-\xMonth-\xDay + T\xHour:\xMin:\xSec+\xTZh:\xTZm}} +\expandafter\convertDate\pdfcreationdate +\ifpdfxonea + \def\@pctchar{\expandafter\@gobble\string\%} + \def\@bchar{\expandafter\@gobble\string\\} + \immediate\pdfobj stream attr{/N 4} file{FOGRA39L.icc} + \edef\OBJ@CVR{\the\pdflastobj} + \pdfcatalog{/OutputIntents [ << + /Type/OutputIntent + /S/GTS_PDFX + /OutputCondition (FOGRA39) + /OutputConditionIdentifier (FOGRA39 \@bchar(ISO Coated v2 + 300\@pctchar\space \@bchar(ECI\@bchar)\@bchar)) + /DestOutputProfile \OBJ@CVR\space 0 R + /RegistryName(http://www.color.org) + >> ]} +\else + \immediate\pdfobj stream attr{/N 4} file{sRGBIEC1966-2.1.icm} + \edef\OBJ@RVT{\the\pdflastobj} + \pdfcatalog{% + /OutputIntents [ << + /Type /OutputIntent + /S/GTS_PDFA1 + /DestOutputProfile \OBJ@RVT\space 0 R + /OutputConditionIdentifier (sRGB IEC61966-2.1) + /Info(sRGB IEC61966-2.1) + >> ]} +\fi +\begingroup +\let\&=\xmpAmp +\ifpdfxonea + \includexmp{pdfx-1a} +\else + \includexmp{pdfa-1b} +\fi +\endgroup + +\input glyphtounicode.tex +\input glyphtounicode-cmr.tex +\pdfgentounicode=1 +\ifpdfxonea + \RequirePackage[draft,pdftex,pdfpagemode=UseNone,bookmarks=false]{hyperref} + \pdfinfo{ + /Title(\xmpTitle)% + /Author(\xmpAuthor)% + /Creator(\xmpProducer)% + /CreationDate(\convDate)% + /ModDate(\convDate)% + /Producer(\xmpProducer)% + /Trapped /False + /GTS_PDFXVersion (PDF/X-1:2001)% + /GTS_PDFXConformance (PDF/X-1a:2001)% + } +\else + \RequirePackage[pdftex,pdfa]{hyperref} + \def\PDF@FinishDoc{% + \Hy@UseMaketitleInfos + \pdfinfo{% + /Creator(\xmpProducer)% + \ifx\@pdfcreationdate\@empty + \else + /CreationDate(\@pdfcreationdate)% + \fi + \ifx\@pdfmoddate\@empty + \else + /ModDate(\@pdfmoddate)% + \fi + /Producer(\xmpProducer)% + /Trapped /False + /GTS_PDFA1Version (PDF/A-1b:2005)% + }% + \Hy@DisableOption{pdfauthor}% + \Hy@DisableOption{pdftitle}% + \Hy@DisableOption{pdfsubject}% + \Hy@DisableOption{pdfcreator}% + \Hy@DisableOption{pdfcreationdate}% + \Hy@DisableOption{pdfmoddate}% + \Hy@DisableOption{pdfproducer}% + \Hy@DisableOption{pdfkeywords}} +\fi +\endinput +%% +%% End of file `pdfx.sty'. -- cgit v1.2.3