6.1.1.3.1.5. thyrsis.gui.injection_widget module¶
Crisis interface to define simulation with a mininumum of user interface
- class thyrsis.gui.injection_widget.InjectionWidget(type_, canvas, attr=None, parent=None)¶
Bases :
PyQt5.QtWidgets.QWidget
Widget to define the injection properties
- attributes()¶
return a dic of attributes
- Renvoie
dictionnary of injection attributes
- Type renvoyé
dict
- static circle(x, y, area)¶
Create a circle QgsGeometry
- Paramètres
x (float) – x coordinate
y (float) – y coordinate
area (float) – area value
- Renvoie
circle
- Type renvoyé
QgsGeometry
- enterEvent(event)¶
display rubberband
- Paramètres
event (string) – event description
- Renvoie
None
- Type renvoyé
None
- leaveEvent(event)¶
clear rubberband
- Paramètres
event (string) – event description
- Renvoie
None
- Type renvoyé
None
- class thyrsis.gui.injection_widget.RaiiRubberBand(canvas, geom_type)¶
Bases :
object
Decorator that ensures that rubberband is properly removed
- addGeometry(geom, layer)¶
Add a geometry as rubberband
- Paramètres
geom (QgsGeometry) – geometry
layer (QgsVectorLayer) – layer
- Renvoie
None
- Type renvoyé
None
- addPoint(point)¶
set the database property
- Paramètres
point (QgsPoint) – point geometry
- Renvoie
None
- Type renvoyé
None
- asGeometry()¶
return the rubberband as a QgsGeometry
- Renvoie
rubberband geometry
- Type renvoyé
QgsGeometry