NAME

Tk::MacProgressBar - a blue, 3-D Macintosh progress bar.

SYNOPSIS

$pb = $parent->MacProgressBar(-option => value);

DESCRIPTION

This widget provides a dynamic image that looks just like a Mac OS 9 progress bar. Packed around it are four Frames, north, south, east and west, within which you can stuff additional widgets. For example, see how MacCopy uses several Labels and a CollapsableFrame widget to create a reasonable facsimile of a Macintosh copy dialog.

The following option/value pairs are supported:

-width

The maximun width of the MacProgressbar.

METHODS

set($percent)

Sets the width of the progress bar, as a percentage of -width.

ADVERTISED WIDGETS

Component subwidgets can be accessed via the Subwidget method. Valid subwidget names are listed below.

Name: label, Class: Label
Widget reference of the Label containing the MacProgressBar
Photo image.
Name: tframe, Class: Frame
Widget reference of the Frame north the MacProgressBar.
Name: bframe, Class: Frame
Widget reference of the Frame south the MacProgressBar.
Name: lframe, Class: Frame
Widget reference of the Frame west the MacProgressBar.
Name: rframe, Class: Frame
Widget reference of the Frame east the MacProgressBar.

EXAMPLE

use Tk;
use Tk::MacProgressBar;
use strict;

my $mw = MainWindow->new;
my $pb = $mw->MacProgressBar(-width => 150, -bg => 'cyan')->pack;

while (1) {
    my $w = rand(100);
    $pb->set($w);
    $mw->idletasks;
    $mw->after(250);
}

AUTHOR and COPYRIGHT

Stephen.O.Lidie@Lehigh.EDU

Copyright (C) 2000 - 2002, Stephen O.Lidie.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

KEYWORDS

MacProgressBar