unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* What is the best way to signal the completion of a task?
@ 2009-07-01 13:32 Steven Shiells
  2009-07-01 15:26 ` Lennart Borgman
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Steven Shiells @ 2009-07-01 13:32 UTC (permalink / raw)
  To: Help-gnu-emacs


I am part of a group who are writing some software that will be
compatible with Emacs. Initially, the software is expected to be slow,
and the user may wish to go and do something else. Currently, there
are situations where there are no visible signs that the task has been
completed. It is in these circumstances that we are unsure of the best
way to notify the user that the task has been completed. We are
looking for something simple and that will not annoy the user if they
away doing other things.

We have tried searching the forum for any similar posts, but had no
success. Any suggestions would be greatly appreciated.

Thanks,

Steven
-- 
View this message in context: http://www.nabble.com/What-is-the-best-way-to-signal-the-completion-of-a-task--tp24289865p24289865.html
Sent from the Emacs - Help mailing list archive at Nabble.com.





^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: What is the best way to signal the completion of a task?
       [not found] <mailman.1647.1246459080.2239.help-gnu-emacs@gnu.org>
@ 2009-07-01 15:03 ` Pascal J. Bourguignon
  0 siblings, 0 replies; 6+ messages in thread
From: Pascal J. Bourguignon @ 2009-07-01 15:03 UTC (permalink / raw)
  To: help-gnu-emacs

Steven Shiells <ss215@hw.ac.uk> writes:

> I am part of a group who are writing some software that will be
> compatible with Emacs. Initially, the software is expected to be slow,
> and the user may wish to go and do something else. Currently, there
> are situations where there are no visible signs that the task has been
> completed. It is in these circumstances that we are unsure of the best
> way to notify the user that the task has been completed. We are
> looking for something simple and that will not annoy the user if they
> away doing other things.
>
> We have tried searching the forum for any similar posts, but had no
> success. Any suggestions would be greatly appreciated.

It would depend on how slow your software is.


If it takes days or weeks to complete, then it would be best if it ran
in background and offered some way to connect to it (eg. a socket),
and query its advancement and when done, its results.

Then you may write an emacs task that could connect to the background
task every five minutes or half an hour, query the advancement, and
display a percentage or a progress bar in the mode line.

When it's done, the user could invoke an emacs command to fetch the
results.

This mode of work would allow the user to close her emacs session, or
even log out, and connect a few days later to see how advanced your
process is.



If it takes only a few minutes, then you could use an emacs process
(eg. with comint), to launch the computing process, and expect the
results.  If you want, your computing process could output percentages
of advancement before outputing the results, and you would write an
emacs process filter to display the advancement as you like.




-- 
__Pascal Bourguignon__


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: What is the best way to signal the completion of a task?
  2009-07-01 13:32 Steven Shiells
@ 2009-07-01 15:26 ` Lennart Borgman
  2009-07-01 15:45 ` Steven Shiells
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 6+ messages in thread
From: Lennart Borgman @ 2009-07-01 15:26 UTC (permalink / raw)
  To: Steven Shiells; +Cc: Help-gnu-emacs

On Wed, Jul 1, 2009 at 3:32 PM, Steven Shiells<ss215@hw.ac.uk> wrote:
>
> I am part of a group who are writing some software that will be
> compatible with Emacs. Initially, the software is expected to be slow,
> and the user may wish to go and do something else. Currently, there
> are situations where there are no visible signs that the task has been
> completed. It is in these circumstances that we are unsure of the best
> way to notify the user that the task has been completed. We are
> looking for something simple and that will not annoy the user if they
> away doing other things.
>
> We have tried searching the forum for any similar posts, but had no
> success. Any suggestions would be greatly appreciated.


I think you will have to describe a bit more how the software interact
with Emacs.




^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: What is the best way to signal the completion of a task?
  2009-07-01 13:32 Steven Shiells
  2009-07-01 15:26 ` Lennart Borgman
@ 2009-07-01 15:45 ` Steven Shiells
  2009-07-02  2:31 ` Kevin Rodgers
       [not found] ` <mailman.1670.1246508165.2239.help-gnu-emacs@gnu.org>
  3 siblings, 0 replies; 6+ messages in thread
