caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: "Angela Zhu" <angela22.zhu@gmail.com>
To: caml-list@inria.fr
Subject: Cancel button or Status bar
Date: Sat, 16 Feb 2008 11:01:02 -0600	[thread overview]
Message-ID: <f82e818a0802160901o2aee2c15qc2f3a2f4e71b2db2@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 931 bytes --]

Hi,

I am using OCaml to develop an interpreter with a GUI.
In the GUI, I have a "run" button, where when you click it, it
will call a function, say "eval prog1".

Some time, the running time of "eval prog1" can be long, and
in case I want to add to the GUI the functionality that,
when click on another "cancel" button, it will terminate the
computation/evaluation immediately. (The user might don't
want to wait until the execution to finish. )

Anyone have some idea how to achieve this?

If this is impractical in OCaml, then how can I generate a
"status bar", which indicates how much of the program
(e.g. in percentage) has been finished, so you can have
an estimation on how much more you need to wait for the program
to finish.

Thanks a lot in advance!

-- 
Regards,
Angela Zhu
------------------------------------------
Dept. of CS, Rice University
http://www.cs.rice.edu/~yz2/
------------------------------------------

[-- Attachment #2: Type: text/html, Size: 1139 bytes --]

             reply	other threads:[~2008-02-16 17:01 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-16 17:01 Angela Zhu [this message]
2008-02-16 17:26 ` [Caml-list] " Dominique Martinet
2008-02-16 21:49   ` Angela Zhu
2008-02-17 22:03   ` Angela Zhu
2008-02-18  8:24     ` Dominique Martinet

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f82e818a0802160901o2aee2c15qc2f3a2f4e71b2db2@mail.gmail.com \
    --to=angela22.zhu@gmail.com \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).