Poppler Qt5 25.12.90
Poppler::FormFieldChoice Class Reference

#include <poppler-form.h>

Inheritance diagram for Poppler::FormFieldChoice:
Collaboration diagram for Poppler::FormFieldChoice:

Public Types

enum  ChoiceType { ComboBox , ListBox }
Public Types inherited from Poppler::FormField
enum  AdditionalActionType { FieldModified , FormatField , ValidateField , CalculateField }
enum  FormType { FormButton , FormText , FormChoice , FormSignature }

Public Member Functions

bool canBeSpellChecked () const
QStringList choices () const
QVector< QPair< QString, QString > > choicesWithExportValues () const
ChoiceType choiceType () const
QList< int > currentChoices () const
QString editChoice () const
bool isEditable () const
bool multiSelect () const
void setAppearanceChoiceText (const QString &text)
void setCurrentChoices (const QList< int > &choice)
void setEditChoice (const QString &text)
Qt::Alignment textAlignment () const
FormType type () const override
Public Member Functions inherited from Poppler::FormField
LinkactivationAction () const
LinkadditionalAction (AdditionalActionType type) const
LinkadditionalAction (Annotation::AdditionalActionType type) const
QString fullyQualifiedName () const
int id () const
bool isPrintable () const
bool isReadOnly () const
bool isVisible () const
QString name () const
QRectF rect () const
void setName (const QString &name) const
void setPrintable (bool value)
void setReadOnly (bool value)
void setVisible (bool value)
QString uiName () const

Detailed Description

A form field that represents a choice field.

Since
0.6

Member Enumeration Documentation

◆ ChoiceType

The particular type of this choice field.

Enumerator
ComboBox 

A simple singleline text field.

ListBox 

A multiline text field.

Member Function Documentation

◆ canBeSpellChecked()

bool Poppler::FormFieldChoice::canBeSpellChecked ( ) const

Whether the text inserted manually in the field (where possible) can be spell-checked.

Returns false if the field is not an editable text field.

◆ choicesWithExportValues()

QVector< QPair< QString, QString > > Poppler::FormFieldChoice::choicesWithExportValues ( ) const

The possible choices of the choice field.

The first value of the pair is the display name of the choice, The second value is the export value (i.e. for use in javascript, etc) of the choice

Since
0.87

◆ editChoice()

QString Poppler::FormFieldChoice::editChoice ( ) const

The text entered into an editable combo box choice field.

Otherwise a null string.

Since
0.22

◆ isEditable()

bool Poppler::FormFieldChoice::isEditable ( ) const

Whether this FormFieldChoice::ComboBox is editable, i.e.

the user can type in a custom value.

Always false for the other types of choices.

◆ multiSelect()

bool Poppler::FormFieldChoice::multiSelect ( ) const

Whether more than one choice of this FormFieldChoice::ListBox can be selected at the same time.

Always false for the other types of choices.

◆ setAppearanceChoiceText()

void Poppler::FormFieldChoice::setAppearanceChoiceText ( const QString & text)

Sets the text inside the Appearance Stream to the specified text.

Since
24.08

◆ setEditChoice()

void Poppler::FormFieldChoice::setEditChoice ( const QString & text)

Sets the text entered into an editable combo box choice field.

Otherwise does nothing.

Since
0.22

◆ type()

FormType Poppler::FormFieldChoice::type ( ) const
overridevirtual

The type of the field.

Implements Poppler::FormField.


The documentation for this class was generated from the following file: