Akonadi::TagWidget Class
| Header: | #include <Akonadi/TagWidget> |
| CMake: | find_package(KPim6 REQUIRED COMPONENTS AkonadiWidgets)target_link_libraries(mytarget PRIVATE KPim6::AkonadiWidgets) |
Public Functions
| TagWidget(QWidget *parent = nullptr) | |
| virtual | ~TagWidget() override |
| void | clearTags() |
| Akonadi::Tag::List | selection() const |
| void | setReadOnly(bool readOnly) |
| void | setSelection(const Akonadi::Tag::List &tags) |
Signals
| void | selectionChanged(const Akonadi::Tag::List &tags) |
Detailed Description
A widget that shows a tag selection and provides means to edit that selection.
TODO A standalone dialog version that takes an item and takes care of writing back the changes would be useful.
Member Function Documentation
[explicit] TagWidget::TagWidget(QWidget *parent = nullptr)
Creates a new tag widget. parent The parent widget.
[override virtual noexcept] TagWidget::~TagWidget()
Destroys the tag widget.
void TagWidget::clearTags()
Clears all selected tags.
Akonadi::Tag::List TagWidget::selection() const
Returns the currently selected tags. Returns A list of selected tags.
See also setSelection().
[signal] void TagWidget::selectionChanged(const Akonadi::Tag::List &tags)
Emitted when the tag selection has changed. tags The new list of selected tags.
void TagWidget::setReadOnly(bool readOnly)
Sets whether the widget is read-only. readOnly True to make read-only, false to allow editing.
void TagWidget::setSelection(const Akonadi::Tag::List &tags)
Sets the selected tags. tags The list of tags to select.
See also selection().