class KProgressDialog

# class KProgressDialog | A dialog with a progress bar. More...
Definition | `#include <kprogress.h>`
Inherits | KDialogBase [public ]
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

#### Public Methods

- KProgressDialog (QWidget* parent = 0, const char* name = 0, const QString& caption = QString::null, const QString& text = QString::null, bool modal = false)
- ~KProgressDialog ()
- KProgress* progressBar ()
- void setLabel (const QString&)
- QString labelText ()
- void setAllowCancel (bool allowCancel)
- bool allowCancel ()
- void showCancelButton (bool show)
- void setAutoClose (bool close)
- bool autoClose ()
- void setAutoReset (bool autoReset)
- bool autoReset ()
- bool wasCancelled ()
- void setButtonText (const QString&)
- QString buttonText ()
- void setMinimumDuration (int ms)
- int minimumDuration ()

#### Protected Methods

- virtual void virtual_hook ( int id, void* data )

#### Protected Slots

- void slotAutoShow ()
- void slotAutoActions (int percentage)
- void slotCancel ()

## Detailed Description

KProgressDialog provides a dialog with a text label, a progress bar and an optional cancel button with a KDE look 'n feel.

Since knowing how long it can take to complete an action and it is undesireable to show a dialog for a split second before hiding it, there are a few ways to control the timing behavior of KProgressDialog. There is a time out that can be set before showing the dialog as well as an option to autohide or keep displaying the dialog once complete.

All the functionality of KProgress is available through direct access to the progress bar widget via progressBar();

KProgressDialog (QWidget* parent = 0, const char* name = 0, const QString& caption = QString::null, const QString& text = QString::null, bool modal = false) | ### KProgressDialog

Constructs a KProgressDialog

Parameters:

parent | Parent of the widget
name | Widget name
caption | Text to display in window title bar
text | Text to display in the dialog
modal | Set to true to make the dialog modal

~KProgressDialog () | ### ~KProgressDialog

Desctructor

KProgress* progressBar () | ### progressBar

Returns the KProgress used in this dialog. To set the number of steps or other progress bar related settings, access the KProgress object directly via this method.

void setLabel (const QString&) | ### setLabel

Sets the text in the dialog

Parameters:

text | the text to display

QString labelText () | ### labelText

Returns the current dialog text

void setAllowCancel (bool allowCancel) | ### setAllowCancel

Sets whether or not the user can cancel the process. If the dialog is cancellable, the Cancel button will be shown and the user can close the window using the window decorations. If the process is not (or should not be) interuptable, set the dialog to be modal and not cancellable.

Parameters:

allowCancel | Set to true to make the dialog non-closable

bool allowCancel () | ### allowCancel

Returns true if the dialog can be cancelled, false otherwise

void showCancelButton (bool show) | ### showCancelButton

Sets whether the cancel button is visible. setAllowCancel(false) implies showCancelButton(false)

Parameters:

show | Whether or not the cancel button should be shown

void setAutoClose (bool close) | ### setAutoClose

Sets whether the dialog should close automagically when all the steps in the KProgress have been completed.

bool autoClose () | ### autoClose

Returns true if the dialog will close upon completion, or false otherwise

void setAutoReset (bool autoReset) | ### setAutoReset

Sets whether the dialog should reset the KProgress dialog back to 0 steps compelete when all steps have been completed. This is useful for KProgressDialogs that will be reused.

bool autoReset () | ### autoReset

Returns true if the KProgress widget will be reset upon completion, or false otherwise

bool wasCancelled () | ### wasCancelled

Returns true if the dialog was closed or cancelled before completion. If the dialog is not cancellable it will always return false.

void setButtonText (const QString&) | ### setButtonText

Sets the text to appear on the cancel button.

Reimplemented from KDialogBase.

QString buttonText () | ### buttonText

Returns the text on the cancel button

void setMinimumDuration (int ms) | ### setMinimumDuration

Set the minimum number of milliseconds to wait before actually showing the dialog

int minimumDuration () | ### minimumDuration

Returns the wait duration in milliseconds

void slotAutoShow () | ### slotAutoShow

[protected slots slot]

void slotAutoActions (int percentage) | ### slotAutoActions

[protected slots slot]

void slotCancel () | ### slotCancel

[protected slots slot]

Reimplemented from KDialogBase.

void virtual_hook ( int id, void* data ) | ### virtual_hook

[protected virtual]

Reimplemented from KDialogBase.

- Author: Aaron J. Seigo
- Generated: root on macppc.ports.openbsd.org on Sat Sep 6 10:36:37 2003, using kdoc 2.0a54.