Re: NSImageView scrolling
Re: NSImageView scrolling
- Subject: Re: NSImageView scrolling
- From: Jeremy Dronfield <email@hidden>
- Date: Sat, 28 Sep 2002 21:26:37 +0100
On Saturday, September 28, 2002, at 08:09 pm, Jan Van Tol wrote:
Actually, it would be really nice to have dynamic scroll bar hiding and
showing. It's not really necessary, but those inactive scroll bars
take up some valuable space, and look kind of ugly. How would I go
about doing this?
Look at the code given (and, more importantly, the documentation
referred to) in my last-but-one post. The code could be put in your
window controller's -windowDidResize: method or - more elegantly - you
could subclass NSImageView and call the code from the view's -drawRect:
method.
Another problem I have now, is that the image (and the ImageView) gets
pushed into the bottom-left corner of the scroll view. I would much
rather have it be centered. I've messed around with the auto-sizing
controls in IB, but I can't seem to get it to work right.
I think the best course of action would be for you to do an image app
tutorial. There's one that meets your requirements at
http://macdevcenter.com/pub/ct/37
Choose the Working With Bitmap Images tutorial. As well as the necessary
code, you'll find all the technical details nicely explained.
-Jeremy
========================================
email@hidden // email@hidden
The Alchemy Pages:
- fractious fiction at
http://freespace.virgin.net/jeremy.dronfield
========================================
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.