integrating embedded interpreter with external controls

J

joshusdog

I need some advice about how to go about architecting a solution to
the following problem.

I'd like to create an application that has an interactive listener/
console window in which the user can enter commands (in much the same
vain as 3D Studio Max, for those who are familiar with the product).
The console would essentially be an embedded Python interpreter
running the interactive loop (a call to the C API's
PyRun_InteractiveLoop()).

I'd also like buttons and other UI controls to be able to access
functions and objects that are defined through the console. I'm not
really sure how to integrate the UI controls with the console though,
especially if the console is running PyRun_InteractiveLoop(), which is
a tight loop.

I'm guessing that the solution will most likely require the console to
run in a separate thread, but I still don't know how to get the UI to
interact with the console.

Does anyone have any helpful suggestions?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,900
Latest member
Nell636132

Latest Threads

Top