diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2005-01-19 23:47:35 +0000 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2005-01-19 23:47:35 +0000 |
commit | f0d3d9feb068b5bff633efaf355c31706caaa94f (patch) | |
tree | 18751e91ef37b123411efe3245da09a6dc902f74 /lispref/display.texi | |
parent | 7c018923b03fb5907df95a72336ca535f1f6b4e0 (diff) | |
download | emacs-f0d3d9feb068b5bff633efaf355c31706caaa94f.tar.gz |
Add dotimes-with-progress-reporter.
Diffstat (limited to 'lispref/display.texi')
-rw-r--r-- | lispref/display.texi | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/lispref/display.texi b/lispref/display.texi index 375db424122..f24432615e4 100644 --- a/lispref/display.texi +++ b/lispref/display.texi @@ -1,7 +1,7 @@ @c -*-texinfo-*- @c This is part of the GNU Emacs Lisp Reference Manual. -@c Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1998, 1999, 2000, 2001, 2002 -@c Free Software Foundation, Inc. +@c Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1998, 1999, 2000, 2001, +@c 2002, 2005 Free Software Foundation, Inc. @c See the file elisp.texi for copying conditions. @setfilename ../info/display @node Display, Calendar, Processes, Top @@ -633,6 +633,22 @@ never print it, there are many good reasons for this not to happen. Secondly, ``done'' is more explicit. @end defun +@defmac dotimes-with-progress-reporter (var count [result]) message body... +This is a convenience macro that works the same way as @code{dotimes} +does, but also reports loop progress using the functions described +above. It allows you to save some typing. + +You can rewrite the example in the beginning of this node using +this macro this way: + +@example +(dotimes-with-progress-reporter + (k 500) + "Collecting some mana for Emacs..." + (sit-for 0.01)) +@end example +@end defmac + @node Invisible Text @section Invisible Text |