From 4ace5b782e3ac1041f49a297d5817d0e2fc62139 Mon Sep 17 00:00:00 2001 From: lindexi Date: Wed, 2 Sep 2026 09:25:30 +0000 Subject: [PATCH] Fix the avalonia scale in x11 (#22129) --- src/Avalonia.X11/Screens/X11Screens.Scaling.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Avalonia.X11/Screens/X11Screens.Scaling.cs b/src/Avalonia.X11/Screens/X11Screens.Scaling.cs index 3398580750..550f3a2f47 100644 --- a/src/Avalonia.X11/Screens/X11Screens.Scaling.cs +++ b/src/Avalonia.X11/Screens/X11Screens.Scaling.cs @@ -1,4 +1,4 @@ -using System; +using System; using System.Collections.Generic; using System.Globalization; using System.Linq; @@ -132,7 +132,7 @@ internal partial class X11Screens { if (_indexedConfig != null) { - if (index > 0 && index < _indexedConfig.Count) + if (index >= 0 && index < _indexedConfig.Count) return _indexedConfig[index]; return 1; }