> You need to dissociate drawing from data collection. Your view's
> implementation of -drawRect: should simply draw whatever the current
> state is. It might be something as simple as this:
>
> - (void)drawRect:(NSRect)dirtyRect {
>  for (DataPoint *p in [modelObject dataPoints])
>    [self drawDataPoint:p];
> }

But I have. My drawRect: is simply as follows.

- (void) drawRect:(NSRect) rect
{
        NSRect bounds = [self bounds];

        [[NSColor blackColor] setFill];
        [NSBezierPath fillRect:bounds];

        [self drawAxes];
        [self drawError];
        
        return;
}
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to