On Apr 20, 2012, at 9:19 AM, koko wrote: > Here is the code that creates and adds the subview ....The method > -makeAndWrapViews is in the custom class of the NSTabViewItem view. > > I do get -viewDidMoveToSuperview when addSubview is called. > > When the tab is clicked I do get viewdidMoveToWindow > > But I never see thev iew! > > - (void)makeAndWrapViews > { > NSRect frame = [self frame];
Who is "self" here? Is it the tab view item view? If so, does the tab view item know that you are using a custom subclass? Lastly, what is the origin point (to make sure it isn't being placed outside the viewable area)? > frame.size.width = 288; > frame.size.height = 259; > > m_text = [[NSPDText alloc] initWithFrame:frame]; > > BOOL text = [NSBundle loadNibNamed:@"NSPDText" owner:m_text]; > > if (text) > { > [self addSubview:m_text]; > } > } Does this code work when you substitute NSPDText with a canned cocoa UI object? Keary Suska Esoteritech, Inc. "Demystifying technology for your home or business" _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com