Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

jeanlain

macrumors 68020
Original poster
Mar 14, 2009
2,481
968
Hey, I'm writing a little app that I'd like to turn into a quickook plugin for viewing DNA sequences traces (such as these) from the Finder. I code as a hobby and this is my first xCode project, so be nice. ;)

I embedded the document view in an NSScrollView in IB (Xcode 4.4) and set the frame.size of the document view to be the size of the document (length of trace).
Scrolling works as intended, but isn't smooth. "Copy on scroll" (as set in IB) doesn't have any effect, so I suppose it doesn't work for some reason.
If I read the documentation, copyOnScroll is a method of NSClipView. I haven't set an NSClipView in IB, but I suppose this was done behind the scene when I embedded the document view inside the scroll view (the Apple documentation isn't quite clear on this). Otherwise it wouldn't make sense to offer a checkbox for "copy on scroll" in the scroll view attribute inspector (copyOnScroll is not a method of NSCrollView).

I also made sure that the scroll view draws its background (not doing so disables copy on scroll).

What am I missing? :confused:
 
Why not post the project to GitHub or BitBucket and have people take a look at it in its entirety? I did this with my OS X learning projects and it helped me a lot.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.