%%
%% This is file `ppdvipdfm.def',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% pdfpages.dtx  (with options: `ppdvipdfmdef')
%% 
%% This file is part of the pdfpages package.
%% 
%% Copyright (C) 2001-2015 Andreas MATTHIAS
%%
%% This work may be distributed and/or modified under the conditions
%% of the LaTeX Project Public License, either version 1.3c
%% 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>.
%%
%% This work has the LPPL maintenance status `maintained'.
%%
%% The Current Maintainer of this work is
%%   Andreas Matthias <andreas.matthias@gmail.com>.
%%
%% Please send error reports and suggestions for improvements to
%%   Andreas MATTHIAS <andreas.matthias@gmail.com>.
%%
\def\AM@fileversion{v0.4y}
\def\AM@Git@Date@process$#1: #2 #3${\AM@Git@Date@process@i#2\END}
\def\AM@Git@Date@process@i#1-#2-#3\END{\def\AM@Git@Date{#1/#2/#3}}
\def\AM@Git@SHA@process$#1: #2${\def\AM@Git@SHA{#2}}
\AM@Git@Date@process$Date: 2015-06-15 20:08:28 +0200 $
\AM@Git@SHA@process$SHA-1: 0a165012872f360ed43fd18b01b5ea77f5f9d6b0 $
\ProvidesFile{ppdvipdfm.def}
   [\AM@Git@Date\space\AM@fileversion\space
    Pdfpages driver for dvipdfm (AM)]
\def\AM@tmp{dvipdfm.def}
\ifx\Gin@driver\AM@tmp\else
  \PackageWarningNoLine{pdfpages}{%
    Graphicx not loaded with driver `dvipdfm'.\MessageBreak
    Please, load graphicx explicitely before pdfpages,\MessageBreak
    e.g.:\MessageBreak
    \@spaces \string\usepackage[dvipdfm]{graphicx}\MessageBreak
    \@spaces \string\usepackage[dvipdfm]{pdfpages}\MessageBreak
    This time I will try to load `dvipdfm.def' which \MessageBreak
    will overwrite `Gin@driver'. Let's hope for the best}%
  \input{dvipdfm.def}%
\fi
\def\AM@notsupported#1{%
  \PackageWarning{pdfpages}{#1 not supported by driver dvipdfm}}
\def\AM@getpagecount{%
  \ifx\AM@pagecount\AM@undefined
    \AM@notsupported{Page selection}
    \def\AM@pagecount{1}%
    \gdef\AM@getpagecount{%
      \def\AM@pagecount{1}%
    }%
  \fi
}
\def\AM@getpagedimen{%
  \AM@pagewidth=\paperwidth
  \AM@pageheight=\paperheight
}
\def\AM@setpagedimen{%
  \paperwidth\AM@pagewidth
  \paperheight\AM@pageheight
}
\let\AM@pagesize@boogie\relax
\def\AM@setRotate{\AM@notsupported{Page rotation}}
\def\AM@resetRotate{}
\def\AM@fitpaper@special{\AM@notsupported{Option fitpaper}}
\def\AM@findfile#1{%
  \AM@findfile@i{#1}{pdf}%
  \AM@findfile@ii{#1}%
}
\let\AM@IfFileExists\IfFileExists
\def\AM@linktodoc@special@begin{%
  \special{pdf: ann
                width \the\wd\@tempboxa\space
                height \the\ht\@tempboxa\space
                depth \the\dp\@tempboxa\space
                << /Type /Annot
                   /Subtype /Link /Border [0 0 0]
                   /A << /S /GoToR
                         /F (\AM@linkfilename)
                         /D [\AM@linktodoc@page@m@ne \AM@linktodocfit]
                         \ifAM@newwindow/NewWindow true\fi >>
                >>}%
}
\let\AM@linktodoc@special@end\relax
\let\AM@survey@special@begin\relax
\let\AM@survey@special@end\relax
\def\AM@thread@special@begin{%
  \special{pdf: thread @\AM@threadname\space
                width \the\wd\@tempboxa\space
                height \the\ht\@tempboxa\space
                depth \the\dp\@tempboxa\space
                <<\threadinfodict>>}%
}
\let\AM@thread@special@end\relax
\def\AM@view{/Fit}
\def\AM@dest@special{%
  \special{pdf: dest (\AM@linkname.\AM@page) [ @thispage \AM@view ]}}
\def\AM@anchor@special{%
  \special{pdf: dest (pdfpages.\the\count1) [ @thispage /Fit ]}}
\def\AM@convert@dest#1{%
  \expandafter\AM@convert@dest@i\ifdim\z@=0pt#1 \END\fi}
\def\AM@convert@dest@i#1 #2\END{%
  \begingroup
  \def\tag{#1}%
  \def\x{FitH}%
  \ifx\x\tag
    \gdef\AM@view{/FitH @ypos}%
  \else
    \def\x{FitBH}%
    \ifx\x\tag
      \gdef\AM@view{/FitBH @ypos}%
    \else
      \def\x{FitV}%
      \ifx\x\tag
        \gdef\AM@view{/FitV @xpos}%
      \else
        \def\x{FitBV}%
        \ifx\x\tag
          \gdef\AM@view{/FitBV @xpos}%
        \else
          \def\x{fitr}%
          \ifx\x\tag
            \gdef\AM@view{/XYZ @xpos @ypos null}%
            \PackageWarningNoLine{pdfpages}{%
              `linkfit=FitR' is not supported.}%
          \else
            \def\x{FitB}%
            \ifx\x\tag
              \gdef\AM@view{/FitB}%
            \else
              \def\x{XYZ}%
              \ifx\x\tag
                \gdef\AM@view{/XYZ @xpos @ypos null}%
              \else
                \def\x{Region}%
                \ifx\x\tag
                  \gdef\AM@view{/XYZ @xpos @ypos null}%
                  \PackageWarningNoLine{pdfpages}{%
                    `linkfit=Region' is not supported by dvipdfm.}%
                \else
                  \gdef\AM@view{/Fit}%
                \fi
              \fi
            \fi
          \fi
        \fi
      \fi
    \fi
  \fi
  \endgroup
}
\def\AM@region@calc{}
\let\AM@disable@includegraphics\relax
\@ifundefined{KV@Gin@page}{%
  \define@key{Gin}{page}{%
    \ifnum#1=1 %
    \else
      \PackageError{pdfpages}{%
        Multipage images are not supported by driver dvipdfm%
      }\@ehc
    \fi
  }}{}
\endinput
%%
%% End of file `ppdvipdfm.def'.
