mirror of
https://github.com/gnustep/libs-back.git
synced 2025-04-22 23:42:16 +00:00
Implemented GSRectClipList() in GSStreamContext.m
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@23885 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
6fe8675dd8
commit
d4ec929e5e
2 changed files with 23 additions and 2 deletions
|
@ -1,4 +1,9 @@
|
|||
2006-10-15 11:14-EDT Mark Tracy
|
||||
2006-10-15 22:48-EDT Gregory John Casamento <greg_casamento@yahoo.com>
|
||||
|
||||
* Source/gsc/GSStreamContext.m: GSRectClipList() copied
|
||||
implementation from GSGState.m.
|
||||
|
||||
2006-10-15 11:14-EDT Mark Tracy <tracy454 at concentric dot net>
|
||||
|
||||
* Source/gsc/GSStreamContext.m: GSStreamContext did not implement
|
||||
GSRectFillList fix: copied code from GSGState.m.
|
||||
|
|
|
@ -717,7 +717,23 @@ fpfloat(FILE *stream, float f)
|
|||
|
||||
- (void) GSRectClipList: (const NSRect *)rects: (int)count
|
||||
{
|
||||
[self notImplemented: _cmd];
|
||||
int i;
|
||||
NSRect union_rect;
|
||||
|
||||
if (count == 0)
|
||||
return;
|
||||
|
||||
/*
|
||||
The specification is not clear if the union of the rects
|
||||
should produce the new clip rect or if the outline of all rects
|
||||
should be used as clip path.
|
||||
*/
|
||||
union_rect = rects[0];
|
||||
for (i = 1; i < count; i++)
|
||||
union_rect = NSUnionRect(union_rect, rects[i]);
|
||||
|
||||
[self DPSrectclip: NSMinX(union_rect) : NSMinY(union_rect)
|
||||
: NSWidth(union_rect) : NSHeight(union_rect)];
|
||||
}
|
||||
|
||||
- (void) GSRectFillList: (const NSRect *)rects: (int)count
|
||||
|
|
Loading…
Reference in a new issue