5

Is there a way to obtain the size of the buttons/arrows of a Qt QSpinBox?

Note: This question has nothing to do with changing the style of a QSpinBox. On the contrary: The intent is to use the QSpinBox style as given and obtain at runtime the size of its buttons/arrows, which will be different for different platforms, for the purpose of fine tuning the layout constraints in which the QSpinBox is one component.

Also: The QStyle class does not appear to provide PixelMetric values for the button/arrows sizes.

Thnx.

user674263
  • 131
  • 1
  • 4
  • 1
    one brute force approach i can think of is, `spinbox.childAt(x, y)->geometry()`, where (x, y) is the position of the button. – Donotalo Mar 24 '11 at 05:16

0 Answers0