Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

rethish

macrumors member
Original poster
Oct 16, 2008
41
0
hi all,

In my application I use an instance of NSTextView. The text content in the textview can be formatted -(text formatting ; eg changecase, changecolor, changefont ,fontsize , etc.. )- at the whole.

but i need to format only the portion of text that i use to select.

Is this possible ?

I tried a lot , please help ...


thankyou.
 

kainjow

Moderator emeritus
Jun 15, 2000
7,958
7
Get its textStorage object, which is a subclass of NSMutableAttributedString, which has methods for setting attributes for a specific range.
 

rethish

macrumors member
Original poster
Oct 16, 2008
41
0
thank you ,

I also found that it can be done using NSRange and setfont: range: method.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.