00001
00002
00003
00004
00005
00006 #ifndef H_CPPPDFPageLabel
00007 #define H_CPPPDFPageLabel
00008
00009 #include <C/PDF/TRN_PageLabel.h>
00010 #include <SDF/SDFDoc.h>
00011
00012 namespace pdftron {
00013 namespace PDF {
00014
00088 class PageLabel : private TRN_PageLabel
00089 {
00090 public:
00091
00092
00093 enum Style
00094 {
00095 e_decimal,
00096 e_roman_uppercase,
00097 e_roman_lowercase,
00098 e_alphabetic_uppercase,
00099 e_alphabetic_lowercase,
00100 e_none
00101 };
00102
00115 static PageLabel Create(SDF::SDFDoc& doc, Style style, const UString& prefix = "", int start_at = 1);
00116
00122 PageLabel(SDF::Obj l=0, int first_page=-1, int last_page=-1);
00123
00127 PageLabel (const PageLabel& d);
00128
00132 PageLabel& operator=(const PageLabel& d);
00133
00141 bool operator==(const PageLabel& d);
00142
00148 bool IsValid() const;
00149
00155 UString GetLabelTitle(int page_num);
00156
00172 void SetStyle(Style style);
00173
00177 Style GetStyle() const;
00178
00183 UString GetPrefix() const;
00184
00189 void SetPrefix(const UString& prefix);
00190
00195 int GetStart() const;
00196
00202 void SetStart(int start_at);
00203
00208 int GetFirstPageNum();
00209
00214 int GetLastPageNum();
00215
00219 SDF::Obj GetSDFObj () const;
00220
00222 PageLabel(const TRN_PageLabel&);
00224 };
00225
00226
00227
00228 #include <Impl/PageLabel.inl>
00229
00230 };
00231 };
00232
00233 #endif