I am currently creating an application with Qt and have found a class named
QIntValidator whichs allows to check whether the contents of a
QLineEdit is actually an integer or not. This class allows to check on the fly whether the entered contents are correct and to signal the user if they entered a string which does not represent an integer.
While the contents validation is interesting by itself, from a user experience point of view, why would I specifically want to use a one-line text editor to enter integral values when I could simply use an integer spinbox that, when correctly configured, prevents the user from even entering characters that would make the represented integer ill-formed? I have found many forms that used one-line text editors to enter integer values, but I still can't understand why they would use them instead of spinboxes.
Moreover, if one doesn't like the spinbox buttons, many GUI systems even allow to hide them.