14#include <klocalizedstring.h>
29 oldStrokes.append(oldStroke);
34 newStrokes.append(newStroke);
49 Q_FOREACH (
KoShape *shape,
d->shapes) {
50 d->addOldStroke(shape->
stroke());
51 d->addNewStroke(stroke);
63 Q_ASSERT(
shapes.count() == strokes.count());
69 d->addOldStroke(shape->
stroke());
71 d->addNewStroke(stroke);
80 d->shapes.append(shape);
81 d->addNewStroke(stroke);
82 d->addOldStroke(shape->
stroke());
96 Q_FOREACH (
KoShape *shape,
d->shapes) {
108 Q_FOREACH (
KoShape *shape,
d->shapes) {
126 other->
d->shapes !=
d->shapes) {
131 d->newStrokes = other->
d->newStrokes;
void setText(const KUndo2MagicString &text)
The undo / redo command for setting the shape stroke.
QList< KoShapeStrokeModelSP > newStrokes
the new strokes to set
void undo() override
revert the actions done in redo
void addOldStroke(KoShapeStrokeModelSP oldStroke)
void redo() override
redo the command
QList< KoShape * > shapes
the shapes to set stroke for
void addNewStroke(KoShapeStrokeModelSP newStroke)
~KoShapeStrokeCommand() override
KoShapeStrokeCommand(const QList< KoShape * > &shapes, KoShapeStrokeModelSP stroke, KUndo2Command *parent=0)
QList< KoShapeStrokeModelSP > oldStrokes
the old strokes, one for each shape
bool mergeWith(const KUndo2Command *command) override
virtual KoShapeStrokeModelSP stroke() const
virtual QRectF boundingRect() const
Get the bounding box of the shape.
virtual void setStroke(KoShapeStrokeModelSP stroke)
virtual void updateAbsolute(const QRectF &rect) const
KUndo2MagicString kundo2_i18n(const char *text)