diff src/nsimage.m @ 101404:8bf66a156bc5

* nsimage.m (setPixmapData:): Set to ignore image DPI.
author Adrian Robert <Adrian.B.Robert@gmail.com>
date Fri, 23 Jan 2009 14:08:24 +0000
parents 954e1944ccf2
children b5a34573cf82
line wrap: on
line diff
--- a/src/nsimage.m	Fri Jan 23 13:52:24 2009 +0000
+++ b/src/nsimage.m	Fri Jan 23 14:08:24 2009 +0000
@@ -400,6 +400,12 @@
 
           if ([bmRep numberOfPlanes] >= 3)
               [bmRep getBitmapDataPlanes: pixmapData];
+
+          /* The next two lines cause the DPI of the image to be ignored.
+             This seems to be the behavior users expect. */
+          [self setScalesWhenResized: YES];
+          [self setSize: NSMakeSize([bmRep pixelsWide], [bmRep pixelsHigh])];
+
           break;
         }
     }