User nerd font symbols for progress as they are guaranteed to exist

This commit is contained in:
Kovid Goyal 2025-01-05 08:58:29 +05:30
parent 9b9b313e77
commit d23adce11c
No known key found for this signature in database
GPG key ID: 06BC317B515ACE7C
2 changed files with 4 additions and 4 deletions

View file

@ -232,14 +232,14 @@ class TabAccessor:
if w is None:
return ''
if w.progress.state is ProgressState.error:
return '\u26a0\ufe0f '
return ' '
if w.progress.state is ProgressState.unset:
return ''
if w.progress.state is ProgressState.indeterminate:
return '🔄 '
return ' '
p = f'{w.progress.percent}% '
if w.progress.state is ProgressState.paused:
return f' {p}'
return f' {p}'
return p
@property

View file

@ -89,11 +89,11 @@ from .fast_data_types import (
wakeup_main_loop,
)
from .keys import keyboard_mode_name, mod_mask
from .progress import Progress
from .rgb import to_color
from .terminfo import get_capabilities
from .types import MouseEvent, OverlayType, WindowGeometry, ac, run_once
from .typing import BossType, ChildType, EdgeLiteral, TabType, TypedDict
from .progress import Progress
from .utils import (
color_as_int,
docs_url,