msticpy.nbwidgets.progress module

Module for pre-defined widget layouts.

class msticpy.nbwidgets.progress.Progress(completed_len: int, visible: bool = True)

Bases: IPyDisplayMixin

UI Progress bar.

Instantiate new _Progress UI.

Parameters:
  • completed_len (int) – The expected value that indicates 100% done.

  • visible (bool) – If True start the progress UI visible, by default True.

display()

Display the interactive widgets.

hide()

Hide the controls.

property max: int

Return the current progress maximum value.

Returns:

Max value

Return type:

int

show()

Make the controls visible.

update_progress(new_total: int = 0, delta: int = 0)

Update progress UI by increment or new total.

Parameters:
  • new_total (int, optional) – New total, by default 0

  • delta (int, optional) – Increment to update current total, by default 0

property value: int

Return the current progress value.

Returns:

Progess value

Return type:

int