|
SILICON
|
#include <diagramView.hpp>
Public Slots | |
| void | zoomIn () |
| Increases the circuit zoom by one step. | |
| void | zoomOut () |
| Decreases the circuit zoom by one step. | |
| void | zoomToRect (const QRectF &rect) |
| Centers a scene rectangle and fits it within the existing zoom limits. | |
| void | centerCircuit () |
| Pans the viewport so the circuit's bounds are centered. | |
| void | modeChanged (InteractionMode mode) |
Public Member Functions | |
| DiagramView (QWidget *parent=nullptr) | |
| void | setScene (DiagramScene *scene) |
Protected Member Functions | |
| void | wheelEvent (QWheelEvent *event) override |
Private Member Functions | |
| bool | zoom (int level) |
| void | updateZoom () |
Private Attributes | |
| int | zoomLevel = 100 |
| qreal | wheelZoomRemainder = 0 |
Static Private Attributes | |
| static constexpr int | MIN_ZOOM_LEVEL = 60 |
| static constexpr int | MAX_ZOOM_LEVEL = 200 |
Definition at line 29 of file diagramView.hpp.
|
explicit |
Definition at line 25 of file diagramView.cpp.
|
slot |
Pans the viewport so the circuit's bounds are centered.
Definition at line 127 of file diagramView.cpp.
|
slot |
Definition at line 133 of file diagramView.cpp.
| void setScene | ( | DiagramScene * | scene | ) |
Definition at line 32 of file diagramView.cpp.
|
private |
Definition at line 121 of file diagramView.cpp.
|
overrideprotected |
Definition at line 47 of file diagramView.cpp.
|
private |
Definition at line 109 of file diagramView.cpp.
|
slot |
Increases the circuit zoom by one step.
Definition at line 85 of file diagramView.cpp.
|
slot |
Decreases the circuit zoom by one step.
Definition at line 90 of file diagramView.cpp.
|
slot |
Centers a scene rectangle and fits it within the existing zoom limits.
| rect | Rectangle in scene coordinates; QRect converts to QRectF implicitly. Empty rectangles are ignored. The aspect ratio is preserved. |
Definition at line 95 of file diagramView.cpp.
|
staticconstexprprivate |
Definition at line 55 of file diagramView.hpp.
|
staticconstexprprivate |
Definition at line 54 of file diagramView.hpp.
|
private |
Definition at line 57 of file diagramView.hpp.
|
private |
Definition at line 56 of file diagramView.hpp.