Odd redraw issue
Odd redraw issue
- Subject: Odd redraw issue
- From: Gideon King <email@hidden>
- Date: Thu, 13 Jul 2006 22:58:19 +1000
Hi, I have a problem in that drawing a pattern image in a view which
is in a scroll view makes a mess when the view is scrolled. I created
a test project and made a custom view, made it a subview of a
scrollview, and put an image in my project and the only code I had in
the custom view was the following:
- (void)drawRect:(NSRect)rect {
[[NSColor whiteColor] set];
NSRectFill(rect);
NSColor *tempColor = [NSColor colorWithPatternImage:[NSImage
imageNamed:@"myImage"]];
[tempColor set];
[NSBezierPath fillRect:rect];
}
And the view is still messed up when I scroll with bits of the image
being drawn over one another. I tried changing the references to
"rect" to [self bounds] but it made no difference.
Any ideas?
Thanks
Gideon King
email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden