Re: NSView drawing problem
Re: NSView drawing problem
- Subject: Re: NSView drawing problem
- From: Thilo Ettelt <email@hidden>
- Date: Sat, 21 Dec 2002 12:56:30 +0100
Thanks. I have subclassed the NSView now. Unfortunetely the problem
still occurred. But i have found a work around: i call the
-setNeedsDisplay: method in the -init and the rest is done by a timer
(which i need in every case because i am working on a clock app).
Cheers, Thilo
Am Samstag, 21.12.02 um 12:35 Uhr schrieb David Rio Vierra:
Your approach to drawing seems a bit off. The usual way of drawing
into a view is actually by implementing an NSView subclass which does
the drawing in its -drawRect: method. Once this method is
implemented, existing NSView code will call it at the appropriate time
in order to draw your view. Keep in mind that in -drawRect:, focus
has already been locked on the view and you need neither lock or
unlock your view.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.