Debian Codegraph @

texk/dvipdfm-x/dpxconf.h

raw
1 /* This is DVIPDFMx, an eXtended version of DVIPDFM by Mark A. Wicks.
2
3 Copyright (C) 2002-2020 by Jin-Hwan Cho and Shunsaku Hirata,
4 the dvipdfmx project team.
5
6 Copyright (C) 1998, 1999 by Mark A. Wicks <[email protected]>
7
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2 of the License, or
11 (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
21 */
22
23 #ifndef _DPXCONF_H_
24 #define _DPXCONF_H_
25
26 enum dpx_mode {
27 dpx_mode_normal_mode,
28 dpx_mode_compat_mode,
29 dpx_mode_xdv_mode,
30 dpx_mode_mpost_mode
31 };
32
33 extern struct _dpx_conf {
34 int is_xbb;
35 int verbose_level;
36 enum dpx_mode compat_mode;
37 int ignore_font_license;
38 int pdfm_str_utf8;
39 struct {
40 int keep_cache;
41 } file;
42 } dpx_conf;
43
44 #ifdef HAVE_LIBPAPER
45 #include <paper.h>
46 #else
47 struct paper {
48 const char* name;
49 double pswidth, psheight;
50 };
51
52 #ifndef DEFAULT_PAPER_NAME
53 #define DEFAULT_PAPER_NAME "a4"
54 #endif
55
56 extern const struct paper paperspecs[];
57 extern const struct paper *paperinfo (const char *ppformat);
58
59 #define paperinit()
60 #define paperdone()
61 #define paperpswidth(p) (((p) && (p)->name) ? p->pswidth : 0.0)
62 #define paperpsheight(p) (((p) && (p)->name) ? p->psheight : 0.0)
63 #define papername(p) (((p) && (p)->name) ? p->name : NULL)
64 #define paperfirst() &(paperspecs[0])
65 #define papernext(p) ((((p)+1) && ((p)+1)->name) ? (p+1) : NULL)
66
67 #define defaultpapername() DEFAULT_PAPER_NAME
68 #define systempapername() DEFAULT_PAPER_NAME
69
70 #define defaultpapersizefile() NULL
71 #define systempapersizefile() NULL
72 #endif /* HAVE_LIBPAPER */
73
74 extern void dumppaperinfo (void);
75
76 #endif /* _DPXCONF_H_ */