• 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: NSBrowser background color
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSBrowser background color


  • Subject: Re: NSBrowser background color
  • From: "Cathy Shive" <email@hidden>
  • Date: Wed, 12 Sep 2007 17:03:46 -0400

Thanks Andy!  This is a very useful trick!

Check out Murat's example, too.  Amazing what it took to set the
background color.  hahah.  :)

Cathy

On 9/12/07, Andy Lee <email@hidden> wrote:
> On Sep 12, 2007, at 4:11 PM, Cathy Shive wrote:
> > HI Andy,
> >
> > Yes, I tried to mess with the delegate method to get to the matrix
> > objects but it didn't do anything.  From what I can understand, the
> > matrix is sized according the content it's displaying - in my case
> > nothing - so it has no height yet.
>
> Hm.  Well, for what it's worth, here's the internal view hierarchy of
> an NSBrowser.  The closest-looking thing to an NSScrollView is a
> private class called _NSBrowserScrollView.  Maybe you can do
> something with the NSClipView.
>
>
> 2007-09-12 16:45:36.847 Scratch[9322]   NSBrowser
> 2007-09-12 16:45:36.847 Scratch[9322]     _NSBrowserScrollView
> 2007-09-12 16:45:36.847 Scratch[9322]       NSClipView
> 2007-09-12 16:45:36.847 Scratch[9322]
> _NSBrowserColumnsContainerView
> 2007-09-12 16:45:36.847 Scratch[9322]           _NSBrowserColumnView
> 2007-09-12 16:45:36.847 Scratch[9322]             NSClipView
> 2007-09-12 16:45:36.847 Scratch[9322]               NSMatrix
> 2007-09-12 16:45:36.847 Scratch[9322]             NSScroller
> 2007-09-12 16:45:36.847 Scratch[9322]       NSScroller
> 2007-09-12 16:45:36.847 Scratch[9322]     NSClipView
> 2007-09-12 16:45:36.847 Scratch[9322]
> _NSBrowserTitlesContainerView
>
>
> I printed this with a quick-and-dirty method I wrote just now:
>
>
> + (void)printViewHierarchy:(NSView *)view withIndent:(NSString *)indent
> {
>         NSLog(@"%@%@", indent, [view className]);
>
>         NSArray *subviews = [view subviews];
>         int i;
>         for (i = 0; i < [subviews count]; i++) {
>                 [self printViewHierarchy:[subviews objectAtIndex:i]
>                         withIndent:[indent stringByAppendingString:@"  "]];
>         }
> }
>
> + (void)printViewHierarchy:(NSView *)view
> {
>         [self printViewHierarchy:view withIndent:@"  "];
> }
>
>
_______________________________________________

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

References: 
 >NSBrowser background color (From: "Cathy Shive" <email@hidden>)
 >Re: NSBrowser background color (From: Scott Thompson <email@hidden>)
 >Re: NSBrowser background color (From: "Cathy Shive" <email@hidden>)
 >Re: NSBrowser background color (From: "Cathy Shive" <email@hidden>)
 >Re: NSBrowser background color (From: Andy Lee <email@hidden>)
 >Re: NSBrowser background color (From: "Cathy Shive" <email@hidden>)
 >Re: NSBrowser background color (From: Andy Lee <email@hidden>)

  • Prev by Date: resetting ivars safely
  • Next by Date: Re: warning: type `string' has a user-defined constructor
  • Previous by thread: Re: NSBrowser background color
  • Next by thread: Re: NSBrowser background color
  • Index(es):
    • Date
    • Thread