Loading...
Searching...
No Matches
PageLabel.h
Go to the documentation of this file.
1//---------------------------------------------------------------------------------------
2// Copyright (c) 2001-2025 by Apryse Software Inc. All Rights Reserved.
3// Consult legal.txt regarding legal and license information.
4//---------------------------------------------------------------------------------------
5#ifndef PDFTRON_H_CPPPDFPageLabel
6#define PDFTRON_H_CPPPDFPageLabel
7
8#include <C/PDF/TRN_PageLabel.h>
9#include <SDF/SDFDoc.h>
10
11namespace pdftron {
12 namespace PDF {
13
87class PageLabel : private TRN_PageLabel
88{
89public:
90
91 // The numbering style to be used for the numeric portion of page label.
101
114 static PageLabel Create(SDF::SDFDoc& doc, Style style, const UString& prefix = "", int start_at = 1);
115
121 PageLabel(SDF::Obj l=0, int first_page=-1, int last_page=-1);
122
127
132
140 bool operator==(const PageLabel& d);
141
147 bool IsValid() const;
148
154 UString GetLabelTitle(int page_num);
155
171 void SetStyle(Style style);
172
177
183
188 void SetPrefix(const UString& prefix);
189
194 int GetStart() const;
195
201 void SetStart(int start_at);
202
208
214
219
220// @cond PRIVATE_DOC
221#ifndef SWIGHIDDEN
222 PageLabel(const TRN_PageLabel&);
223#endif
224// @endcond
225};
226
227
228
229#include <Impl/PageLabel.inl>
230
231 }; // namespace PDF
232}; // namespace pdftron
233
234#endif // PDFTRON_H_CPPPDFPageLabel
bool operator==(const PageLabel &d)
PageLabel(SDF::Obj l=0, int first_page=-1, int last_page=-1)
void SetStyle(Style style)
Style GetStyle() const
PageLabel & operator=(const PageLabel &d)
void SetStart(int start_at)
@ e_roman_uppercase
Uppercase Roman numerals.
Definition PageLabel.h:95
@ e_none
No numeric portion in the label.
Definition PageLabel.h:99
@ e_alphabetic_uppercase
Uppercase letters (A to Z for the first 26 pages, AA to ZZ for the next 26, and so on)
Definition PageLabel.h:97
@ e_decimal
Decimal Arabic numerals.
Definition PageLabel.h:94
@ e_alphabetic_lowercase
Lowercase letters (a to z for the first 26 pages, aa to zz for the next 26, and so on)
Definition PageLabel.h:98
@ e_roman_lowercase
Lowercase Roman numerals.
Definition PageLabel.h:96
void SetPrefix(const UString &prefix)
static PageLabel Create(SDF::SDFDoc &doc, Style style, const UString &prefix="", int start_at=1)
UString GetLabelTitle(int page_num)
SDF::Obj GetSDFObj() const
UString GetPrefix() const
PageLabel(const PageLabel &d)