Creating a single Tab Stop in an NSTextView
Creating a single Tab Stop in an NSTextView
- Subject: Creating a single Tab Stop in an NSTextView
- From: Ian was here <email@hidden>
- Date: Tue, 17 Jan 2006 08:46:04 -0800 (PST)
I'm trying to reset the position of the first tab stop
within my text view. I would like it to be at position
48. For some reason the following code doesn't seem to
do the trick. Has anyone else done something similar
to this?
NSMutableParagraphStyle *theParagraphStyle =
[[NSMutableParagraphStyle alloc] init];
NSTextTab *textTab = [[NSTextTab alloc]
initWithType:NSLeftTabStopType location:48.0];
NSArray *tabStop = [[NSArray alloc]
initWithObjects:textTab, nil];
[theParagraphStyle setTabStops:tabStop];
[textView setDefaultParagraphStyle:theParagraphStyle];
[tabStop release];
[textTab release];
[theParagraphStyle release];
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden