Skip to content

Commit

Permalink
owpolar: change α value/TDM tilt
Browse files Browse the repository at this point in the history
Added a validator to only allow integers between 0-90 to be entered.
Changed the name from alpha value to TDM tilt to avoid confusion with absorptance
Included a tooltip to clarify the meaning of this value
  • Loading branch information
callumgassner authored and markotoplak committed Nov 20, 2024
1 parent 98563de commit 736a566
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions orangecontrib/spectroscopy/widgets/owpolar.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import pandas as pd
from AnyQt.QtCore import QItemSelectionModel, QItemSelection, QItemSelectionRange
from AnyQt.QtWidgets import QFormLayout, QWidget, QListView, QLabel, QSizePolicy
from AnyQt.QtGui import QIntValidator
from scipy.optimize import curve_fit


Expand Down Expand Up @@ -575,8 +576,10 @@ def __init__(self):
vbox.layout().addWidget(form)

pbox = gui.widgetBox(vbox, sizePolicy=(QSizePolicy.Minimum, QSizePolicy.Fixed))
gui.lineEdit(pbox, self, "alpha", "Alpha value",
callback=self._change_input, valueType=int)
gui.lineEdit(pbox, self, "alpha", u"TDM Tilt (\N{DEGREE SIGN})",
callback=self._change_input, valueType=int,
validator=QIntValidator(0, 90), tooltip= \
"The angle (in degrees) between the long axis of the molecule and the transition dipole moment")

gui.checkBox(pbox, self, 'invert_angles', label="Invert Angles",
callback=self._change_input)
Expand Down

0 comments on commit 736a566

Please sign in to comment.