-
Notifications
You must be signed in to change notification settings - Fork 32
/
poppler-convert.sip
87 lines (74 loc) · 2.13 KB
/
poppler-convert.sip
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
namespace Poppler {
class BaseConverter {
%TypeHeaderCode
#include <qt5/poppler-qt5.h>
%End
public:
virtual ~BaseConverter();
void setOutputFileName(const QString &outputFileName);
void setOutputDevice(QIODevice *device);
virtual bool convert() = 0;
enum Error
{
NoError,
FileLockedError,
OpenOutputError,
NotSupportedInputFileError,
};
Error lastError() const;
private:
BaseConverter(const Poppler::BaseConverter&);
}; // class BaseConverter
class PSConverter : Poppler::BaseConverter {
%TypeHeaderCode
#include <qt5/poppler-qt5.h>
%End
public:
enum PSOption {
Printing = 0x00000001,
StrictMargins = 0x00000002,
ForceRasterization = 0x00000004,
%If(POPPLER_V0_20_0 -)
PrintToEPS = 0x00000008,
HideAnnotations = 0x00000010,
%End
};
typedef QFlags<Poppler::PSConverter::PSOption> PSOptions;
~PSConverter();
void setPageList(const QList<int> &pageList);
void setTitle(const QString &title);
void setHDPI(double hDPI);
void setVDPI(double vDPI);
void setRotate(int rotate);
void setPaperWidth(int paperWidth);
void setPaperHeight(int paperHeight);
void setRightMargin(int marginRight);
void setBottomMargin(int marginBottom);
void setLeftMargin(int marginLeft);
void setTopMargin(int marginTop);
void setStrictMargins(bool strictMargins);
void setForceRasterize(bool forceRasterize);
void setPSOptions(PSOptions options);
PSOptions psOptions() const;
bool convert();
private:
PSConverter(const Poppler::PSConverter&);
}; // class PSConverter
class PDFConverter : Poppler::BaseConverter {
%TypeHeaderCode
#include <qt5/poppler-qt5.h>
%End
public:
enum PDFOption {
WithChanges = 0x00000001,
};
typedef QFlags<Poppler::PDFConverter::PDFOption> PDFOptions;
virtual ~PDFConverter();
void setPDFOptions(PDFOptions options);
PDFOptions pdfOptions() const;
bool convert();
private:
PDFConverter(const Poppler::PDFConverter&);
}; // class PDFConverter
}; // namespace Poppler
/* kate: indent-width 4; space-indent on; hl c++; indent-mode cstyle; */