Use the offset adjustment for cairo > 1.8 in the general case.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@28943 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Fred Kiefer 2009-11-03 08:39:15 +00:00
parent 22cf7533eb
commit 55a29294d2
2 changed files with 9 additions and 3 deletions

View file

@ -1301,12 +1301,13 @@ _set_op(cairo_t *ct, NSCompositingOperation op)
[source->ctm boundingRectFor: aRect result: &aRect];
if ((copyOnSelf) && (cairo_version() >= CAIRO_VERSION_ENCODE(1, 8, 0)))
// if ((copyOnSelf) && (cairo_version() >= CAIRO_VERSION_ENCODE(1, 8, 0)))
if (cairo_version() >= CAIRO_VERSION_ENCODE(1, 8, 0))
{
NSSize size = [_surface size];
NSSize size = [source->_surface size];
// For cairo > 1.8 we seem to need this adjustment
aRect.origin.y -= 2*(offset.y - size.height);
aRect.origin.y -= 2*(source->offset.y - size.height);
}
x = floorf(aPoint.x);