Source code for devctrl.utility

"""Various utility modules: file io, logging, settings and more."""
from PyQt6.QtCore import QObject

from .._configure import gui, _set_configured

if gui():
    from PyQt6.QtCore import pyqtSignal as Signal
    from PyQt6.QtCore import QObject as SignalParent
else:
    from .signal import Signal
[docs] class SignalParent: pass
[docs] def handle_events() -> None: """Handle queued events of the signal implementation. With QT signals, delivery is handled by the QT event loop and this is a no-op. With the pure-python fallback (:mod:`devctrl.utility.signal`), this dispatches all events queued by :meth:`Signal.emit`. """ if not gui(): Signal.handle_events()
# from . import messaging _set_configured()