![]() |
#include <Text.h>
Public Types | |
enum | Icon { e_Comment, e_Key, e_Help, e_NewParagraph, e_Paragraph, e_Insert, e_Note, e_Unknown } |
Icon enumeration defines the type of icon associated with the Text annotation. More... | |
Public Member Functions | |
Text (SDF::Obj d=0) | |
Creates a Text annotation and initializes it using given Cos/SDF object. | |
Text (const Annot &mku) | |
Creates a Text annotation and initializes it using given annotation object. | |
bool | IsOpen () const |
Returns the initial status of the Text annotation. | |
void | SetOpen (bool isopen) |
Sets the initial status of the Text annotation. | |
Icon | GetIcon () const |
Returns the type of the icon associated with the Text annotation. | |
const char * | GetIconName () const |
Returns the name of the icon associated with the Text annotation. | |
void | SetIcon (Icon icon=e_Note) |
Sets the type of the icon associated with the Text annotation. | |
void | SetIcon (const char *icon) |
Sets the name of the icon associated with the Text annotation. | |
UString | GetState () const |
Returns the string indicating the state of the Text annotation. | |
void | SetState (const UString &state="") |
Sets the string indicating the state of the Text annotation. | |
UString | GetStateModel () const |
Returns the string indicating the state model of the Text annotation. | |
void | SetStateModel (const UString &sm) |
Sets the string indicating the state model of the Text annotation. | |
Static Public Member Functions | |
static Text | Create (SDF::SDFDoc &doc, const Rect &pos, const UString &contents=UString("")) |
Creates a new Text annotation in the specified document. | |
static Text | Create (SDF::SDFDoc &doc, const Point &pos, const UString &contents=UString("")) |
Creates a new Text annotation in the specified document. |
When closed, the annotation shall appear as an icon; when open, it shall display a pop-up window containing the text of the note in a font and size chosen by the conforming reader. Text annotations do not scale and rotate with the page (i.e. they should behave as if the NoZoom and NoRotate annotation flags).
Icon enumeration defines the type of icon associated with the Text annotation.
pdftron::PDF::Annots::Text::Text | ( | SDF::Obj | d = 0 |
) |
Creates a Text annotation and initializes it using given Cos/SDF object.
pdftron::PDF::Annots::Text::Text | ( | const Annot & | mku | ) | [inline] |
Creates a Text annotation and initializes it using given annotation object.
static Text pdftron::PDF::Annots::Text::Create | ( | SDF::SDFDoc & | doc, | |
const Rect & | pos, | |||
const UString & | contents = UString("") | |||
) | [static] |
Creates a new Text annotation in the specified document.
doc | A document to which the annotation is added. | |
pos | A rectangle specifying the annotation's bounds in default user space units. |
doc | A document to which the annotation is added. | |
pos | A rectangle specifying the annotation's bounds in default user space units. | |
contents | The text of the annotation, that shall be displayed in its popup window. |
static Text pdftron::PDF::Annots::Text::Create | ( | SDF::SDFDoc & | doc, | |
const Point & | pos, | |||
const UString & | contents = UString("") | |||
) | [static] |
Creates a new Text annotation in the specified document.
doc | A document to which the annotation is added. | |
pos | A point specifying the annotation's location in default user space units. | |
contents | The text of the annotation, that shall be displayed in its popup window. |
bool pdftron::PDF::Annots::Text::IsOpen | ( | ) | const |
Returns the initial status of the Text annotation.
void pdftron::PDF::Annots::Text::SetOpen | ( | bool | isopen | ) |
Sets the initial status of the Text annotation.
(Optional)
isopen | A boolean value that specifies whether the annotation shall initially be displayed as opened. Default value: false. |
Icon pdftron::PDF::Annots::Text::GetIcon | ( | ) | const |
Returns the type of the icon associated with the Text annotation.
const char* pdftron::PDF::Annots::Text::GetIconName | ( | ) | const |
Returns the name of the icon associated with the Text annotation.
The annotation’s appearance stream, if present, will take precedence over this entry.
void pdftron::PDF::Annots::Text::SetIcon | ( | Icon | icon = e_Note |
) |
Sets the type of the icon associated with the Text annotation.
(Optional)
icon | A value of the enum "Icon" type. Default value: e_Note. |
void pdftron::PDF::Annots::Text::SetIcon | ( | const char * | icon | ) |
Sets the name of the icon associated with the Text annotation.
(Optional)
icon | A string denoting the name of the icon. |
The annotation’s appearance stream, if present, will take precedence over this entry.
UString pdftron::PDF::Annots::Text::GetState | ( | ) | const |
void pdftron::PDF::Annots::Text::SetState | ( | const UString & | state = "" |
) |
UString pdftron::PDF::Annots::Text::GetStateModel | ( | ) | const |
void pdftron::PDF::Annots::Text::SetStateModel | ( | const UString & | sm | ) |