summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/oberdiek/ifpdf.sty
blob: 0dad5060810a82e3d93d4653838b2fe6539ec97a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
%%
%% This is file `ifpdf.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% ifpdf.dtx  (with options: `package')
%% 
%% Source File: ifpdf.dtx
%% Copyright 2016-2017 Heiko Oberdiek and LaTeX3 project
%%
%% This file may be distributed under the terms of the LPPL.
%% https://www.latex-project.org/lppl/
\ifx\ProvidesPackage\undefined
\def\next#1#2[#3]{\wlog{#2 #3}\expandafter\gdef
\csname ver\string @ifpdf.sty\endcsname{#3}}
\expandafter\next\fi
\ProvidesPackage{ifpdf}
[2017/03/15 v3.2 Provides the ifpdf switch]
\expandafter\ifx\csname ifpdf\endcsname\relax
 \csname newif\expandafter\endcsname\csname ifpdf\endcsname
\else
 \ifx\pdftrue\undefined
  \ifx\PackageError\undefined
  \begingroup\def\PackageError#1#2#3{\endgroup\errmessage{#2}}
  \fi
  \PackageError{ifpdf}{incompatible ifpdf definition}{}
  \expandafter\expandafter\expandafter
 \fi
\fi
\let\ifpdf\iffalse
\ifx\directlua\undefined
\begingroup\expandafter\expandafter\expandafter\endgroup
\expandafter\ifx\csname pdfoutput\endcsname\relax
\else
  \ifnum\pdfoutput>0 %
    \pdftrue
  \fi
\fi
\else
\directlua{%
if (tex.outputmode or tex.pdfoutput or 0) > 0 then
  tex.print('\string\\pdftrue')
end
}
\fi
\endinput
%%
%% End of file `ifpdf.sty'.