Poppler.AnnotText

g GObject.Object GObject.Object Poppler.Annot Poppler.Annot GObject.Object->Poppler.Annot Poppler.AnnotMarkup Poppler.AnnotMarkup Poppler.Annot->Poppler.AnnotMarkup Poppler.AnnotText Poppler.AnnotText Poppler.AnnotMarkup->Poppler.AnnotText

Subclasses:

None

Methods

Inherited:

Poppler.AnnotMarkup (14), Poppler.Annot (14), GObject.Object (37)

Structs:

GObject.ObjectClass (5)

class

new (doc, rect)

get_icon ()

get_is_open ()

get_state ()

set_icon (icon)

set_is_open (is_open)

Virtual Methods

Inherited:

GObject.Object (7)

Properties

None

Signals

Inherited:

GObject.Object (1)

Fields

Inherited:

GObject.Object (1)

Class Details

class Poppler.AnnotText(**kwargs)
Bases:

Poppler.AnnotMarkup

Abstract:

No

An annotation for text.

Since 25.06 this type supports g_autoptr

classmethod new(doc, rect)
Parameters:
Returns:

A newly created Poppler.AnnotText annotation

Return type:

Poppler.Annot

Creates a new Text annotation that will be located on rect when added to a page. See Poppler.Page.add_annot()

New in version 0.16.

get_icon()
Returns:

a new allocated string containing the icon name

Return type:

str

Gets name of the icon of self.

get_is_open()
Returns:

the state of self. True if it’s open, False in other case.

Return type:

bool

Retrieves the state of self.

get_state()
Returns:

Poppler.AnnotTextState of self.

Return type:

Poppler.AnnotTextState

Retrieves the state of self.

set_icon(icon)
Parameters:

icon (str) – the name of an icon

Sets the icon of self. The following predefined icons are currently supported:

Poppler.ANNOT_TEXT_ICON_NOTE

Poppler.ANNOT_TEXT_ICON_COMMENT

Poppler.ANNOT_TEXT_ICON_KEY

Poppler.ANNOT_TEXT_ICON_HELP

Poppler.ANNOT_TEXT_ICON_NEW_PARAGRAPH

Poppler.ANNOT_TEXT_ICON_PARAGRAPH

Poppler.ANNOT_TEXT_ICON_INSERT

Poppler.ANNOT_TEXT_ICON_CROSS

Poppler.ANNOT_TEXT_ICON_CIRCLE

Since 26.1.0, Poppler also knows how to render the following icons, which are somewhat standard and other PDF renderers may also support:

Poppler.ANNOT_TEXT_ICON_CHECK

Poppler.ANNOT_TEXT_ICON_STAR

Poppler.ANNOT_TEXT_ICON_RIGHT_ARROW

Poppler.ANNOT_TEXT_ICON_RIGHT_POINTER

Poppler.ANNOT_TEXT_ICON_UP_ARROW

Poppler.ANNOT_TEXT_ICON_UP_LEFT_ARROW

Poppler.ANNOT_TEXT_ICON_CROSS_HAIRS

New in version 0.16.

set_is_open(is_open)
Parameters:

is_open (bool) – whether annotation should initially be displayed open

Sets whether self should initially be displayed open

New in version 0.16.