Re: Setting color to an NSView
Re: Setting color to an NSView
- Subject: Re: Setting color to an NSView
- From: Michael Watson <email@hidden>
- Date: Fri, 8 Dec 2006 09:53:35 -0500
Where is that -drawRect: being done? In the NSView or the NSSplitView?
If it's in the NSView, are you sure myRect is what you think it is?
--
m-s
On 08 Dec, 2006, at 09:16, vibhatha v wrote:
Hi,
I have an NSView and this NSView is a part of splitview.
Now, i have to set color to this NSView. Also, i have some text
fields on my
view which should be visible.
i tried setting the color using,
-(void)drawRect:(NSRect)rect
{
NSRect myRect = NSMakeRect(0,398,212,107);
[[NSColor blueColor] set];
NSRectFill(myRect);
}
in my custom class.
Also, i tried setting the view color in my controller class also.
But this does not seem to work.
Can anyone suggest me as to where i have gone wrong?
Thanks and Regards,
Vibhatha.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
40bungie.org
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden