开发者

UIView draw in subview

Is it possible for a container UIView to draw in a child UIView? If s开发者_Go百科o, how do I obtain the child's cgcontext?


It is possible, add an accessor to the clild view's context.

Just because it is possible doesn't mean that this is recommended. In fact it is a really bad idea. A better is to ask the subview to change the way it is drawing. Set an accessor for an instance variable, or set a new state that will change the drawing.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