Re: Persistant reference to file that is not a path?

2011-08-25 Thread Josh Abernathy
Check out file reference URLs and bookmarks: http://developer.apple.com/library/mac/#documentation/FileManagement/Conceptual/FileSystemProgrammingGUide/AccessingFilesandDirectories/AccessingFilesandDirectories.html#//apple_ref/doc/uid/TP40010672-CH3-SW5 On Aug 25, 2011, at 11:37 PM, Ron

Re: [Lion] IBOutlets, strong or weak?

2011-08-08 Thread Josh Abernathy
According to the AppKit release notes: Note that Xcode 4.2 defaults to ARC when creating new projects, and in the WWDC seed release, as well as in the latest version available at the time 10.7 ships, generates outlet declarations that are strong. This is true for outlets generated in new

Re: Temporarily enabling layer backing for NSView

2011-05-18 Thread Josh Abernathy
Try doing the animation one runloop after calling -setWantsLayer:, kinda like this (typed in Mail): - (void)doAnimation { [parentView setWantsLayer:YES]; [self performSelector:@selector(noSeriouslyDoTheAnimation) withObject:nil afterDelay:0]; } - (void) noSeriouslyDoTheAnimation {

Re: iCal-style NSTextFields

2010-01-13 Thread Josh Abernathy
field. Any help would be appreciated. On Jan 10, 2010, at 2:54 PM, Josh Abernathy wrote: If you're asking about the shadow, create a child window and move them to that when they're editing. On Jan 10, 2010, at 11:56 AM, Seth Willits wrote: On Jan 10, 2010, at 11:49 AM, Ulai Beekam

Re: iCal-style NSTextFields

2010-01-10 Thread Josh Abernathy
If you're asking about the shadow, create a child window and move them to that when they're editing. On Jan 10, 2010, at 11:56 AM, Seth Willits wrote: On Jan 10, 2010, at 11:49 AM, Ulai Beekam wrote: Go into iCal (in Snow Leopard) and create a new event and and then click outside that

Re: maximum theoretical speedup with dual quad processors

2009-01-31 Thread Josh Abernathy
At the risk of stating the obvious: it seems like your limiting factor in speedup will depend a lot more on your algorithm design than NSInvocationQueue, the number of cores/processors, etc. In other words, this isn't really an Apple-specific question. It's a matter of parallel algorithm

Re: autocompletion window disappears

2009-01-20 Thread Josh Abernathy
I've also written my own completion mechanism. It's not too hard, just add a child window and list your results however makes sense for your application. A lot less ugly and a lot more appropriate than Apple's default, in my opinion. On Jan 20, 2009, at 10:28 AM, Ross Carter wrote: On

Re: How to launch window of the application on clicking of dock icon?

2008-12-09 Thread Josh Abernathy
In your app delegate, implement -applicationDidBecomeActive: to show your window. On Dec 9, 2008, at 12:02 PM, Arun wrote: Hi, I have created a simple application in cocoa. when it is ran, the main window appears and a default dock icon in the Dock. If i close the window, the dock icon

NSPredicateEditor and date comparisons

2008-12-07 Thread Josh Abernathy
Hi all, In my application, users have the option of comparing to a date in an NSPredicateEditor. For the NSDates it is comparing against, only the date is important; time doesn't matter. The interesting thing I found about NSPredicateEditor is the NSTimeInterval it compares my NSDates to

Re: NSPredicateEditor and date comparisons

2008-12-07 Thread Josh Abernathy
to a string, which introduces more complications. NSPredicateEditor tends to just call objectValue on the gui component, so try calling that yourself on your NSDatePicker and see what happens. --- On Sun, 7/12/08, Josh Abernathy [EMAIL PROTECTED] wrote: From: Josh Abernathy [EMAIL PROTECTED

NSPredicateEditor and date comparisons

2008-12-06 Thread Josh Abernathy
Hi all, In my application, users have the option of comparing to a date in an NSPredicateEditor. For the NSDates it is comparing against, only the date is important; time doesn't matter. The interesting thing I found about NSPredicateEditor is the NSTimeInterval it compares my NSDates to

Re: Putting an image on a CALayer

2008-10-21 Thread Josh Abernathy
Scott Stevenson uses an NSImage category with: - (CGImageRef)cgImage { // I'm open to better ideas. :) NSData* data = [self TIFFRepresentation]; return CreateCGImageFromData(data); } So create an NSImage and use that. On Oct 21, 2008, at 11:46 AM, DKJ wrote: