Hi,
one way would be to run the code in a separate thread.
Perhaps it wouldn't be particularly elegant, but you could simply
append "(call-with-new-thread (lambda()" <code-from-your-text-field> "))" before calling eval.
You'd need to reorganize your app, however, if you'd wish to display the _expression_'s resulting object, because if you did it that way, you'd only get a thread object.
A possible solution would be to do something like this:
(define thread-results (make-hash-table))
(let ((thread (call-with-new-thread
(lambda()(let ((result <code-from-your-text-field>))
(hash-set! thread-results (current-thread) result))))))
(set-thread-cleanup! (lambda() <display data from thread results to the text field>)))
I probably wouldn't know however how to implement that at the C level.
Best regards