I am having two UIButton
in my setting page, one button is to increase the font size of the text and other is to decrease the font size of the text. But all I have to need is when the user tap the UIButton
for increasing font size, it need to incise 18pt, then the user again tap or one more time in the same button it need to set the font size to 24pt, then again taping the same button result in in cement of font size to 32pt. I need to limit or there tap counts. Vise versa the same effect in decreasing font size button.
-(IBAction)_clickfontsizeincrease:(id)sender
{
self.multiPageView.font = [UIFont systemFontOfSize:30.0f];
}
-(IBAction)_clickfontsizedecrease:(id)sender
{
self.multiPageView.font = [UIFont systemFontOfSize:10.0f];
}
How to do this? Thanks in advance.
static int tapCount = 0;
- (IBAction) buttonTapped :(id)sender {
tapCount++;
// Based upon tapCount condition you can do whatever you want.
}