From: Steven Shiells @ 2009-07-01 15:45 UTC (permalink / raw)
  To: Help-gnu-emacs


More info about the software -- The software takes a source file, performs
some functions on the source file and in some cases highlights sections of
the source file, and others times does nothing.  The case we are worried
about is when there is no highlighting to be carried out.

Hope this helps,

Steven


Steven Shiells wrote:
> 
> I am part of a group who are writing some software that will be
> compatible with Emacs. Initially, the software is expected to be slow,
> and the user may wish to go and do something else. Currently, there
> are situations where there are no visible signs that the task has been
> completed. It is in these circumstances that we are unsure of the best
> way to notify the user that the task has been completed. We are
> looking for something simple and that will not annoy the user if they
> away doing other things.
> 
> We have tried searching the forum for any similar posts, but had no
> success. Any suggestions would be greatly appreciated.
> 
> Thanks,
> 
> Steven
> 

-- 
View this message in context: http://www.nabble.com/What-is-the-best-way-to-signal-the-completion-of-a-task--tp24289865p24292118.html
Sent from the Emacs - Help mailing list archive at Nabble.com.





^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: What is the best way to signal the completion of a task?
  2009-07-01 13:32 Steven Shiells
  2009-07-01 15:26 ` Lennart Borgman
  2009-07-01 15:45 ` Steven Shiells
@ 2009-07-02  2:31 ` Kevin Rodgers
       [not found] ` <mailman.1670.1246508165.2239.help-gnu-emacs@gnu.org>
  3 siblings, 0 replies; 6+ messages in thread
From: Kevin Rodgers @ 2009-07-02  2:31 UTC (permalink / raw)
  To: help-gnu-emacs

Steven Shiells wrote:
> I am part of a group who are writing some software that will be
> compatible with Emacs. Initially, the software is expected to be slow,
> and the user may wish to go and do something else. Currently, there
> are situations where there are no visible signs that the task has been
> completed. It is in these circumstances that we are unsure of the best
> way to notify the user that the task has been completed. We are
> looking for something simple and that will not annoy the user if they
> away doing other things.
> 
> We have tried searching the forum for any similar posts, but had no
> success. Any suggestions would be greatly appreciated.

If the task is an asynchronous Emacs subprocess, then a sentinel is the
way to go.  If the task is an operating system process, then you
probably need to use the file system to communicate its status to Emacs,
which can use a timer to check for the change.

-- 
Kevin Rodgers
Denver, Colorado, USA





^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: What is the best way to signal the completion of a task?
       [not found] ` <mailman.1670.1246508165.2239.help-gnu-emacs@gnu.org>
@ 2009-07-02  6:01   ` Anselm Helbig
  0 siblings, 0 replies; 6+ messages in thread
From: Anselm Helbig @ 2009-07-02  6:01 UTC (permalink / raw)
  To: help-gnu-emacs

At Wed, 1 Jul 2009 08:45:43 -0700 (PDT),
Steven Shiells <ss215@hw.ac.uk> wrote:
> 
> 
> More info about the software -- The software takes a source file, performs
> some functions on the source file and in some cases highlights sections of
> the source file, and others times does nothing.  The case we are worried
> about is when there is no highlighting to be carried out.

This sounds more or less like what flymake does. Maybe you should look
at how flymake does it and borrow some ideas there? 

HTH, 

Anselm


-- 
Anselm Helbig 
mailto:anselm.helbig+news2009@googlemail.com


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2009-07-02  6:01 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.1647.1246459080.2239.help-gnu-emacs@gnu.org>
2009-07-01 15:03 ` What is the best way to signal the completion of a task? Pascal J. Bourguignon
2009-07-01 13:32 Steven Shiells
2009-07-01 15:26 ` Lennart Borgman
2009-07-01 15:45 ` Steven Shiells
2009-07-02  2:31 ` Kevin Rodgers
     [not found] ` <mailman.1670.1246508165.2239.help-gnu-emacs@gnu.org>
2009-07-02  6:01   ` Anselm Helbig

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 read-only IMAP folder(s) and NNTP newsgroup(s).