fix: a screen reader reads a slider as the value shown beside it

NVDA read a slider's bare number as a share of its length, so -5 °C was 45 and
the fog was where the knob stood on its scale. Sliders now give the text shown
next to them: the weather's temperature and visibility, and every setting row.
This commit is contained in:
maj00r
2026-11-15 17:59:04 +01:00
parent 5883376762
commit a0a6ebdffa
8 changed files with 175 additions and 32 deletions

View File

@@ -762,6 +762,8 @@ public partial class Scenarios : UserControl
{
weatherTempLabel.Text = $"{(int)weatherTemp.Value} °C";
weatherFogLabel.Text = FogScale2(FogScale.ToMetres(weatherFog.Value));
weatherTemp.ValueText = weatherTempLabel.Text;
weatherFog.ValueText = weatherFogLabel.Text;
weatherDayDate.Text = string.Format(LanguageCulture, App.Loc["DayOfYear"], SelectedDayOfYear());
weatherRestore.IsEnabled = _currentScenery?.Weather.Changed ?? false;