Example #1
0
    def _init_ui(self):
        # Widgets
        self._btn_atomic_number = AtomicNumberAttributePushButton(self.CLASS.atomic_number)

        # Layouts
        layout = _ConditionWidget._init_ui(self)
        layout.addRow('<i>Element</i>', self._btn_atomic_number)

        # Signals
        self._btn_atomic_number.selectionChanged.connect(self.edited)

        return layout
Example #2
0
    def _init_ui(self):
        # Controls
        self._cb_interpolation = QComboBox()
        self._cb_interpolation.addItems([None] + list(_BACKGROUND_INTERPOLATIONS))

        # Layouts
        layout = _ConditionWidget._init_ui(self)
        layout.addRow("<i>Interpolation</i>", self._cb_interpolation)

        # Signals
        self._cb_interpolation.currentIndexChanged.connect(self.edited)

        return layout
Example #3
0
    def _init_ui(self):
        # Widgets
        self._cb_unit = QComboBox()
        self._cb_unit.addItems(list(_COMPOSITION_UNITS))

        # Layouts
        layout = _ConditionWidget._init_ui(self)
        layout.addRow('<i>Unit</i>', self._cb_unit)

        # Signals
        self._cb_unit.currentIndexChanged.connect(self.edited)

        return layout
Example #4
0
    def _init_ui(self):
        # Widgets
        self._txt_quantity = TextAttributeLineEdit(self.CLASS.quantity)
        self._txt_unit = UnitAttributeLineEdit(self.CLASS.unit)

        # Layouts
        layout = _ConditionWidget._init_ui(self)
        layout.addRow('<i>Quantity</i>', self._txt_quantity)
        layout.addRow('<i>Unit</i>', self._txt_unit)

        # Signals
        self._txt_quantity.textEdited.connect(self.edited)
        self._txt_unit.textEdited.connect(self.edited)

        return layout
Example #5
0
    def _init_ui(self):
        # Widgets
        self._cb_signal_type = QComboBox()
        self._cb_signal_type.addItems([None] + list(_SIGNAL_TYPES))
        self._txt_manufacturer = TextAttributeLineEdit(self.CLASS.manufacturer)
        self._txt_model = TextAttributeLineEdit(self.CLASS.model)
        self._txt_serial_number = TextAttributeLineEdit(self.CLASS.serial_number)
        self._txt_measurement_unit = UnitAttributeLineEdit(self.CLASS.measurement_unit)
        self._txt_elevation = NumericalAttributeLineEdit(self.CLASS.elevation)
        self._txt_azimuth = NumericalAttributeLineEdit(self.CLASS.azimuth)
        self._txt_distance = NumericalAttributeLineEdit(self.CLASS.distance)
        self._txt_area = NumericalAttributeLineEdit(self.CLASS.area)
        self._txt_solid_angle = NumericalAttributeLineEdit(self.CLASS.solid_angle)
        self._txt_semi_angle = NumericalAttributeLineEdit(self.CLASS.semi_angle)
        self._txt_temperature = NumericalAttributeLineEdit(self.CLASS.temperature)

        # Layout
        layout = _ConditionWidget._init_ui(self)
        layout.addRow('Type of signal', self._cb_signal_type)
        layout.addRow('Manufacturer', self._txt_manufacturer)
        layout.addRow('Model', self._txt_model)
        layout.addRow('Serial number', self._txt_serial_number)
        layout.addRow('Measurement unit', self._txt_measurement_unit)
        layout.addRow('Elevation', self._txt_elevation)
        layout.addRow('Azimuth', self._txt_azimuth)
        layout.addRow('Distance', self._txt_distance)
        layout.addRow('Area', self._txt_area)
        layout.addRow('Solid angle', self._txt_solid_angle)
        layout.addRow('Semi angle', self._txt_semi_angle)
        layout.addRow('Temperature', self._txt_temperature)

        # Signals
        self._cb_signal_type.currentIndexChanged.connect(self.edited)
        self._txt_manufacturer.textEdited.connect(self.edited)
        self._txt_model.textEdited.connect(self.edited)
        self._txt_serial_number.textEdited.connect(self.edited)
        self._txt_measurement_unit.textEdited.connect(self.edited)
        self._txt_elevation.textEdited.connect(self.edited)
        self._txt_azimuth.textEdited.connect(self.edited)
        self._txt_distance.textEdited.connect(self.edited)
        self._txt_area.textEdited.connect(self.edited)
        self._txt_solid_angle.textEdited.connect(self.edited)
        self._txt_semi_angle.textEdited.connect(self.edited)
        self._txt_temperature.textEdited.connect(self.edited)

        return layout
