ProtectTaurusMessageBox
- class ProtectTaurusMessageBox(title=None, msg=None)[source]
The idea of this class is to be used as a decorator on any method you which to protect against exceptions. The handle of the exception is to display a
TaurusMessageBox
with the exception information. The optional parameter title gives the window bar a customized title. The optional parameter msg allows you to give a customized message in the dialog. Example:@ProtectTaurusMessgeBox(title="Error trying to turn the beam on") def turnBeamOn(device_name): d = taurus.Device(device_name) d.TurnOn()
Import from
taurus.qt.qtgui.dialog
as:from taurus.qt.qtgui.dialog import ProtectTaurusMessageBox