adding python scripting to my application

Julian julvar at nospamtamu.edu
Mon Nov 13 02:34:17 CET 2006


"martdi" <martin.dion at gmail.com> wrote in message 
news:1162843693.517313.286480 at m73g2000cwd.googlegroups.com...
> Jerry wrote:
>> I am not a Python guru by any means, but I believe that when an
>> application says that you can "script" their application with Python,
>> it means that you can actually write Python code to interact with the
>> application.  Embedding may be the same thing.  Extending (as I read
>> it) involves writing portions of your program in Python and have do the
>> logic portions.
>>
>> If you would like to allow users to write small scripts that interact
>> with your program and control it (a la VBScript or AppleScript), then I
>> believe embedding Python in your program is what you want.
>>
>> If you would like Python to run various parts of your program in order
>> to make some portions easier to write/manage/whatever, then you want to
>> "extend" your program using Python.
>>
>> The key difference being that you aren't providing a way for someone
>> else to interact with your program using Python if you are extending.
>>
>> Again, I am not a guru and a read through the docs on python.org would
>> probably be the best place to get sound technical advice on these
>> subjects.
>>
>> --
>> Jerry
>
>
> I'm not sure either, but I though Extending was making the C/C++ Code
> available from Python, while Embedding was making Python Code Available
> in your app.
>

Like I mentioned in my first post, one of the purposes of linking to python 
would be to run multiple cases in a for loop.
that would mean passing information from the python script to my c++ 
application. mean python would have to be the top-level program.
so, I think I should be looking at extending my program. I am going to look 
at using swig for this..

thanks,
Julian. 





More information about the Python-list mailing list