This is the mail archive of the insight@sources.redhat.com mailing list for the Insight project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: question about Insight


On Sat, 2005-05-21 at 03:58 +0000, é ää wrote:

>      When programming with Tcl/tk and C, we generally code core function 
> with C and code GUI with tcl/tk. Iâd like to know how to implement the 
> interface between GUI and gdb in Insight. When gdb is running, it is in 
> wait loop. Iâd like to know how to pass the commands that received from 
> GUI to gdb. I have not found any documents about Insightâs source code. So 
> I cannot understand the structure of Insight source code.

Insight cannot be any different than your own applications. For the most
part, core functionality resides in C and the GUI in Tcl (and its
interpreter).

Gdb's event loop is not used (although it could). When the GUI needs to
execute something in gdb, it does exactly like any other Tcl/C[++] app
does: it calls new tcl commands installed into the interpreter. See
src/gdb/gdbtk/generic/gdbtk-cmds.c and others.

I am very surprised to hear that an experienced C/Tcl programmer
couldn't figure this out. Believe me when I say there are much trickier
things to figure out in Insight than this... This is also discussed in
the README file.

Good luck,
Keith


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]