From 276a1784efc0a4d0b94eb563322cf925bc5a00a6 Mon Sep 17 00:00:00 2001 From: Sebastien Bourdeauducq Date: Tue, 9 Jun 2015 20:05:39 +0800 Subject: [PATCH] gui: add TTL override label --- artiq/gui/moninj.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/artiq/gui/moninj.py b/artiq/gui/moninj.py index f5c18903c..97ced770c 100644 --- a/artiq/gui/moninj.py +++ b/artiq/gui/moninj.py @@ -41,9 +41,12 @@ class _TTLWidget(QtGui.QFrame): self._direction = QtGui.QLabel() self._direction.setAlignment(QtCore.Qt.AlignCenter) grid.addWidget(self._direction, 2, 1) + self._override = QtGui.QLabel() + self._override.setAlignment(QtCore.Qt.AlignCenter) + grid.addWidget(self._override, 3, 1) self._value = QtGui.QLabel() self._value.setAlignment(QtCore.Qt.AlignCenter) - grid.addWidget(self._value, 3, 1, 6, 1) + grid.addWidget(self._value, 4, 1, 6, 1) self._value.setContextMenuPolicy(QtCore.Qt.ActionsContextMenu) menu = QtGui.QActionGroup(self._value) @@ -83,8 +86,10 @@ class _TTLWidget(QtGui.QFrame): if override: value_s = "" + value_s + "" color = " color=\"red\"" + self._override.setText("OVERRIDE") else: color = "" + self._override.setText("") self._value.setText("{}".format( color, value_s)) oe = oe or self.force_out