• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSTextView Custom Class "Not Applicable"
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTextView Custom Class "Not Applicable"


  • Subject: Re: NSTextView Custom Class "Not Applicable"
  • From: Peter Horn <email@hidden>
  • Date: Mon, 15 Apr 2002 19:44:28 +0200

Hi!

I wrote a NSTextView subclass, Interface Builder knows about it, but in the
"Custom Class" pane of the info window of the NSTextView I only can see the
text "Not Applicable".

I had this problem, too. The problem is, that you have an NSTextView inside an NSClipView inside an NSScrollView. So what you need to do, is:

// get the right size
NSSize contSize = [scrollView contentSize];
// init new view with correct size
customView = [[XXCustomView alloc] initWithFrame:NSMakeRect(0.0, 0.0, contSize.width,
contSize.height)];
// correctly set the resizing
[customView setAutoresizingMask:NSViewWidthSizable | NSViewHeightSizable];
// insert the newly created view into the scrollView
[scrollView setDocumentView:customView];

Regards,
Peter
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >NSTextView Custom Class "Not Applicable" (From: Manfred Lippert <email@hidden>)

  • Prev by Date: Re: NSTextView Custom Class "Not Applicable"
  • Next by Date: How do I use C++ code or lib in Cocoa?
  • Previous by thread: Re: NSTextView Custom Class "Not Applicable"
  • Next by thread: How do I use C++ code or lib in Cocoa?
  • Index(es):
    • Date
    • Thread