NSTextView, NSTabView - Frame/Scroll issues?
NSTextView, NSTabView - Frame/Scroll issues?
- Subject: NSTextView, NSTabView - Frame/Scroll issues?
- From: Brian Amerige <email@hidden>
- Date: Thu, 4 Jan 2007 17:31:58 -0500
- Resent-date: Fri, 5 Jan 2007 16:30:45 -0500
- Resent-from: Brian Amerige <email@hidden>
- Resent-message-id: <email@hidden>
- Resent-to: email@hidden
Hey all,
Ive got an NSTabView (PSMTabBarControl and the like) with
NSTabViewItems being generated by code. Their View, an NSTextView, is
also generated by code as such:
NSTextView *newTextView = [[[NSTextView alloc] init] autorelease];
[newTextView setEditable:YES];
[[newTextView textStorage] setDelegate:self];
//Open a new window
NSTabViewItem *newTabViewItem = [[[NSTabViewItem alloc] init]
autorelease];
[newTabViewItem setView:newTextView];
[oTabView addTabViewItem:newTabViewItem];
I've tried adjusting the frame ([newTextView setFrame:[oTabView
contentRect]];) of the NSTextView, (both before and after i called
addTabViewItem:), but it doesn't seem to respond to it nicely.
It doesn't fill the height of the window (even thought the springs in
IB are accurately set for the NSTabView), but rather it fills the
height to match the size of the document (eg. a 5 line text file is
only a 5 line textview). In the event that the document is taller
(height wise) than the window, it doesn't add a scrollbar, either.
Any comments are welcome!
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden