guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Alternatives to gh_repl() for gtk app?


From: Chris Baker
Subject: Re: Alternatives to gh_repl() for gtk app?
Date: 06 Jan 2001 11:33:42 -0800
User-agent: Gnus/5.0803 (Gnus v5.8.3) Emacs/20.7

Neil Jerram <address@hidden> writes:

> >>>>> "Chris" == Chris Baker <address@hidden> writes:
> 
>     Chris> I'd like to have an repl just like the guile repl in my gtk
>     Chris> app.  The problem is I can't just hand over control to
>     Chris> gh_repl(), since I have to hand over control to gtk.  I can
>     Chris> arrange to get a callback when there's input available, and
>     Chris> I can evaluate it, but I'd like to reuse as much of the
>     Chris> existing code as possible, so I can use the debugging
>     Chris> facilities, etc.  I had a look through boot-9.scm, but it
>     Chris> wasn't immediately clear to me what was going on, so I'm
>     Chris> not quite sure how best to procede.  Does anyone have any
>     Chris> ideas?
> 
> Take a look at the gtk-repl procedure in
> /usr/local/share/guile/gtk-1.2/gtk.scm.  (Assuming you have installed
> guile-gtk with prefix /usr/local.)  I think it does what you need - or
> something very similar.

Thanks to all for the replies.

It took me a bit to figure out what was going on in this procedure,
and I had to adapt it a bit, since I'm trying to avoid gtk
dependencies in my scheme, but it works great.  I can even run my app
in emacs and use scheme mode commands to send it code.

It might be cool to move event-repl.scm from guile-gtk to the main
guile distribution since it doesn't seem to depend on gtk, and it
might be useful for people using other drawing enviornments.

Thanks again,

cbb




reply via email to

[Prev in Thread] Current Thread [Next in Thread]