[Pythonmac-SIG] Python and LabVIEW (yet another thought)
Marcus H. Mendenhall
marcus.h.mendenhall@vanderbilt.edu
Fri, 21 Jun 2002 16:41:59 -0500
>On Friday, June 21, 2002, at 03:27 , Marcus H. Mendenhall wrote:
>>>To be completely sure that Python (and the underlying GUSI and
>>>SIOUX libraries) don't touch any windows you can call
>>>PyMac_SetConsoleHandler(PyMac_DummyReadHandler,
>>>PyMac_DummyWriteHandler, PyMac_DummyWriteHandler) before calling
>>>PyMac_Initialize(). See
>>
>>
OK, I went ahead and looked at the source for the PyMac stuff to see
whether this type of solution is feasible. The problem probably
arises even earlier in the startup process than setting up the
console handlers, since init_common initializes all the Mac toolbox
stuff, even in the fully embedded (faceless) case.
I may try to dredge up a Mac with a current copy of CW7, and build a
custom PythonCore which does no mac UI initialization, and see if
this can be made compatible with LabVIEW.
If this works, it might not be a bad idea to add some switches so
that it is easy to build versions of Python which can be embedded in
full-fledged mac apps, which already have a running UI, and are
likely to take exception to anyone reinitializing stuff. Basically,
what I need is a copy of the unix Python compiled into the form of a
Mac shared library, since most of the things I plan to do with it
will have no need for Mac interface elements to be accessed from
Python.
Any thoughts?
Marcus