|
| AbstractShapeBrushTool (TileMapPreviewGraphicsItem *previewItem, QUndoStack *undoStack) |
|
void | cellClicked (int x, int y, QMouseEvent *) override |
| Called the first time the left mouse button is pressed over a cell. More...
|
|
void | cellActivated (int x, int y, QMouseEvent *) override |
| Called when the left mouse button is down over a new cell. More...
|
|
void | cellReleased (int x, int y, QMouseEvent *) override |
| Called when the left mouse button is released over a cell. More...
|
|
void | deactivate () override |
| Deactivates the tool. This is called before the tool stops being used. More...
|
|
virtual QRegion | getShape (QPoint start, QPoint end) const =0 |
| This function should output a QVector of points that should be filled in. More...
|
|
| AbstractTileMapTool (TileMapPreviewGraphicsItem *previewItem) |
|
void | setTileMap (TileMap *tileMap) |
|
void | setTileTemplate (TileTemplate *tileTemplate) |
|
virtual void | toolTileMapChanged (TileMap *previous=nullptr) |
| Called whenever mTileMap changes. Called in constructor. More...
|
|
virtual void | cellHovered (int, int, QMouseEvent *) |
| Called when the mouse hovers over a new cell. More...
|
|
virtual void | mouseExitedMap (QMouseEvent *) |
| Called when the mouse is no longer hovering over a cell. More...
|
|
virtual | ~AbstractTool () |
|
virtual void | activate () |
| Activates the tool. This is called before the tool is used. More...
|
|
virtual QList< QAction * > | contextActions () |
| Returns a vector of qactions which can be used to modify the behaviour of the tool. Will be used by the tool manager to add the actions to a context tool bar. More...
|
|
virtual void | mousePressEvent (QMouseEvent *) |
|
virtual void | mouseReleaseEvent (QMouseEvent *) |
|
virtual void | mouseMoveEvent (QMouseEvent *) |
|
virtual void | wheelEvent (QWheelEvent *) |
|
virtual QRegion AbstractShapeBrushTool::getShape |
( |
QPoint |
start, |
|
|
QPoint |
end |
|
) |
| const |
|
pure virtual |
This function should output a QVector of points that should be filled in.
All points are specified as offsets from (0, 0), which is assumed to be the place where the mouse drag started. The point (dx, dy) is the place where the mouse drag ended.
There is no assumption on whether the points lie in the rectangle between (0, 0) and (dx, dy).
- Parameters
-
dx | The X offset from the start of drawing. |
dy | The Y offset from the start of drawing. |
Implemented in LineBrushTool, RectBrushTool, and EllipseBrushTool.