Web lists-archives.com

Re: advice sought for program with GUI




On Thu, Feb 28, 2019 at 12:43:57PM +0100, Thomas Schmitt wrote:
> Hi,
> 
> [beginning to deviate from topic]
> 
> I wrote:
> > > Tcl is not the most comfortable programming language,
> 
> tomas@xxxxxxxxxx wrote:
> > Hey! this is the first time I (mildly) have to disagree with you.
> > Once I got to grips that Tcl is a kind of "inside-out" Lisp
> > (or a flip-backwards-and-a-half-turn Forth), Tcl is up there
> > in my favorite bunch.
> 
> When i wrote xorriso-tcltk as demo for a xorriso slave under a GUI master,
> i had a hard time with processing shell-style quoted text. In the end my
> solution was to let the xorriso slave parse quoted text into a more
> machine readable form (FORTRAN inspired, iirc) which i was able to digest
> in Tcl.
> 
> Another unexpected obstacle was to perform the C-style gesture of pipe(2)
> and fork(2) in order to create the slave and to connect its stdin and
> stdout to the Tcl program. Single channel is easy. But two-way
> communications seems not to be foreseen by Mr. Ousterhout (or i am not
> weird enough).

They've become better in both departments. In the second one *way*
better -- with the introduction of channels [1]

> Solution was to teach xorriso how to start and connect to its own
> frontends and to let the Tcl script start xorriso which then starts another
> instance of the Tcl script as actually working GUI frontend.

Hah. I have a little gui which juggles several running instances of
ffmpeg (as transcoding jobs). While it's running, you can drag-n-drop
additional jobs onto it and each job shows a little progress bar and
a couple of controls to cancel and things.

All in all about 700 LOC, but development went smoothly. Of course,
one has to think async to not get messed up.

It seems Tcl has grown a bit since then.

> (Ok. Probably i am as weird as tomas. Just differing in detail.)

This honors me :)

Cheers
-- t

Attachment: signature.asc
Description: Digital signature