TUIX v0.6Beta
Progress Bar Widget (`content_builder.PROGRESS_BAR`)
ProgressBar renders a horizontal fill bar representing a float value in the 0.0 to 1.0 range. It supports customizable fill/empty glyphs, full RGB color palettes, and optional numerical percentage overlays.
| Method | Description |
|---|---|
| objects.tuix_progressbar_set_value(obj_ptr, value: float) -> int | Sets the progress value (clamped to 0.0 .. 1.0). |
| objects.tuix_progressbar_get_value(obj_ptr) -> float | Returns current float progress value. |
| objects.tuix_progressbar_set_style(obj_ptr, fill, empty, fr, fg, fb, er, eg, eb) -> int | Sets fill character, empty character, filled RGB color, and empty background RGB color. |
| objects.tuix_progressbar_show_percentage(obj_ptr, show: bool = True) -> int | Enables or disables centered percentage overlay text. |
from tuix.core import object as objects, content_builder
uid = objects.create_object(content_builder.PROGRESS_BAR, b'Main', 0.6, 0.08, 0.1, 0.2)
bar = objects.get_object_by_uid(uid)
objects.tuix_progressbar_set_value(bar, 0.75)
objects.tuix_progressbar_set_style(bar, '#', '-', 120, 220, 80, 50, 50, 50)
objects.tuix_progressbar_show_percentage(bar, True)