From b79ce5833803e55724544f089f33b3457e2d5b97 Mon Sep 17 00:00:00 2001 From: lashman Date: Fri, 6 Mar 2026 13:53:32 +0200 Subject: [PATCH] Add accessible value updates to processing progress bar Screen readers now announce progress bar value with descriptive text like "Processing 5 of 47: sunset.jpg" during batch processing, instead of just reporting the fraction. --- pixstrip-gtk/src/app.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/pixstrip-gtk/src/app.rs b/pixstrip-gtk/src/app.rs index 526ad58..2d8992f 100644 --- a/pixstrip-gtk/src/app.rs +++ b/pixstrip-gtk/src/app.rs @@ -1258,8 +1258,15 @@ fn run_processing(_window: &adw::ApplicationWindow, ui: &WizardUi) { file, } => { if let Some(ref bar) = progress_bar { - bar.set_fraction(current as f64 / total as f64); + let frac = current as f64 / total as f64; + bar.set_fraction(frac); bar.set_text(Some(&format!("{}/{} - {}", current, total, file))); + bar.update_property(&[ + gtk::accessible::Property::ValueNow(frac * 100.0), + gtk::accessible::Property::ValueText( + &format!("Processing {} of {}: {}", current, total, file) + ), + ]); } let eta = calculate_eta(&start_time, current, total); update_progress_labels(&ui_for_rx.nav_view, current, total, &file, &eta);