source: trunk/poppler/mypoppler/poppler/Outline.h @ 461

Last change on this file since 461 was 257, checked in by Eugene Romanenko, 13 years ago

PDF plugin: Poppler library updated to version 0.10.0

File size: 2.0 KB
Line 
1//========================================================================
2//
3// Outline.h
4//
5// Copyright 2002-2003 Glyph & Cog, LLC
6//
7//========================================================================
8
9//========================================================================
10//
11// Modified under the Poppler project - http://poppler.freedesktop.org
12//
13// All changes made under the Poppler project to this file are licensed
14// under GPL version 2 or later
15//
16// Copyright (C) 2005 Marco Pesenti Gritti <mpg@redhat.com>
17//
18// To see a description of the changes please see the Changelog file that
19// came with your tarball or type make ChangeLog if you are building from git
20//
21//========================================================================
22
23#ifndef OUTLINE_H
24#define OUTLINE_H
25
26#ifdef USE_GCC_PRAGMAS
27#pragma interface
28#endif
29
30#include "Object.h"
31#include "CharTypes.h"
32
33class GooString;
34class GooList;
35class XRef;
36class LinkAction;
37
38//------------------------------------------------------------------------
39
40class Outline {
41public:
42
43  Outline(Object *outlineObj, XRef *xref);
44  ~Outline();
45
46  GooList *getItems() { return items; }
47
48private:
49
50  GooList *items;               // NULL if document has no outline,
51                                // otherwise, a list of OutlineItem
52};
53
54//------------------------------------------------------------------------
55
56class OutlineItem {
57public:
58
59  OutlineItem(Dict *dict, XRef *xrefA);
60  ~OutlineItem();
61
62  static GooList *readItemList(Object *firstItemRef, Object *lastItemRef,
63                             XRef *xrefA);
64
65  void open();
66  void close();
67
68  Unicode *getTitle() { return title; }
69  int getTitleLength() { return titleLen; }
70  LinkAction *getAction() { return action; }
71  GBool isOpen() { return startsOpen; }
72  GBool hasKids() { return firstRef.isRef(); }
73  GooList *getKids() { return kids; }
74
75private:
76
77  XRef *xref;
78  Unicode *title;
79  int titleLen;
80  LinkAction *action;
81  Object firstRef;
82  Object lastRef;
83  Object nextRef;
84  GBool startsOpen;
85  GooList *kids;        // NULL if this item is closed or has no kids,
86                        // otherwise a list of OutlineItem
87};
88
89#endif
Note: See TracBrowser for help on using the repository browser.