Changeset View
Changeset View
Standalone View
Standalone View
libs/image/kis_painter.h
Show First 20 Lines • Show All 629 Lines • ▼ Show 20 Line(s) | 91 | public: | |||
---|---|---|---|---|---|
630 | /** | 630 | /** | ||
631 | * Return the active paintop (which is created based on the specified preset and | 631 | * Return the active paintop (which is created based on the specified preset and | ||
632 | * will be deleted as soon as the KisPainter instance dies). | 632 | * will be deleted as soon as the KisPainter instance dies). | ||
633 | */ | 633 | */ | ||
634 | KisPaintOp* paintOp() const; | 634 | KisPaintOp* paintOp() const; | ||
635 | 635 | | |||
636 | void setMirrorInformation(const QPointF &axesCenter, bool mirrorHorizontally, bool mirrorVertically); | 636 | void setMirrorInformation(const QPointF &axesCenter, bool mirrorHorizontally, bool mirrorVertically); | ||
637 | 637 | | |||
638 | void copyMirrorInformationFrom(const KisPainter *other); | ||||
639 | | ||||
638 | /** | 640 | /** | ||
639 | * Returns whether the mirroring methods will do any | 641 | * Returns whether the mirroring methods will do any | ||
640 | * work when called | 642 | * work when called | ||
641 | */ | 643 | */ | ||
642 | bool hasMirroring() const; | 644 | bool hasMirroring() const; | ||
643 | 645 | | |||
644 | /** | 646 | /** | ||
645 | * Indicates if horizontal mirroring mode is activated | 647 | * Indicates if horizontal mirroring mode is activated | ||
Show All 12 Lines | |||||
658 | void mirrorRect(Qt::Orientation direction, QRect *rc) const; | 660 | void mirrorRect(Qt::Orientation direction, QRect *rc) const; | ||
659 | 661 | | |||
660 | /** | 662 | /** | ||
661 | * Mirror \p dab in the requested direction around the center point defined | 663 | * Mirror \p dab in the requested direction around the center point defined | ||
662 | * in the painter. The dab's offset is adjusted automatically. | 664 | * in the painter. The dab's offset is adjusted automatically. | ||
663 | */ | 665 | */ | ||
664 | void mirrorDab(Qt::Orientation direction, KisRenderedDab *dab) const; | 666 | void mirrorDab(Qt::Orientation direction, KisRenderedDab *dab) const; | ||
665 | 667 | | |||
668 | /** | ||||
669 | * Calculate the list of the mirrored rects that will be painted on the | ||||
670 | * the canvas when calling renderMirrorMask() at al | ||||
671 | */ | ||||
672 | const QVector<QRect> calculateAllMirroredRects(const QRect &rc); | ||||
673 | | ||||
666 | /// Set the current pattern | 674 | /// Set the current pattern | ||
667 | void setPattern(const KoPattern * pattern); | 675 | void setPattern(const KoPattern * pattern); | ||
668 | 676 | | |||
669 | /// Returns the currently set pattern | 677 | /// Returns the currently set pattern | ||
670 | const KoPattern * pattern() const; | 678 | const KoPattern * pattern() const; | ||
671 | 679 | | |||
672 | /** | 680 | /** | ||
673 | * Set the color that will be used to paint with, and convert it | 681 | * Set the color that will be used to paint with, and convert it | ||
▲ Show 20 Lines • Show All 85 Lines • ▼ Show 20 Line(s) | |||||
759 | void setCompositeOp(const KoCompositeOp * op); | 767 | void setCompositeOp(const KoCompositeOp * op); | ||
760 | const KoCompositeOp * compositeOp(); | 768 | const KoCompositeOp * compositeOp(); | ||
761 | 769 | | |||
762 | /// Set the composite op for this painter by string. | 770 | /// Set the composite op for this painter by string. | ||
763 | /// Note: the colorspace must be set previously! | 771 | /// Note: the colorspace must be set previously! | ||
764 | void setCompositeOp(const QString& op); | 772 | void setCompositeOp(const QString& op); | ||
765 | 773 | | |||
766 | /** | 774 | /** | ||
767 | * Add the r to the current dirty rect. | 775 | * Add \p r to the current set of dirty rects | ||
768 | */ | 776 | */ | ||
769 | void addDirtyRect(const QRect & r); | 777 | void addDirtyRect(const QRect &r); | ||
770 | 778 | | |||
771 | /** | 779 | /** | ||
780 | * Add \p rects to the current set of dirty rects | ||||
781 | */ | ||||
782 | void addDirtyRects(const QVector<QRect> &rects); | ||||
783 | | ||||
784 | /** | ||||
772 | * Reset the selection to the given selection. All painter actions will be | 785 | * Reset the selection to the given selection. All painter actions will be | ||
773 | * masked by the specified selection. | 786 | * masked by the specified selection. | ||
774 | */ | 787 | */ | ||
775 | void setSelection(KisSelectionSP selection); | 788 | void setSelection(KisSelectionSP selection); | ||
776 | 789 | | |||
777 | /** | 790 | /** | ||
778 | * @return the selection set on this painter. | 791 | * @return the selection set on this painter. | ||
779 | */ | 792 | */ | ||
▲ Show 20 Lines • Show All 87 Lines • Show Last 20 Lines |