source: trunk/poppler/mypoppler/poppler/Annot.h @ 2

Last change on this file since 2 was 2, checked in by Eugene Romanenko, 16 years ago

First import

File size: 1.5 KB
Line 
1//========================================================================
2//
3// Annot.h
4//
5// Copyright 2000-2003 Glyph & Cog, LLC
6//
7//========================================================================
8
9#ifndef ANNOT_H
10#define ANNOT_H
11
12#ifdef USE_GCC_PRAGMAS
13#pragma interface
14#endif
15
16class XRef;
17class Gfx;
18class Catalog;
19
20//------------------------------------------------------------------------
21// Annot
22//------------------------------------------------------------------------
23
24class Annot {
25public:
26
27  Annot(XRef *xrefA, Dict *acroForm, Dict *dict);
28  ~Annot();
29  GBool isOk() { return ok; }
30
31  void draw(Gfx *gfx);
32
33  // Get appearance object.
34  Object *getAppearance(Object *obj) { return appearance.fetch(xref, obj); }
35
36private:
37
38  void generateAppearance(Dict *acroForm, Dict *dict);
39
40  XRef *xref;                   // the xref table for this PDF file
41  Object appearance;            // a reference to the Form XObject stream
42                                //   for the normal appearance
43  GooString *appearBuf;
44  double xMin, yMin,            // annotation rectangle
45         xMax, yMax;
46  GBool ok;
47};
48
49//------------------------------------------------------------------------
50// Annots
51//------------------------------------------------------------------------
52
53class Annots {
54public:
55
56  // Extract non-link annotations from array of annotations.
57  Annots(XRef *xref, Catalog *catalog, Object *annotsObj);
58
59  ~Annots();
60
61  // Iterate through list of annotations.
62  int getNumAnnots() { return nAnnots; }
63  Annot *getAnnot(int i) { return annots[i]; }
64
65private:
66
67  Annot **annots;
68  int nAnnots;
69};
70
71#endif
Note: See TracBrowser for help on using the repository browser.