mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 06:51:44 +00:00
* Source/NSImageCell.m: if drawing on a view use -centerScanRect:
to pixel align the drawing rect. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@34285 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
8936dbf826
commit
44d4221385
2 changed files with 16 additions and 3 deletions
|
@ -1,3 +1,8 @@
|
|||
2011-11-17 Eric Wasylishen <ewasylishen@gmail.com>
|
||||
|
||||
* Source/NSImageCell.m: if drawing on a view use -centerScanRect:
|
||||
to pixel align the drawing rect.
|
||||
|
||||
2011-12-02 German Arias <german@xelalug.org>
|
||||
|
||||
* Source/NSAlert.m (-_setupPanel): Verify if there is error
|
||||
|
@ -951,7 +956,7 @@
|
|||
ivars with the non-fragile ABI.
|
||||
|
||||
2011-06-28 Eric Wasylishen <ewasylishen@gmail.com>
|
||||
|
||||
|
||||
* Headers/Additions/GNUstepGUI/GSImageMagickImageRep.h:
|
||||
* Source/GNUmakefile:
|
||||
* Source/NSImageRep.m:
|
||||
|
|
|
@ -182,6 +182,7 @@ yBottomInRect(NSSize innerSize, NSRect outerRect, BOOL flipped)
|
|||
NSPoint position;
|
||||
BOOL is_flipped = [controlView isFlipped];
|
||||
NSSize imageSize, realImageSize;
|
||||
NSRect rect;
|
||||
|
||||
NSDebugLLog(@"NSImageCell", @"NSImageCell drawInteriorWithFrame called");
|
||||
|
||||
|
@ -237,9 +238,16 @@ yBottomInRect(NSSize innerSize, NSRect outerRect, BOOL flipped)
|
|||
break;
|
||||
}
|
||||
|
||||
rect = NSMakeRect(position.x, position.y,
|
||||
imageSize.width, imageSize.height);
|
||||
|
||||
if (nil != controlView)
|
||||
{
|
||||
rect = [controlView centerScanRect: rect];
|
||||
}
|
||||
|
||||
// draw!
|
||||
[_cell_image drawInRect: NSMakeRect(position.x, position.y,
|
||||
imageSize.width, imageSize.height)
|
||||
[_cell_image drawInRect: rect
|
||||
fromRect: NSMakeRect(0, 0, realImageSize.width,
|
||||
realImageSize.height)
|
||||
operation: NSCompositeSourceOver
|
||||
|
|
Loading…
Reference in a new issue