Steve Lai
Steve Lai

Reputation: 637

stepper work only pressed by twice?

I an using a stepper to control the font size of a text view, but there is no action being fired until I press the stepper twice. Why is this happening?

The following code is for the `mystepper' IBAction:

- (IBAction) changeFontSize:(id)sender
{
    [myStepper setMinimumValue:14.0]
    self.myStepper.maximumValue =20.0;

    CGFloat newSize = [myTextView fontWithSize:self.stepper.value];
    self.myTextView.font = newSize;
}

Upvotes: 1

Views: 134

Answers (1)

Nazik
Nazik

Reputation: 8444

Check whether u had connected the UIStepper Recieved Actions to the changeFontSize: function for Values Changed not for Touches inside

Upvotes: 1

Related Questions