#include <kis_pattern_chooser.h>
Definition at line 19 of file kis_pattern_chooser.h.
◆ KisPatternChooser()
| KisPatternChooser::KisPatternChooser |
( |
QWidget * | parent = 0 | ) |
|
Definition at line 29 of file kis_pattern_chooser.cc.
30 : QFrame(parent)
31{
33 m_lblName->setTextElideMode(Qt::ElideMiddle);
34 m_lblName->setSizePolicy(QSizePolicy::Ignored, QSizePolicy::Fixed);
35
41
44
47
48 QVBoxLayout *mainLayout = new QVBoxLayout(this);
49 mainLayout->setSizeConstraint(QLayout::SetMinAndMaxSize);
50 mainLayout->setContentsMargins(0, 0, 0, 0);
53}
connect(this, SIGNAL(optionsChanged()), this, SLOT(saveOptions()))
KisResourceItemChooser * m_itemChooser
KSqueezedTextLabel * m_lblName
void update(KoResourceSP resource)
void resourceSelected(KoResourceSP resource)
Emitted when a resource was selected.
void setPreviewOrientation(Qt::Orientation orientation)
determines whether the preview right or below the splitter
void setPreviewTiled(bool tiled)
determines whether the preview should tile the resource's image or not
void showTaggingBar(bool show)
void setSynced(bool sync)
References connect(), m_itemChooser, m_lblName, ResourceType::Patterns, resourceSelected(), KisResourceItemChooser::setPreviewOrientation(), KisResourceItemChooser::setPreviewTiled(), KisResourceItemChooser::setSynced(), KisResourceItemChooser::showTaggingBar(), and update().
◆ ~KisPatternChooser()
| KisPatternChooser::~KisPatternChooser |
( |
| ) |
|
|
override |
◆ currentResource()
| KoResourceSP KisPatternChooser::currentResource |
( |
bool | includeHidden = false | ) |
|
◆ resourceSelected
Emitted when a resource was selected.
◆ setCurrentItem
| void KisPatternChooser::setCurrentItem |
( |
int | row | ) |
|
|
slot |
◆ setCurrentPattern
◆ setGrayscalePreview()
| void KisPatternChooser::setGrayscalePreview |
( |
bool | grayscale | ) |
|
◆ setPreviewOrientation()
| void KisPatternChooser::setPreviewOrientation |
( |
Qt::Orientation | orientation | ) |
|
◆ update
Definition at line 94 of file kis_pattern_chooser.cc.
95{
96 if (!resource) return;
97
99 m_lblName->setText(QString(
"%1 (%2 x %3)").arg(i18n(pattern->name().toUtf8().data())).arg(pattern->width()).arg(pattern->height()));
100}
References m_lblName.
◆ updateItemSize
| void KisPatternChooser::updateItemSize |
( |
| ) |
|
|
signal |
◆ m_itemChooser
◆ m_lblName
| KSqueezedTextLabel* KisPatternChooser::m_lblName |
|
private |
The documentation for this class was generated from the following files: