Merge pull request #9 from kumitterer/main

Fix duration display in edit form
This commit is contained in:
Julia P 2024-04-03 20:20:11 +02:00 committed by GitHub
commit ae32a95205
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -383,7 +383,7 @@ class EventOptionsWidget(QWidget):
duration_label = QLabel("Duration:")
duration_lineedit = QLineEdit()
unit_label = QLabel("µs")
duration_lineedit.setText(str(self.event.duration * Decimal(1e6)))
duration_lineedit.setText("%.16g" % (self.event.duration * Decimal(1e6)))
duration_layout.addWidget(duration_label)
duration_layout.addWidget(duration_lineedit)
duration_layout.addWidget(unit_label)