|
Krita Source Code Documentation
|
A pattern shape background. More...
#include <KoPatternBackground.h>
Inheritance diagram for KoPatternBackground:Classes | |
| class | Private |
Public Types | |
| enum | PatternRepeat { Original , Tiled , Stretched } |
| Pattern rendering style. More... | |
| enum | ReferencePoint { TopLeft , Top , TopRight , Left , Center , Right , BottomLeft , Bottom , BottomRight } |
| Pattern reference point. More... | |
Public Member Functions | |
| bool | compareTo (const KoShapeBackground *other) const override |
| KoPatternBackground () | |
| KoPatternBackground (const KoPatternBackground &) | |
| KoPatternBackground & | operator= (const KoPatternBackground &) |
| void | paint (QPainter &painter, const QPainterPath &fillPath) const override |
| reimplemented from KoShapeBackground | |
| QImage | pattern () const |
| Returns the pattern. | |
| QSizeF | patternDisplaySize () const |
| Returns the pattern display size. | |
| QSizeF | patternOriginalSize () const |
| Returns the original image size. | |
| QRectF | patternRectFromFillSize (const QSizeF &size) |
| Returns the bounding rect of the pattern image based on the given fill size. | |
| ReferencePoint | referencePoint () const |
| Returns the pattern reference point identifier. | |
| QPointF | referencePointOffset () const |
| Returns reference point offset in percent of the pattern display size. | |
| PatternRepeat | repeat () const |
| Returns the pattern repeat. | |
| void | setPattern (const QImage &pattern) |
| Sets a new pattern. | |
| void | setPatternDisplaySize (const QSizeF &size) |
| Sets pattern display size. | |
| void | setReferencePoint (ReferencePoint referencePoint) |
| Sets the pattern reference point. | |
| void | setReferencePointOffset (const QPointF &offset) |
| Sets the reference point offset in percent of the pattern display size. | |
| void | setRepeat (PatternRepeat repeat) |
| Sets the pattern repeatgfl. | |
| void | setTileRepeatOffset (const QPointF &offset) |
| Sets the tile repeat offset in percent of the pattern display size. | |
| void | setTransform (const QTransform &matrix) |
| Sets the transform matrix. | |
| QPointF | tileRepeatOffset () const |
| Returns tile repeat offset in percent of the pattern display size. | |
| QTransform | transform () const |
| Returns the transform matrix. | |
| ~KoPatternBackground () override | |
Public Member Functions inherited from KoShapeBackground | |
| virtual bool | hasTransparency () const |
| Returns if the background has some transparency. | |
| KoShapeBackground () | |
| virtual | operator bool () const |
| virtual | ~KoShapeBackground () |
Private Attributes | |
| QSharedDataPointer< Private > | d |
A pattern shape background.
Definition at line 23 of file KoPatternBackground.h.
Pattern rendering style.
| Enumerator | |
|---|---|
| Original | |
| Tiled | |
| Stretched | |
Definition at line 27 of file KoPatternBackground.h.
Pattern reference point.
| Enumerator | |
|---|---|
| TopLeft | |
| Top | |
| TopRight | |
| Left | |
| Center | |
| Right | |
| BottomLeft | |
| Bottom | |
| BottomRight | |
Definition at line 33 of file KoPatternBackground.h.
|
explicit |
Definition at line 110 of file KoPatternBackground.cpp.
|
override |
Definition at line 116 of file KoPatternBackground.cpp.
| KoPatternBackground::KoPatternBackground | ( | const KoPatternBackground & | rhs | ) |
Definition at line 120 of file KoPatternBackground.cpp.
|
overridevirtual |
Implements KoShapeBackground.
Definition at line 131 of file KoPatternBackground.cpp.
| KoPatternBackground & KoPatternBackground::operator= | ( | const KoPatternBackground & | rhs | ) |
Definition at line 125 of file KoPatternBackground.cpp.
References d.
|
overridevirtual |
reimplemented from KoShapeBackground
Implements KoShapeBackground.
Definition at line 216 of file KoPatternBackground.cpp.
| QImage KoPatternBackground::pattern | ( | ) | const |
| QSizeF KoPatternBackground::patternDisplaySize | ( | ) | const |
Returns the pattern display size.
Definition at line 200 of file KoPatternBackground.cpp.
References d.
| QSizeF KoPatternBackground::patternOriginalSize | ( | ) | const |
Returns the original image size.
Definition at line 211 of file KoPatternBackground.cpp.
References d.
| QRectF KoPatternBackground::patternRectFromFillSize | ( | const QSizeF & | size | ) |
Returns the bounding rect of the pattern image based on the given fill size.
Definition at line 263 of file KoPatternBackground.cpp.
| KoPatternBackground::ReferencePoint KoPatternBackground::referencePoint | ( | ) | const |
Returns the pattern reference point identifier.
Definition at line 167 of file KoPatternBackground.cpp.
References d.
| QPointF KoPatternBackground::referencePointOffset | ( | ) | const |
Returns reference point offset in percent of the pattern display size.
Definition at line 177 of file KoPatternBackground.cpp.
References d.
| KoPatternBackground::PatternRepeat KoPatternBackground::repeat | ( | ) | const |
| void KoPatternBackground::setPattern | ( | const QImage & | pattern | ) |
Sets a new pattern.
Definition at line 147 of file KoPatternBackground.cpp.
| void KoPatternBackground::setPatternDisplaySize | ( | const QSizeF & | size | ) |
| void KoPatternBackground::setReferencePoint | ( | ReferencePoint | referencePoint | ) |
Sets the pattern reference point.
Definition at line 172 of file KoPatternBackground.cpp.
References d, and referencePoint().
| void KoPatternBackground::setReferencePointOffset | ( | const QPointF & | offset | ) |
Sets the reference point offset in percent of the pattern display size.
Definition at line 182 of file KoPatternBackground.cpp.
References d.
| void KoPatternBackground::setRepeat | ( | PatternRepeat | repeat | ) |
Sets the pattern repeatgfl.
Definition at line 157 of file KoPatternBackground.cpp.
| void KoPatternBackground::setTileRepeatOffset | ( | const QPointF & | offset | ) |
Sets the tile repeat offset in percent of the pattern display size.
Definition at line 195 of file KoPatternBackground.cpp.
References d.
| void KoPatternBackground::setTransform | ( | const QTransform & | matrix | ) |
| QPointF KoPatternBackground::tileRepeatOffset | ( | ) | const |
Returns tile repeat offset in percent of the pattern display size.
Definition at line 190 of file KoPatternBackground.cpp.
References d.
| QTransform KoPatternBackground::transform | ( | ) | const |
|
private |
Definition at line 107 of file KoPatternBackground.h.