89 self.logLevelComboBox.addItem(mqttLogLevelString( |
89 self.logLevelComboBox.addItem(mqttLogLevelString( |
90 logLevel, isMqttLogLevel=False), logLevel) |
90 logLevel, isMqttLogLevel=False), logLevel) |
91 self.logLevelComboBox.setCurrentIndex( |
91 self.logLevelComboBox.setCurrentIndex( |
92 self.logLevelComboBox.count() - 1) |
92 self.logLevelComboBox.count() - 1) |
93 |
93 |
94 # TODO: Log Edit improvements: |
|
95 # 1. add capability to search |
|
96 |
|
97 self.__logMessagesBackgrounds = { |
94 self.__logMessagesBackgrounds = { |
98 MqttClient.LogDebug: QBrush(Qt.white), |
95 MqttClient.LogDebug: QBrush(Qt.white), |
99 MqttClient.LogInfo: QBrush(Qt.lightGray), |
96 MqttClient.LogInfo: QBrush(Qt.lightGray), |
100 MqttClient.LogNotice: QBrush(Qt.green), |
97 MqttClient.LogNotice: QBrush(Qt.green), |
101 MqttClient.LogWarning: QBrush(Qt.yellow), |
98 MqttClient.LogWarning: QBrush(Qt.yellow), |
102 MqttClient.LogError: QBrush(Qt.red), |
99 MqttClient.LogError: QBrush(Qt.red), |
103 MqttClient.LogDisabled: QBrush(Qt.magenta) |
100 MqttClient.LogDisabled: QBrush(Qt.magenta) |
104 # reuse LogDisabled for unknown log levels |
101 # reuse LogDisabled for unknown log levels |
105 } |
102 } |
|
103 |
|
104 self.logSearchWidget.attachTextEdit(self.logEdit) |
|
105 try: |
|
106 self.logSearchWidget.setWidthForHeight(False) |
|
107 except AttributeError: |
|
108 # eric < 18.10 |
|
109 pass |
106 |
110 |
107 self.brokerWidget.setCurrentIndex(0) |
111 self.brokerWidget.setCurrentIndex(0) |
108 |
112 |
109 self.__connectionModeProfile = True |
113 self.__connectionModeProfile = True |
110 self.__setConnectionMode(True) # initial mode is 'profile connection' |
114 self.__setConnectionMode(True) # initial mode is 'profile connection' |