Re: Drawing over a view's subviews
Re: Drawing over a view's subviews
- Subject: Re: Drawing over a view's subviews
- From: Nicko van Someren <email@hidden>
- Date: Wed, 15 Jun 2005 17:06:22 +0100
On 15 Jun 2005, at 16:56, Mark Morrill wrote:
I've got a view with an arbitrary number of subviews. Some of the
subviews might be custom WebViews, for example. The application is
an authoring tool.
What I want to be able to do is to draw 'grab points' so that the
user can resize a subview.
If I draw inside the view, the subviews draw over top of what I
draw. I need to be able to draw after the subviews draw.
Where would I hook into the drawing process to do this?
As far as I know the appropriate place to do this is not exposed in
the NSView API. I suggest that you create another, identically sized
view layered on top, which is marked as non-opaque (e.g. implements
isOpaque to return NO) and which handles your grab points (possibly
by implementing hitTest: so that the mouse clicks can "fall through"
your view when the click is not on a grab point).
Nicko
_______________________________________________
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