• 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
Scaled NSImage size of NSImageView?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Scaled NSImage size of NSImageView?


  • Subject: Scaled NSImage size of NSImageView?
  • From: Gustavo Pizano <email@hidden>
  • Date: Wed, 13 Jan 2010 15:57:26 +0100

Hello all.
I want to get the actual size of the NSImage which I dragged into an NSImaveView that has the imageScaling to NSImageScaleProportionallyUpOrDown.

I have found some answers on the web, but it seems Im still missing something, or those answer don't apply to me.. On of them was to create a Category of NSImageCell and there add a method like this


@implementation NSImageCell  (XWSImageCellCategory);

-(NSRect)rectCoveredByImageInBounds:(NSRect) bounds{
	return [super  imageRectForBounds:bounds];
}


I have done that.. but Im getting still the size of the NSImageView.

I dunno if  Im missing something in my Custom NSImageView, overriding some method, but I don't see what might help me.

Thanks a lot

Best Regards

Gustavo Pizano

_______________________________________________

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: Scaled NSImage size of NSImageView?
      • From: David Duncan <email@hidden>
  • Prev by Date: iPhone: CATransition done (get the key?)
  • Next by Date: coreAnimation CALayers and NSViews, which to use ?
  • Previous by thread: Re: iPhone: CATransition done (get the key?)
  • Next by thread: Re: Scaled NSImage size of NSImageView?
  • Index(es):
    • Date
    • Thread