• 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
NSScrollView bug : can someone confirm ?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSScrollView bug : can someone confirm ?


  • Subject: NSScrollView bug : can someone confirm ?
  • From: Eric Morand <email@hidden>
  • Date: Thu, 26 Oct 2006 14:23:07 +0200

Hi !

I'm facing a very strange behavior with an NSScrollView instance (not subclassed).

I've created a scroll view programatically which contains a NSImageView instance. Here is the code I use for this purpose :


- (void)awakeFromNib
{
NSWindow * theWindow = [self window];

NSImageView * theImageView = [[NSImageView alloc] initWithFrame:NSMakeRect(0,0,300,300)];

[theImageView setImageFrameStyle:NSImageFrameGrayBezel];

NSScrollView * scrollView = [[NSScrollView alloc] initWithFrame: [[theWindow contentView] frame]];

[scrollView setHasVerticalScroller:YES];
[scrollView setHasHorizontalScroller:NO];
[scrollView setAutohidesScrollers:YES];
[scrollView setBorderType:NSNoBorder];
[scrollView setAutoresizingMask:NSViewWidthSizable| NSViewHeightSizable];

[scrollView setDocumentView:theImageView];

[theImageView release];

[theWindow setContentView:scrollView];

[scrollView release];
}


Everything seems to work perfectly...until I stretch the window vertically to an height smaller than the height of the image view : the vertical scroller should appear but it doesn't until the height of the window is around 20 pixels smaller than the height of the image view (I guess this ~20 pixels is the exact height of the horizontal scroller that is not displayed).

I've created a test project which highlight the problem. It can be downloaded here : http://homepage.mac.com/eric.morand/.Public/Test.zip

Just build it, run it and gently resize the window vertically until the vertical scroller appears.


Can anyone help me on this ? Am I doing something wrong or is this a (known) bug ?




Thanks,


Eric. _______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Prev by Date: how to get an event (also name the event) when mac(universal i.e. or min 10.3.9 and above) wakes up from sleep mode
  • Next by Date: Capturing events from Bluetooth USB Dongle
  • Previous by thread: Re: how to get an event (also name the event) when mac(universal i.e. or min 10.3.9 and above) wakes up from sleep mode
  • Next by thread: Capturing events from Bluetooth USB Dongle
  • Index(es):
    • Date
    • Thread