PyQt5 QSpinBox – Setting Style Hint
In this article we will see how we can set the style hint of the spin box text. Style hints are used by the font matching algorithm to find an appropriate default family if a selected font family is not available. There are many styles hints offered by the spin box like AnyStyle, SansSerif, Times etc.
In order to do this we use setStyleHint method with the QFont object of the spin box.
Syntax : font.setStyleHint(style_hint, style_preference)
Argument : It takes style hint as argument and second argument is optional which is the preference
Return : It returns None
Below is the implementation