开发者

Programmatically resizing and Scrolling NSView after application launch

I want to create a simple application which performs some calculations and then draws some images on view. I use NSBezierPath. Then I must resize t开发者_JAVA技巧he view and allow people scroll the finished picture. But i don't know how.If I also try to draw an image on an invisible part of canvas then it becomes invisible or isn't drawn (I couldn't know the future canvas size).


Check out the Apple sample code called BezierPathLab. I think that will get you started. There's lot of other sample code for Quartz 2D drawing too.

Being able to scroll and resize the view should be as simple as putting the view that you will be using to draw inside an NSScrollView.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