GUI: status bar update from Takashi recommendations

This commit is contained in:
2025-09-19 16:10:40 +02:00
parent 7e02c537eb
commit 14cd289b55
+6 -6
View File
@@ -84,9 +84,9 @@ class StatusBar(QStatusBar):
self.cryo_label.set_value(f"{status.bl.cryojet_K:.1f}", "red")
if status.bl.shutter_open:
self.shutter_label.setText(f"""Shutter: <span style="color: green ; "> Open </span>""")
self.shutter_label.setText(f"""Shutter: <span style="color: red ; "> Open ☢️ </span>""")
else:
self.shutter_label.setText(f"""Shutter: <span style="color: red ; "> Closed </span>""")
self.shutter_label.setText(f"""Shutter: <span style="color: green ; "> Closed 🚪 </span>""")
if status.session.current_pgroup is not None:
self.pgroup_label.setText(f"""p-group: {status.session.current_pgroup} """)
@@ -116,9 +116,9 @@ class StatusBar(QStatusBar):
self.state_label.setText(f"""State: {state} """)
if status.busy:
busy_flag = """ <span style="color: red; "> Busy </span>"""
busy_flag = """ <span style="color: red; "> Busy 🔒 </span>"""
else:
busy_flag = """ <span style="color: green ; "> Idle </span>"""
busy_flag = """ <span style="color: green ; "> Idle 🔓 </span>"""
html_content = f"""Beamline: {busy_flag} """
@@ -126,11 +126,11 @@ class StatusBar(QStatusBar):
session_flag = ""
if status.session.session == SessionsStateEnum.Vacant:
session_flag = """<span style="color: yellow ; "> Vacant </span>"""
session_flag = """<span style="color: yellow ; "> Vacant 🔓 </span>"""
elif status.session.session == SessionsStateEnum.OwnedByYou:
session_flag = """<span style="color: green ; "> Owned ⬤ </span>"""
elif status.session.session == SessionsStateEnum.OwnedByElse:
session_flag = """<span style="color: red ; "> Other </span>"""
session_flag = """<span style="color: red ; "> Other 🔒 </span>"""
html_content_session = f"""Session: {session_flag}"""
self.session_label.setText(html_content_session)