Question

I need to change the font style from bold to italic,by using two buttons.for ex, i am entering the text "this is my iphone application ", after the string "this is"i would like to change the text from bold to italic ( by clicking italic button ) while the previous one remains same.This should apply every time for the button click actions,here is my code

-(IBAction)BoldClicked{
    textView.font = [UIFont boldSystemFontOfSize:18.0];
}
-(IBAction)ItalicClicked{
 textView.font = [UIFont italicSystemFontOfSize:18.0];
}

But the total text is changing..Should I use web view for this?

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top