XmProgressMeter(3Xm)

NAME
XmProgressMeter - The Progress Meter widget class

SYNOPSIS
#include <ProgressMeter.h>

Depending on your system's configuration the place of this include file may vary.

DESCRIPTION
The ProgressMeter widget may be used to chart the completion of a task. A ProgressMeter has an elongated rectangular region similar to a ScrollBar. A ProgressMeter can be output only and therefore only be set by the application.

  Classes
ProgressMeter inherits behaviour and resources from Core and Primitive classes.

The class pointer is xmProgressMeterWidgetClass.

The class name is XmProgressMeter.

  New Resources
The following table defines a set of widget resources used by the programmer to specify data. The programmer can also set the resource values for the inherited classes to set attributes for this widget. To reference a resource by name or by class in a .Xdefaults file, remove the XmN or XmC prefix and use the remaining letters. To specify one of the defined values for a resource in a .Xdefaults file, remove the Xm prefix and use the remaining letters (in either lowercase or uppercase, but include any underscores between words). The codes in the access column indicate if the given resource can be set at creation time (C), set by using XtSetValues (S), retrieved by using XtGetValues (G), or is not applicable (N/A).

XmProgressMeter Resource Set
Name | Default | Access
Class | Type
XmNboxMode | FALSE | CSG
XmCBoxMode | Boolean
XmNfontList | dynamic | CSG
XmCFontList | XmFontList
XmNmaximum | 100 | CSG
XmCValue | int
XmNminimum | 0 | CSG
XmCValue | int
XmNnumBoxes | 10 | CSG
XmCValue | int
XmNorientation | XmHORIZONTAL | CSG
XmCOrientation | unsigned char
XmNshowBoxSeparators | TRUE | CSG
XmCShowBoxSeparators | Boolean
XmNshowPercentage | TRUE | CSG
XmCShowPercentage | Boolean
XmNshowTime | FALSE | CSG
XmCShowTime | Boolean
XmNshowTimeUnit | TRUE | CSG
XmCShowTimeUnit | Boolean
XmNvalue | 50 | CSG
XmCValue | int

XmNboxMode
    Specifies the style of the progress meter widget. If this value is FALSE then the style will be a traditional percentage meter. If this value is TRUE then the style will be like the progress meter in Microsoft's new program versions (eg. WinWord 6.0).

XmNfontList
    Specifies the font list to use for the percentage label when XmNshowPercentage is TRUE and for the time labels when XmNshowTime is TRUE. If this value is NULL at initialization, the font list is initialized by looking up the parent hierarchy of the widget for an ancestor that is a subclass of XmBulletinBoard, XmVendorShell or XmMenuShell widget class. If such an ancestor is found, the font list is initialized to the XmNlabelFontList of the ancestor widget. If no such ancestor is found, the default is implementation dependent. Refer to XmFontList(3Xm) for more information on the creation and structure of a font list.

XmNmaximum
    Specifies the progress meter's maximum value. XmNmaximum must be greater then XmNminimum.

XmNminimum
    Specifies the progress meter's minimum value. XmNmaximum must be greater than XmNminimum.

XmNnumBoxes
    Specifies the number of boxes the progress meter should contain if XmNboxMode is TRUE. This value is adapted such that the minimum box width (horizontal layout) or height (vertical layout) is at least 5 pixels.

XmNorientation
    Displays the progress meter vertically or horizontally. This resource can have values of XmVERTICAL and XmHORIZONTAL.

XmNshowBoxSeparators
    If this resource is TRUE and XmNboxMode is TRUE then the progress meter will have shaded separators drawn in the background color between the boxes.

XmNshowPercentage
    Specifies whether a percentage label for the current progress meter value should be displayed centered in the middle of the progress meter. If the value is TRUE, the current progress meter value is displayed.

XmNshowTime
    If this resource is TRUE then the passed time is displayed at the lower end of the progress meter widget and the estimated remaining time is displayed at the higher end of the progress meter widget with the font specified by XmNfontList.

XmNshowTimeUnit
    If XmNshowTime has the value FALSE, this resource does not have any effects. Otherwise if XmNshowTimeUnit has the value TRUE, the passed time and estimated remaining time labels are displayed like this: 15 sec or 2:47 min. If this resource is FALSE, the passed time and estimated remaining time labels are displayed always like this: mm:ss where mm specifies the minutes and ss the seconds. All the times are calculated automatically by the widget.

XmNvalue
    Specifies the progress meter's current position between XmNminimum and XmNmaximum. The value is constrained to be within these inclusive bounds. The initial value of this resource is 50.

  Inherited Resources
XmProgressMeter inherits behaviour and resources from the following superclasses. For a complete description of each resource, refer to the man page for that superclass.
THIS REST OF THIS INFORMATION HERE IS STILL MISSING !

  Callback Information
A pointer to the following structure is passed to each callback:

typedef struct {
    int    reason;
    XEvent    * event;
    int    value;
} XmProgressMeterCallbackStruct;

reason
    Indicates the reason why the callback was invoked.

event
    Points to the XEvent, that triggered the callback.

value
    Is the new progress meter value.

BUGS
No bugs yet found. Report bugs to mperzl@gsf.de. Please include a detailed description and state which version of the ProgressMeter widget you are using.

COPYRIGHT
Copyright (c) 1996 Michael A. Perzl.
All rights reserved.

Permission to use, copy, modify, distribute, and sell this software and its documentation for any purpose is hereby granted without fee, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of Michael A. Perzl not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. Michael A. Perzl makes no representations about the suitability of this software for any purpose. It is provided "as is" without any express or implied warranties, including, without limitation, the implied warranties of merchantability and fitness for a particular purpose.

Michael A. Perzl DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL Michael A. Perzl BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

AVAILABILITY
The most recent released version of the progress meter widget is always available for anonymous ftp from

    ftp.gsf.de (146.107.1.2)
    /pub/mperzl

It will also be available (hopefully pretty soon) at

    ftp.x.org (198.112.44.100)
    /contrib/widgets/motif/ProgressMeter

or from any mirror sites of ftp.x.org.

AUTHOR
Michael A. Perzl
Institute of Radiation Protection
GSF-National Research Center for Environment and Health
Germany
E-Mail: mperzl@gsf.de

RELATED INFORMATION
Core(3Xm), XmPrimitive(3Xm), XmCreateProgressMeter(3Xm), XmProgressMeterSetValue(3Xm) and XmProgressMeterGetValue(3Xm).