mirror of
https://github.com/bec-project/bec_widgets.git
synced 2025-07-14 11:41:49 +02:00
fix: renamed spiral progress bar to ring progress bar; closes #235
This commit is contained in:
@ -1,9 +1,9 @@
|
||||
(user.widgets.spiral_progress_bar)=
|
||||
# [Spiral Progress Bar](/api_reference/_autosummary/bec_widgets.cli.client.SpiralProgressBar)
|
||||
# [Ring Progress Bar](/api_reference/_autosummary/bec_widgets.cli.client.RingProgressBar)
|
||||
|
||||
**Purpose:**
|
||||
|
||||
The Spiral Progress Bar widget is a circular progress bar that can be used to visualize the progress of a task. The
|
||||
The ring Progress Bar widget is a circular progress bar that can be used to visualize the progress of a task. The
|
||||
widget is designed to be used in applications where the progress of a task is represented as a percentage. The Spiral
|
||||
Progress Bar widget is a part of the BEC Widgets library and can be controlled directly using its API, or hooked up to
|
||||
the progress of a device readback or scan.
|
||||
@ -15,22 +15,22 @@ the progress of a device readback or scan.
|
||||
- multiple progress rings to show different tasks in parallel.
|
||||
|
||||
**Example of Use:**
|
||||

|
||||

|
||||
|
||||
**Code example:**
|
||||
|
||||
The following code snipped demonstrates how to create a `SpiralProgressBar` using BEC Widgets within BEC.
|
||||
The following code snipped demonstrates how to create a `RingProgressBar` using BEC Widgets within BEC.
|
||||
```python
|
||||
# adds a new dock with a spiral progress bar
|
||||
progress = gui.add_dock().add_widget("SpiralProgressBar")
|
||||
# adds a new dock with a ring progress bar
|
||||
progress = gui.add_dock().add_widget("RingProgressBar")
|
||||
# customize the size of the ring
|
||||
progress.set_line_width(20)
|
||||
```
|
||||
|
||||
By default, the Spiral Progress Bar widget will display a single ring. To add more rings, use the add_ring method:
|
||||
By default, the Ring Progress Bar widget will display a single ring. To add more rings, use the add_ring method:
|
||||
|
||||
```python
|
||||
# adds a new dock with a spiral progress bar
|
||||
# adds a new dock with a ring progress bar
|
||||
progress.add_ring()
|
||||
```
|
||||
|
||||
@ -42,7 +42,7 @@ progress.rings[0].set_line_width(20) # set the width of the first ring
|
||||
progress.rings[1].set_line_width(10) # set the width of the second ring
|
||||
```
|
||||
|
||||
By default, the `SpiralProgressBar` widget is set with `progress.enable_auto_update(True)`, which will automatically
|
||||
By default, the `RingProgressBar` widget is set with `progress.enable_auto_update(True)`, which will automatically
|
||||
update the bars in the widget. To manually set updates for each progress bar, use the set_update method. Note that
|
||||
manually updating a ring will disable the automatic update for the whole widget:
|
||||
|
@ -9,7 +9,7 @@ hidden: false
|
||||
---
|
||||
|
||||
bec_figure/
|
||||
spiral_progress_bar/
|
||||
ring_progress_bar/
|
||||
website/
|
||||
buttons/
|
||||
text_box/
|
||||
|
Reference in New Issue
Block a user