I'm trying to subclass QToolButton
to elide its text. To tell how much room is left for text, I have to take button width (available) and subtract from it:
icon size (available),
size of the button frame with shadows and other cute effects (can't find it),
padding (can't find it either).
Obviously these things are style-dependent and there must be API calls to retrieve them, but QStyle
does not seem to offer anything relevant. Any suggestions?