CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Static Private Attributes
progressbar.Timer Class Reference
Inheritance diagram for progressbar.Timer:
progressbar.Widget progressbar.FormatLabel

Public Member Functions

def __init__ (self, format='Elapsed Time:%s')
 
def update (self, pbar)
 
- Public Member Functions inherited from progressbar.Widget
def update (self, pbar)
 

Static Public Member Functions

def format_time (seconds)
 

Public Attributes

 format
 

Static Public Attributes

 TIME_SENSITIVE
 
- Static Public Attributes inherited from progressbar.Widget
 TIME_SENSITIVE
 

Static Private Attributes

 __slots__
 

Detailed Description

Definition at line 37 of file progressbar.py.

Constructor & Destructor Documentation

def progressbar.Timer.__init__ (   self,
  format = 'Elapsed Time: %s' 
)

Definition at line 43 of file progressbar.py.

43  def __init__(self, format='Elapsed Time: %s'):
44  self.format = format
45 
def __init__(self, format='Elapsed Time:%s')
Definition: progressbar.py:43

Member Function Documentation

def progressbar.Timer.format_time (   seconds)
static

Definition at line 47 of file progressbar.py.

References createfilelist.int, and str.

Referenced by progressbar.Timer.update().

47  def format_time(seconds):
48  'Formats time as the string "HH:MM:SS".'
49 
50  return str(datetime.timedelta(seconds=int(seconds)))
51 
52 
def format_time(seconds)
Definition: progressbar.py:47
#define str(s)
def progressbar.Timer.update (   self,
  pbar 
)

Definition at line 53 of file progressbar.py.

References Formatter.SimpleAsciiFormatter.format, progressbar.Timer.format, Formatter.SimpleHTMLFormatter.format, and progressbar.Timer.format_time().

Referenced by progressbar.ProgressBar.__next__(), MatrixUtil.Matrix.__setitem__(), MatrixUtil.Steps.__setitem__(), Vispa.Gui.VispaWidget.VispaWidget.autosize(), Vispa.Views.LineDecayView.LineDecayContainer.createObject(), Vispa.Views.LineDecayView.LineDecayContainer.deselectAllObjects(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner.deselectAllWidgets(), Vispa.Gui.VispaWidget.VispaWidget.enableAutosizing(), progressbar.ProgressBar.finish(), Vispa.Gui.MenuWidget.MenuWidget.leaveEvent(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner.mouseMoveEvent(), Vispa.Gui.MenuWidget.MenuWidget.mouseMoveEvent(), Vispa.Views.LineDecayView.LineDecayContainer.mouseMoveEvent(), Vispa.Gui.VispaWidgetOwner.VispaWidgetOwner.mouseReleaseEvent(), Vispa.Views.LineDecayView.LineDecayContainer.objectMoved(), MatrixUtil.Steps.overwrite(), Vispa.Views.LineDecayView.LineDecayContainer.removeObject(), Vispa.Gui.ConnectableWidget.ConnectableWidget.removePorts(), Vispa.Gui.FindDialog.FindDialog.reset(), Vispa.Gui.PortConnection.PointToPointConnection.select(), Vispa.Gui.VispaWidget.VispaWidget.select(), Vispa.Views.LineDecayView.LineDecayContainer.select(), Vispa.Gui.VispaWidget.VispaWidget.setText(), Vispa.Gui.VispaWidget.VispaWidget.setTitle(), Vispa.Gui.ZoomableWidget.ZoomableWidget.setZoom(), Vispa.Views.LineDecayView.LineDecayContainer.setZoom(), and Vispa.Gui.PortConnection.PointToPointConnection.updateConnection().

53  def update(self, pbar):
54  'Updates the widget to show the elapsed time.'
55 
56  return self.format % self.format_time(pbar.seconds_elapsed)
def update(self, pbar)
Definition: progressbar.py:53
def format_time(seconds)
Definition: progressbar.py:47

Member Data Documentation

progressbar.Timer.__slots__
staticprivate

Definition at line 40 of file progressbar.py.

progressbar.Timer.format
progressbar.Timer.TIME_SENSITIVE
static

Definition at line 41 of file progressbar.py.