Changing the size of UIStepper

user523234 picture user523234 · Aug 29, 2012 · Viewed 8.1k times · Source

I can't seem to change the size of UIStepper:

  1. In IB, the Width and Height boxes are grayed out.
  2. I used initWithFrame:

    UIStepper *stepper = [[UIStepper alloc] initWithFrame:CGRectMake(300, 638, 120, 80)];

    But it does not change the size. Several posts on SO seemed to implied it is changeable. Any suggestion?

Answer

gdm picture gdm · Oct 9, 2013
UIStepper* s = [UIStepper alloc] init];  
s.transform = CGAffineTransformMakeScale(0.75, 0.75);