NSWindow setFrame:display: ceiling behavior?

2011-08-26 Thread Arbit Richardi
Given the following code snip: NSRect newFrame = [myWindow frame]; newFrame.size.width = 772.16; [myWindow setFrame:newFrame display:YES]; NSLog(@"%f", [myWindow frame].size.width); The output is: 773.00, and in fact, the window is drawn 773 points wide on my MacBook Pro. Why do windows pref

Re: NSWindow setFrame:display: ceiling behavior?

2011-08-27 Thread Arbit Richardi
On Sat, Aug 27, 2011 at 12:31 AM, Nick Zitzmann wrote: > > On Aug 25, 2011, at 2:36 PM, Arbit Richardi wrote: >> Is there another method that will >> draw windows at non-whole number point sizes? > > No. What are you trying to accomplish? Cocoa has no problem at all

Unlock NSWindow aspect ratio?

2011-09-24 Thread Arbit Richardi
It's easy to lock an NSWindow aspect ratio with setAspectRatio: or setContentAspectRatio: but is there a way to unlock it? Documentation for contentAspectRatio states that the default content aspect ratio is (0, 0), so you might think setting to the "default" would work, but it doesn't — it makes t

Re: Unlock NSWindow aspect ratio?

2011-09-24 Thread Arbit Richardi
On Sat, Sep 24, 2011 at 6:10 PM, Arbit Richardi wrote: > It's easy to lock an NSWindow aspect ratio with setAspectRatio: or > setContentAspectRatio: but is there a way to unlock it? Documentation > for contentAspectRatio states that the default content aspect ratio is > (0, 0), s

Window collection behavior, remove from cycle?

2011-10-11 Thread Arbit Richardi
I have a fullscreen window that should effectively disable window cycling; because I've taken over the entire screen, it doesn't makes sense to be able to bring other windows in front of the fullscreen one. NSWindow's NSWindowCollectionBehaviorIgnoresCycle collection behavior only removes a window

Speeding up image drawing?

2011-10-31 Thread Arbit Richardi
I'm looking for tips to speed image drawing on OS X — this is a primary function of my application. I started out naively with NSImage, switched to CGImage, tried layer backing, and now draw directly into a hosted layer with Quartz. I have an implementation using CATiledLayers but it doesn't add sp

Re: Speeding up image drawing?

2011-11-01 Thread Arbit Richardi
> I'm pretty certain Preview is using IKImageView, or at least it used to. Mike, Preview doesn't use IKImageView in 10.6. That class is really slow, probably because it has a ton of bells and whistles, and it doesn't show up in the stack frames when I look at Preview in Instruments (Preview appear