• 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
How to create source-list programmatically?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to create source-list programmatically?


  • Subject: How to create source-list programmatically?
  • From: Hoon Hwangbo <email@hidden>
  • Date: Sat, 19 Oct 2013 05:48:50 +0900

Hello.

Today, I spend a whole day to configure source-list.
It is typical job, but it work too hard for me because I wanted to avoid Interface Builder.

I configured NSOutlineView and subclassed NSTableCellView and assigned my own NSImageView and NSTextField
to the properties. I expected to will work like UITableView on iOS, but it never worked.

After all my trial failed, I discovered SidebarDemo(https://developer.apple.com/library/mac/samplecode/SidebarDemo/Listings/SidebarDemoAppDelegate_m.html) sample.
And I realized that just using image-view and text-field supplied by IB will clear all the problems.

I think IB is configuring something special classes, and those classes are don't seem to be accessible from plain Objective-C code.
Because, when I configured the text-field and image-view myself, NSOutlineView doesn't even try to layout it.

So should I always use the IB to make source-list correctly? Is there no *purely programatic* - with only code - way to do that?


_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden


  • Follow-Ups:
    • Re: How to create source-list programmatically?
      • From: Ken Thomases <email@hidden>
  • Prev by Date: Re: Deadlock during NSCache flush
  • Next by Date: Re: Is 10.9 ready for production development?
  • Previous by thread: Re: Is 10.9 ready for production development?
  • Next by thread: Re: How to create source-list programmatically?
  • Index(es):
    • Date
    • Thread