user891268
user891268

Reputation: 1425

how to set color of text in selected TextView

How to set color of text in selected TextView.

i try it not able to figure it out.

Is it possible to change UITextView`s color in particular range ?

Please help me out.

enter image description here

Upvotes: 0

Views: 418

Answers (1)

jtbandes
jtbandes

Reputation: 118681

Does this work for you?

NSString *selection = [textView.text substringWithRange:textView.selectedRange];

Upvotes: 1

Related Questions