[Pythonmac-SIG] #! line and simple dialogs [SOLVED]
Bob Ippolito
bob at redivi.com
Sat Oct 2 09:05:28 CEST 2004
On Oct 2, 2004, at 2:51 AM, Kevin Altis wrote:
> On Oct 1, 2004, at 10:54 PM, Nathaniel Gray wrote:
>
>> I actually meant dependencies for the casual scripter, not the
>> end-user. I'd love to be able to tell my friends, "Python makes an
>> elegant replacement for AppleScript for your simple scripting tasks
>> and you only need to install 1 package to make it work." If
>> EasyDialogs was just a little better it would already be true! :-)
>> If/when appscript and/or PyObjC get into the core then the argument
>> would become even simpler and much more convincing.
>
> It is possible that Apple will include the current versions of PyObjC,
> wxPython, and/or appscript with Tiger, but I wouldn't count on it and
> it still won't solve the problem on Jaguar or Panther. There isn't a
> whole lot of difference between installing PyObjC and wxPython from a
> user standpoint, they both are distributed as disk images and get
> installed by double-clicking a package file. Of course, you could use
> the PackageManager as well, but that has other problems. AFAIK,
> appscript is orthogonal to the issue of whether you do the GUI via
> wxPython or PyObjC even if that GUI is a linear series of steps and
> only uses dialogs for input. For scripting other applications
> appscript certainly seems easier to use than PyObjC from the examples
> I've seen and used myself. So, I think you're going to want to install
> two packages, but neither are hard to do and it will work on different
> versions of Mac OS X.
What PyObjC examples are you thinking of that demonstrate scripting of
other applications? If any exist, they certainly aren't using any
written-in-Objective-C facilities to script other applications. AppKit
really doesn't have any features that will let you script other
applications (though it does have features that help you develop a
scriptable application). The Python standard library ways of doing
Apple Events are ancient and cumbersome, so of course anything using
appscript is going to look a heck of a lot better (it's a wrapper on
top of them), but none of them depend on PyObjC.
It is possible to write a GUI that is a linear series of steps using
only dialogs for input with purely Apple Events (and therefore possible
using only appscript). I'm not sure it would be particularly great,
but that's what AppleScripters have done for quite some time.
-bob
More information about the Pythonmac-SIG
mailing list