From a3b38fc6b7e1a7934bf28042aeb28af5dbd6daad Mon Sep 17 00:00:00 2001 From: linuswck Date: Fri, 18 Oct 2024 13:26:18 +0800 Subject: [PATCH] gui: Unify the param tree unit formatting style --- pykirdy/kirdy_qt.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pykirdy/kirdy_qt.py b/pykirdy/kirdy_qt.py index 92272a8..59435e0 100644 --- a/pykirdy/kirdy_qt.py +++ b/pykirdy/kirdy_qt.py @@ -408,9 +408,9 @@ class MainWindow(QtWidgets.QMainWindow): LASER_DIODE_PARAMETERS = [ {'name': 'Readings', 'expanded': True, 'type': 'group', 'children': [ - {'name': 'LD Current Set', 'type': 'float', 'suffix': 'A', 'siPrefix': True, 'readonly': True, "compactHeight": False}, - {'name': 'PD Current', 'type': 'float', 'suffix': 'A', 'siPrefix': True, 'readonly': True, "compactHeight": False}, - {'name': 'PD Power', 'type': 'float', 'suffix': 'W', 'siPrefix': True, 'readonly': True, "compactHeight": False}, + {'name': 'LD Current Set', 'type': 'float', 'unit': 'mA', 'readonly': True, "compactHeight": False}, + {'name': 'PD Current', 'type': 'float', 'unit': 'uA', 'siPrefix': True, 'readonly': True, "compactHeight": False}, + {'name': 'PD Power', 'type': 'float', 'unit': 'mW', 'readonly': True, "compactHeight": False}, {'name': 'LF Mod Termination (50 Ohm)', 'type': 'list', 'limits': ['On', 'Off'], 'readonly': True, "compactHeight": False} ]}, {'name': 'Output Config', 'expanded': True, 'type': 'group', 'children': [ @@ -438,8 +438,8 @@ class MainWindow(QtWidgets.QMainWindow): THERMOSTAT_PARAMETERS = [ {'name': 'Readings', 'expanded': True, 'type': 'group', 'children': [ - {'name': 'Temperature', 'type': 'float', 'format': '{value:.4f} ℃', 'readonly': True, "compactHeight": False}, - {'name': 'Current through TEC', 'type': 'float', 'suffix': 'A', 'siPrefix': True, 'decimals': 6, 'readonly': True, "compactHeight": False}, + {'name': 'Temperature', 'type': 'float', 'unit': '℃', 'format': '{value:.4f}', 'readonly': True, "compactHeight": False}, + {'name': 'Current through TEC', 'type': 'float', 'unit': 'mA', 'decimals': 6, 'readonly': True, "compactHeight": False}, ]}, {'name': 'Output Config', 'expanded': True, 'type': 'group', 'children': [ {'name': 'Control Method', 'type': 'mutex', 'limits': ['Constant Current', 'Temperature PID'],