Drawing to NSQuickDrawView
Drawing to NSQuickDrawView
- Subject: Drawing to NSQuickDrawView
- From: Ernst Persson <email@hidden>
- Date: Wed, 17 Apr 2002 15:45:04 +0200
Hi!
I've just started playing around a bit with
Cocoa/InterfaceBuilder/Objective-C and thought I would do a Game Of Life
application.
The main window has a NSQuickDrawView and some buttons... Everything is
pretty much set up as in the CurrencyConverter tutorial.
I have a IBOutlet id myquickdrawview; that I use on the action
- (IBAction)resize:(id)sender
{
void* thePort;
Rect portRect;
[myquickdrawview lockFocus];
thePort = [myquickdrawview qdPort];
SetPort( thePort);
EraseRect( GetPortBounds( thePort, &portRect) );
SysBeep(1);
[myquickdrawview unlockFocus];
}
So when I press the button I get my SysBeep but nothing is drawn... what
am I doing wrong?
//ernie
_______________________________________________
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.