RQLineEdit

class pyreaqtive.widgets.rqlineedit.RQLineEdit(model: Union[pyreaqtive.models.rqtext.RQText, str, pyreaqtive.models.rqobject.RQObject], *args, rq_if: Optional[pyreaqtive.models.rqbool.RQBool] = None, **kwargs)

Bases: pyreaqtive.widgets.rqwidget.RQWidget, PyQt5.QtWidgets.QLineEdit

Reactive LineEdit Widget

model: Union[pyreaqtive.models.rqtext.RQText, pyreaqtive.models.rqobject.RQObject]

Model linked to the widget

__init__(model: Union[pyreaqtive.models.rqtext.RQText, str, pyreaqtive.models.rqobject.RQObject], *args, rq_if: Optional[pyreaqtive.models.rqbool.RQBool] = None, **kwargs)

Constructor.

Parameters
  • model – Model to link the widget to

  • args – arguments to pass to the native pyqt widget

  • rq_if – RQBool that controls the visibility

  • **kwargs – arguments to pass to the native pyqt widget

_rq_data_changed()None

Slot triggered when the model changes text.

Updates value of the LineEdit

_rq_writing = False

Flag to signal that this widget is triggering the update and is writing to the model

_rq_reading = False

Flag to indicate that the model changed and the widget is reading the model

_value_changed(text: str)None

Slot triggered when the user changes text of the LineEdit.

Propagates changes to the model