Example #6
0
    def _init_ui(self):
        # Widgets
        self._txt_dwell_time = NumericalAttributeLineEdit(self.CLASS.dwell_time)
        self._txt_total_time = NumericalAttributeLineEdit(self.CLASS.total_time)
        self._txt_dwell_time_live = NumericalAttributeLineEdit(self.CLASS.dwell_time_live)

        # Layouts
        layout = _ConditionWidget._init_ui(self)
        layout.addRow('Dwell time', self._txt_dwell_time)
        layout.addRow('Total time', self._txt_total_time)
        layout.addRow('Dwell time (live)', self._txt_dwell_time_live)

        # Signals
        self._txt_dwell_time.textEdited.connect(self.edited)
        self._txt_total_time.textEdited.connect(self.edited)
        self._txt_dwell_time_live.textEdited.connect(self.edited)

        return layout
Example #7
0
    def _init_ui(self):
        print("TEST HUHU")
        # Controls
        self._cb_type = QComboBox()
        self._cb_type.addItems([None] + list(_INTENSITY_TYPES))
        self._cb_measure = QComboBox()
        self._cb_measure.addItems([None] + list(_INTENSITY_MEASURES))

        # Layouts
        layout = _ConditionWidget._init_ui(self)
        layout.addRow("<i>Type</i>", self._cb_type)
        layout.addRow("<i>Measure</i>", self._cb_measure)

        # Signals
        self._cb_type.currentIndexChanged.connect(self.edited)
        self._cb_measure.currentIndexChanged.connect(self.edited)

        return layout
Example #8
0
    def _init_ui(self):
        # Controls
        self._txt_manufacturer = TextAttributeLineEdit(self.CLASS.manufacturer)
        self._txt_model = TextAttributeLineEdit(self.CLASS.model)
        self._txt_serial_number = TextAttributeLineEdit(self.CLASS.serial_number)

        # Layouts
        layout = _ConditionWidget._init_ui(self)
        layout.addRow("<i>Manufacturer</i>", self._txt_manufacturer)
        layout.addRow("<i>Model</i>", self._txt_model)
        layout.addRow("Serial number", self._txt_serial_number)

        # Signals
        self._txt_manufacturer.textEdited.connect(self.edited)
        self._txt_model.textEdited.connect(self.edited)
        self._txt_serial_number.textEdited.connect(self.edited)

        return layout
Example #9
0
    def _init_ui(self):
        # Widgets
        self._txt_x = NumericalAttributeLineEdit(self._class.x)
        self._txt_y = NumericalAttributeLineEdit(self._class.y)
        self._txt_z = NumericalAttributeLineEdit(self._class.z)
        self._txt_r = NumericalAttributeLineEdit(self._class.r)
        self._txt_t = NumericalAttributeLineEdit(self._class.t)

        # Layouts
        if self._inline:
            layout = QVBoxLayout()

            layout_xyz = QHBoxLayout()
            layout_xyz.addWidget(QLabel('X'))
            layout_xyz.addWidget(self._txt_x)
            layout_xyz.addWidget(QLabel('Y'))
            layout_xyz.addWidget(self._txt_y)
            layout_xyz.addWidget(QLabel('Z'))
            layout_xyz.addWidget(self._txt_z)

            layout_rt = QHBoxLayout()
            layout_rt.addWidget(QLabel('R'))
            layout_rt.addWidget(self._txt_r)
            layout_rt.addWidget(QLabel('T'))
            layout_rt.addWidget(self._txt_t)

            layout.addLayout(layout_xyz)
            layout.addLayout(layout_rt)
        else:
            layout = _ConditionWidget._init_ui(self)
            layout.addRow('X', self._txt_x)
            layout.addRow('Y', self._txt_y)
            layout.addRow('Z', self._txt_z)
            layout.addRow('R', self._txt_r)
            layout.addRow('T', self._txt_t)

        # Signals
        self._txt_x.textEdited.connect(self.edited)
        self._txt_y.textEdited.connect(self.edited)
        self._txt_z.textEdited.connect(self.edited)
        self._txt_r.textEdited.connect(self.edited)
        self._txt_t.textEdited.connect(self.edited)

        return layout
Example #10
0
    def _init_ui(self):
        # Widgets
        validator = QIntValidator()
        validator.setBottom(0)

        self._txt_start_channel = QLineEdit()
        self._txt_start_channel.setValidator(validator)
        self._txt_start_channel.setAccessibleName('Start channel')

        self._txt_end_channel = QLineEdit()
        self._txt_end_channel.setValidator(validator)
        self._txt_end_channel.setAccessibleName("End channel")

        # Layouts
        layout = _ConditionWidget._init_ui(self)
        layout.addRow('<i>Start channel</i>', self._txt_start_channel)
        layout.addRow('<i>End channel</i>', self._txt_end_channel)

        # Signals
        self._txt_start_channel.textEdited.connect(self.edited)
        self._txt_end_channel.textEdited.connect(self.edited)

        return layout