DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
Frame definition files

Using the reread descriptor

The reread descriptor in a frame definition file is used to request that a frame be reread when a checkworld is executed. One time that checkworld is executed is when a SIGALRM signal occurs (a SIGALRM occurs every MAILCHECK seconds). The frame is rebuilt if this descriptor evaluates to any value other than FALSE.

This example uses the output of the UNIX system date(1) command in the title of the menu and in the name of the first item. Recall that the menu descriptor is not re-evaluated when reread evaluates to TRUE, but the name descriptor is:

   menu="Menu `date`"
   begrow=center
   begcol=30
   reread=true
   

name="Run UNIX System V `date`" action=unix-system

name="Find Modified Files" action=`find $HOME -mtime -7 -print > modfiles`nop

name="Find Executable Files" action=`find $HOME -perm -100 -print > execfiles`nop

name="Exit My Application" action=exit

Menu.reread: an example of a dynamically updated menu

This menu definition file creates the following menu:

Menu.reread: screen output

After a SIGALRM occurs (for example, if MAILCHECK=180 and 3 minutes have elapsed), the date in the name of the first item changes but the date in the menu's title does not change. The menu now looks like this:

Menu.reread: screen output after a SIGALRM occurs


Next topic: Using the interrupt and oninterrupt descriptors
Previous topic: Menu.columns: screen output

© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 27 April 2004