Size of a wxSpinCtrl
Posted: Fri Nov 21, 2014 8:46 pm
How can I set the text width of a wxSpinCtrl ?
The control I want is only supposed to allow a single digit (the min value is 0 and the max is 9), but the control default to a width that would hold like a 15-digit number.
Is there some way to specify the "text width"?
I tried using GetSizeFromTextSize() and using that result to set the Control's size, but that didn't seem to work.
I'd like the width of the text box to "match" the length of the maximum value.
I wouldn't think it would matter, but I am using wxWidgets 3.0.0 on Win7-64.
Thanks.
The control I want is only supposed to allow a single digit (the min value is 0 and the max is 9), but the control default to a width that would hold like a 15-digit number.
Is there some way to specify the "text width"?
I tried using GetSizeFromTextSize() and using that result to set the Control's size, but that didn't seem to work.
I'd like the width of the text box to "match" the length of the maximum value.
I wouldn't think it would matter, but I am using wxWidgets 3.0.0 on Win7-64.
Thanks.