summaryrefslogtreecommitdiff
path: root/noncore/unsupported/qpdf/xpdf/Annot.h
Unidiff
Diffstat (limited to 'noncore/unsupported/qpdf/xpdf/Annot.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/unsupported/qpdf/xpdf/Annot.h69
1 files changed, 69 insertions, 0 deletions
diff --git a/noncore/unsupported/qpdf/xpdf/Annot.h b/noncore/unsupported/qpdf/xpdf/Annot.h
new file mode 100644
index 0000000..0cc33dd
--- a/dev/null
+++ b/noncore/unsupported/qpdf/xpdf/Annot.h
@@ -0,0 +1,69 @@
1//========================================================================
2//
3// Annot.h
4//
5// Copyright 2000-2002 Glyph & Cog, LLC
6//
7//========================================================================
8
9#ifndef ANNOT_H
10#define ANNOT_H
11
12#ifdef __GNUC__
13#pragma interface
14#endif
15
16#include <aconf.h>
17
18class XRef;
19class Gfx;
20
21//------------------------------------------------------------------------
22// Annot
23//------------------------------------------------------------------------
24
25class Annot {
26public:
27
28 Annot(XRef *xrefA, Dict *dict);
29 ~Annot();
30 GBool isOk() { return ok; }
31
32 void draw(Gfx *gfx);
33
34 // Get appearance object.
35 Object *getAppearance(Object *obj) { return appearance.fetch(xref, obj); }
36
37private:
38
39 XRef *xref; // the xref table for this PDF file
40 Object appearance; // a reference to the Form XObject stream
41 // for the normal appearance
42 fouble xMin, yMin, // annotation rectangle
43 xMax, yMax;
44 GBool ok;
45};
46
47//------------------------------------------------------------------------
48// Annots
49//------------------------------------------------------------------------
50
51class Annots {
52public:
53
54 // Extract non-link annotations from array of annotations.
55 Annots(XRef *xref, Object *annotsObj);
56
57 ~Annots();
58
59 // Iterate through list of annotations.
60 int getNumAnnots() { return nAnnots; }
61 Annot *getAnnot(int i) { return annots[i]; }
62
63private:
64
65 Annot **annots;
66 int nAnnots;
67};
68
69#endif