NSWindow setResizable:
December 18, 2007This article has been updated moved to a new location.
This article has been updated moved to a new location.
EDITED TO ADD: I could reproduce this bug in a large project, but not isolate it in a smaller one. It is much likely for my code to have a bug then NSWorkspace. I’m still not 100% certain that this issue wasn’t my fault in some way I don’t understand. But no [...]
A few days ago, out of morbid curiosity, I went looking for a a quine written in AppleScript. To my surprise, I couldn’t find one.
I’d never actually written a quine before, so this was a good ‘excuse’ to make one (and brush up on some computability theory — use it or lose it).
Well, here [...]
Before you consider using any of the unsupported hacks I’m about to discuss, check to see if existing frameworks , or iChat’s AppleScript interface, will do what you need. Any software update can break unsupported code in unpredictable ways at any time. When Leopard came out, all the hacks I had been using [...]
This article has been updated, and republished here.
When writing a short AppleScript to complete a specific task, do not write a procedure that checks if A exists, then operates on it if it does. Instead, write an expression that operates on A, and ignore any exceptions caused by A not existing. Surrounding the statement in a try-block will ignore any [...]
This article has been updated, and moved here.
To make sure there is only one instance of your application running, you can use the function WeAreAlreadyRunning() from SingletonApplication.zip
WeAreAlreadyRunning() walks the list of running processes, using the Process Manager. Each process’s bundle identifier (if it exists) is compared to the bundle identifier of the calling process’s main bundle.
If you are writing a [...]
If you are about to add automatic updating to your application (and you should), then check out the Sparkle Framework before you start. I wish I had done this before I spent a lot of time writing my own automatic updating code.
(EDITED TO ADD: this app looks promising. Ultimately a central place to [...]
This article has been updated and moved here.