Overview     Modules     Class Hierarchy     Classes     Members  

tlp::PluginProgressWidget Class Reference

Displays the progression of a process and allow user to stop or cancel it. More...

#include <PluginProgressWidget.h>

Collaboration diagram for tlp::PluginProgressWidget:

List of all members.

Public Slots

  • void stopCompute ()
    This slot set the progress state to STOP. This will stop process, if it handle this state. See the PluginProgress class for more information.
  • void cancelCompute ()
    This slot set the progress state to CANCEL. This will cancel the process, if it handle this state. See the PluginProgress class for more information.
  • void changePreview (bool)
    Enable or disable the preview mode.
  • void setComment (std::string msg)
  • ProgressState progress (int step, int max_step)

Public Member Functions

Protected Member Functions


Detailed Description

Displays the progression of a process and allow user to stop or cancel it.

Use the stop or cancel buttons to control the process. If user give a View and if the preview check box is checked each time the progress_handler function is called the init function of the view is called. Be careful when using the preview mode as it can slow down the process.


Constructor & Destructor Documentation

tlp::PluginProgressWidget::PluginProgressWidget ( QWidget *  parent = 0  ) 
tlp::PluginProgressWidget::PluginProgressWidget ( View view,
int  updateInterval = 200,
QWidget *  parent = 0 
)

Create a PluginProgressWidget.

Parameters:
view The view to update if the preview mode is enabled. Can be NULL if you don't want to update a view.
updateInterval The minimum time interval (in msec) between two update the progress bar. Avoid to perform too many call to progressBar redraw function that can slow down the process. parent The parent widget.
tlp::PluginProgressWidget::~PluginProgressWidget (  ) 

Member Function Documentation

void tlp::PluginProgressWidget::cancelCompute (  )  [slot]

This slot set the progress state to CANCEL. This will cancel the process, if it handle this state. See the PluginProgress class for more information.

void tlp::PluginProgressWidget::changePreview ( bool   )  [slot]

Enable or disable the preview mode.

void tlp::PluginProgressWidget::preview_handler ( bool  b  )  [protected]
ProgressState tlp::PluginProgressWidget::progress ( int  step,
int  max_step 
) [slot]
void tlp::PluginProgressWidget::progress_handler ( int  i,
int  j 
) [protected]
void tlp::PluginProgressWidget::setComment ( std::string  msg  )  [slot]
void tlp::PluginProgressWidget::showPreview ( bool   ) 

Show or hide the preview check box in the widget.

void tlp::PluginProgressWidget::stopCompute (  )  [slot]

This slot set the progress state to STOP. This will stop process, if it handle this state. See the PluginProgress class for more information.



Tulip Software by LaBRI Visualization Team    2001 - 2012