• 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: NSSplitView question - how to implement my own "adjustViews" style method
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSSplitView question - how to implement my own "adjustViews" style method


  • Subject: Re: NSSplitView question - how to implement my own "adjustViews" style method
  • From: Motti Shneor <email@hidden>
  • Date: Tue, 03 Jul 2012 07:46:05 +0300

Thanks Graham (Sigh…)

I was beginning to think I'm stupid or something, struggling so hard with a UI element as ordinary as a Split-View.

I have the feeling I "almost got it", and I even think I understand why and when delegate methods are being called.  Rolling out my own SplitView doesn't seem to be easier than finding the answer to my question, because to inherit from NSSplitView I'd still need to understand how "super" works won't I?.
Also I'll have to re-implement lots of behavior (animation, dynamics, efficient drawing etc.) that might prove a big job.

I could re-state my question again even simpler --- I want to know what makes NSSplitView respond with "YES" to the following:

[mySplitView isSubviewCollapsed:panelSubview];

Is it just the subview being hidden? being zero-framed? being vertically/horizontally transformed to zero? Does the NSSplitView maintain a "collapsed" state member for each of its subviews? How can I set this state?

and if anyone from Apple is on this list --- for god sake, why isn't there a [mySplitView setSubview:panelSubview collapsedStateTo:YES/NO] ????

--Motti

On 3 ביול 2012, at 03:14, Graham Cox wrote:

> On 03/07/2012, at 12:21 AM, Motti Shneor wrote:
>
>> I really need an advice here.
>
> This will sound flippant but it's not meant to be: implement your own split view.
>
> NSSplitView is the most bizarre piece of design and difficult to get to behave just how you want even in simple cases like having two views, one which should stay fixed when the overall view is resized. This behaviour is likely to be the most commonly needed but is not the default for NSSplitView. The delegate methods are weird and don't get called in every case. Once you add in the complexity of dynamic views, your head is going to be spinning.
>
> Rolling your own is not that hard, and can be designed with your use-case in mind.
>
> --Graham


_______________________________________________

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: NSSplitView question - how to implement my own "adjustViews" style method
      • From: Graham Cox <email@hidden>
    • Re: NSSplitView question - how to implement my own "adjustViews" style method
      • From: Quincey Morris <email@hidden>
    • Re: NSSplitView question - how to implement my own "adjustViews" style method
      • From: Todd Heberlein <email@hidden>
References: 
 >NSSplitView question - how to implement my own "adjustViews" style method (From: Motti Shneor <email@hidden>)
 >Re: NSSplitView question - how to implement my own "adjustViews" style method (From: Graham Cox <email@hidden>)

  • Prev by Date: Re: Allow FileUpload in iOS 4 or 5
  • Next by Date: Re: NSSplitView question - how to implement my own "adjustViews" style method
  • Previous by thread: Re: NSSplitView question - how to implement my own "adjustViews" style method
  • Next by thread: Re: NSSplitView question - how to implement my own "adjustViews" style method
  • Index(es):
    • Date
    • Thread