• 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 size, how to change ?!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSSplitView size, how to change ?!


  • Subject: Re: NSSplitView size, how to change ?!
  • From: Greg Titus <email@hidden>
  • Date: Mon, 21 Jan 2002 16:24:01 -0800

On Monday, January 21, 2002, at 03:58 PM, Vince DeMarco wrote:

On Monday, January 21, 2002, at 01:40 PM, Gore wrote:

hmmm, I tryed that with one view in the splitview, and it didn't work, I tryed to call setFrame: to one of the splitview views (2 views) but nothing happend, did I do something wrong ?!


I just check out some internal code (which i can't send to you sorry) that figures out the percentage that each view occupies (stores this in the defaults) then on app startup, uses this value to reset the frame of each of the views in the splitview and then tells the splitview to redraw itself. ([splitview setNeedsDisplay:])

mail does this and it works find.

Try doing both views.


Yep. Both views need changing to get it to work. If you want code, you can look at NSSplitView-OAExtensions in OmniAppKit, which adds:

@interface NSSplitView (OAExtensions)
- (float)fraction;
- (void)setFraction:(float)newFract;
- (int)topPixels;
- (void)setTopPixels:(int)newTop;
- (int)bottomPixels;
- (void)setBottomPixels:(int)newBottom;
@end

--Greg


References: 
 >Re: NSSplitView size, how to change ?! (From: Vince DeMarco <email@hidden>)

  • Prev by Date: Re: NSGlyph is still a puzzle
  • Next by Date: Re: Calling BSD from Cocoa and/or CFM?
  • Previous by thread: Re: NSSplitView size, how to change ?!
  • Next by thread: NSWorkspace notification problems
  • Index(es):
    • Date
    • Thread