Hello List,

I am trying to get an NSCustomImageRep to properly “react” (e.g. redraw) after 
a NSImage setSize call.

I am writing a NSCustomImageRep class for a resolution independent image format 
(e.g. like NSPDFImageRep and NSEPSImageRep). However, I can’t get it to 
properly account when the size is adjusted through NSImage setSize. So long as 
I call setSize before the first time the image is drawn, everything works 
perfectly, but any subsequent calls to setSize don’t seem to cause my imageRep 
to redraw for the new size.

A call to NSImage recache doesn’t seem to have any effect, and I am especially 
confused because the documentation for NSImage setCacheMode states that 
“NSPDFImageRep and NSEPSImageRep classes use theNSImageCacheAlways mode” How 
can the image reps be always cached and yet respond appropriately (e.g. 
maintain full resolution) when NSImage setSize is called?

Thanks in advance!

-Mathew Eis
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to