• 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: NSImageView and ZoomFactors
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSImageView and ZoomFactors


  • Subject: Re: NSImageView and ZoomFactors
  • From: Brian Postow <email@hidden>
  • Date: Fri, 20 Aug 2010 13:54:11 -0400

On Aug 20, 2010, at 1:35 PM, Quincey Morris wrote:

> On Aug 20, 2010, at 06:46, Brian Postow wrote:
>
>> Ok,. Since the NSImageView wants to always center the image in the bounds rect, that should make the translation (moving the origin) not too hard, yes?
>
> Yes, though I'd say it differently. What's important is the size of the document view, and where its frame is positioned within the bounds rect of the content (clip) view. That's because zooming has an impact on the limits and scroll position of the scroll bars.
>

ok, it appears that it's a little more complicated that that.

I just discovered 	[imageView setImageAlignment: ] which, as long as the imageView is bigger than the scrollview, does the correct thing (Lock the image to the upper left corner of the scrollView). However, when the imageView is smaller than the scrollview, The imageView is still locked to the bottom left of the scrollview, but the image is locked to the top left of the imageview.

Setting the Scrollview boundsOrigin, the imageView bounds origin and translating the origin of the imageview or the scrollview had absolutely no effect.

do I need to do something (other than setNeedsDisplay: YES) in order to make a translate actually happen?

Brian Postow
Senior Software Engineer
Acordex Imaging Systems

_______________________________________________

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: NSImageView and ZoomFactors
      • From: Quincey Morris <email@hidden>
References: 
 >NSImageView and ZoomFactors (From: Brian Postow <email@hidden>)
 >Re: NSImageView and ZoomFactors (From: Quincey Morris <email@hidden>)
 >Re: NSImageView and ZoomFactors (From: Brian Postow <email@hidden>)
 >Re: NSImageView and ZoomFactors (From: Quincey Morris <email@hidden>)
 >Re: NSImageView and ZoomFactors (From: Quincey Morris <email@hidden>)
 >Re: NSImageView and ZoomFactors (From: Brian Postow <email@hidden>)
 >Re: NSImageView and ZoomFactors (From: Quincey Morris <email@hidden>)
 >Re: NSImageView and ZoomFactors (From: Brian Postow <email@hidden>)
 >Re: NSImageView and ZoomFactors (From: Quincey Morris <email@hidden>)

  • Prev by Date: Re: Embedding a system preference pane
  • Next by Date: Re: Embedding a system preference pane
  • Previous by thread: Re: NSImageView and ZoomFactors
  • Next by thread: Re: NSImageView and ZoomFactors
  • Index(es):
    • Date
    • Thread