Skip to content

Conversation

@maxkatz6
Copy link
Member

@maxkatz6 maxkatz6 commented Nov 20, 2025

What does the pull request do?

public interface IPlatformSettings
{
+        /// <summary>
+        /// Gets the preferred application language as specified in the operating system settings.
+        /// </summary>
+        string PreferredApplicationLanguage { get; }

+        /// <summary>
+        /// Raises when the preferred application language is changed in the operating system settings.
+        /// </summary>
+        event EventHandler? PreferredApplicationLanguageChanged;
}

Status

  • Default - fallbacks to CultureInfo.CurrentUICulture.Name, not sure if it's ideal
  • Windows - GetUserDefaultLocaleName
  • Browser - navigator.language
  • macOS
  • Linux (is LANG/LC_MESSAGES env variable is the only option really? there is a GTK specific API though...)
  • iOS
  • Android

Checklist

Fixed issues

Partially implements #19402

@maxkatz6 maxkatz6 added feature api-approved The new public APIs have been approved. labels Nov 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api-approved The new public APIs have been approved. feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants