Re: Problem using NSView's scrollRect:by:

2017-01-26 Thread Quincey Morris
On Jan 25, 2017, at 23:37 , Quincey Morris wrote: > > There’s yet something else going on here I tried creating a project with your code, and there is indeed something else going on here: 1. In a default, non-storyboard, non-document macOS application

Re: Problem using NSView's scrollRect:by:

2017-01-25 Thread Quincey Morris
On Jan 25, 2017, at 22:59 , Tae Won Ha wrote: > > I've read the documentation, but I thought that to "just" copy a potion of > the NSView's content to somewhere else inside the view, you don't have to do > the second and third part. And I did not quite understand the second

Re: Problem using NSView's scrollRect:by:

2017-01-25 Thread Quincey Morris
On Jan 25, 2017, at 14:13 , Tae Won Ha wrote: > > What I expected was that the red box at the bottom left corner gets > 'copied' to the point (100, 100) when I invoke the triggerScroll action. > However nothing happens. What am I doing wrong? At the very least, you aren’t

Problem using NSView's scrollRect:by:

2017-01-25 Thread Tae Won Ha
Hi guys. I'm trying to implement a view that has scroll functionality by itself, since I cannot use an NSScrollView. I think that NSView's scrollRect:by: is probably the way to go, but how can I use it? I tried the following (in a freshly created Xcode project): AppDelegate.swift: --- >8 ---