mirror of
https://github.com/gnustep/libs-back.git
synced 2025-04-22 15:31:14 +00:00
Correct drawing of pattern colour.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@28911 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
c937679547
commit
738706e4b6
2 changed files with 28 additions and 11 deletions
23
ChangeLog
23
ChangeLog
|
@ -1,23 +1,30 @@
|
|||
2009-10-29 Fred Kiefer <FredKiefer@gmx.de>
|
||||
|
||||
* Source/gsc/GSGState.m (-_fillRect:withPattern:): Convert the
|
||||
drawing coordinate back in user space.
|
||||
|
||||
2009-10-28 Thomas Gamper <icicle@cg.tuwien.ac.at>
|
||||
|
||||
* Source/x11/XGGLFormat.m
|
||||
Check for GLX_VERSION_1_4.
|
||||
Check for GLX_VERSION_1_4.
|
||||
|
||||
2009-10-28 Riccardo Mottola <rmottola@users.sf.net>
|
||||
|
||||
* Source/x11/XGGLFormat.m
|
||||
cleaned up c99-isms
|
||||
|
||||
2009-10-25 Thomas Gamper <icicle@cg.tuwien.ac.at>
|
||||
|
||||
* Source/x11/XGServerWindow.m
|
||||
Implement setMouseLocation:onScreen:.
|
||||
* Source/x11/XGServerWindow.m
|
||||
Implement setMouseLocation:onScreen:.
|
||||
|
||||
2009-10-25 Thomas Gamper <icicle@cg.tuwien.ac.at>
|
||||
|
||||
* Source/x11/XGGLContext.m
|
||||
* Source/x11/XGGLFormat.m
|
||||
* Headers/x11/XGOpenGL.h
|
||||
Clean up OpenGL stuff, reformat code and add Multisampling
|
||||
support.
|
||||
* Source/x11/XGGLContext.m
|
||||
* Source/x11/XGGLFormat.m
|
||||
* Headers/x11/XGOpenGL.h
|
||||
Clean up OpenGL stuff, reformat code and add Multisampling
|
||||
support.
|
||||
|
||||
2009-10-23 Fred Kiefer <FredKiefer@gmx.de>
|
||||
|
||||
|
|
|
@ -1236,6 +1236,12 @@ typedef enum {
|
|||
NSSize size;
|
||||
float x;
|
||||
float y;
|
||||
NSAffineTransform *ictm;
|
||||
|
||||
// The coordinates we get here are already in device space,
|
||||
// but compositeToPoint needs user space coordinates
|
||||
ictm = [ctm copyWithZone: GSObjCZone(self)];
|
||||
[ictm invert];
|
||||
|
||||
size = [pattern size];
|
||||
y = floor(NSMinY(rect) / size.height) * size.height;
|
||||
|
@ -1243,13 +1249,17 @@ typedef enum {
|
|||
{
|
||||
x = floor(NSMinX(rect) / size.width) * size.width;
|
||||
while (x < NSMaxX(rect))
|
||||
{
|
||||
[color_pattern compositeToPoint: NSMakePoint(x, y)
|
||||
{
|
||||
NSPoint p = NSMakePoint(x, y);
|
||||
|
||||
p = [ictm pointInMatrixSpace: p];
|
||||
[color_pattern compositeToPoint: p
|
||||
operation: NSCompositeSourceOver];
|
||||
x += size.width;
|
||||
}
|
||||
}
|
||||
y += size.height;
|
||||
}
|
||||
RELEASE(ictm);
|
||||
}
|
||||
|
||||
- (void) fillRect: (NSRect)rect withPattern: (NSImage*)color_pattern
|
||||
|
|
Loading…
Reference in a new issue