dotnet / dotnet/wpf

Localization of WPF standard components

Open
#3,863 3 comments 3 reactions 1 assignee Claimed by @ryalanms View on GitHub
Bug Investigate
Dominant language
C#
Stars
7.7k
Forks
1.3k
Avg merge
1d 11h
Merged PRs (30d)
61

Description

* .NET Core Version: 3.1.9
* Windows version: Windows 10 1909 (18363.1198)
* Does the bug reproduce also in WPF for .NET Framework 4.8?: No

**Problem description:**
Wpf standard components in net Core does not respect CurrentCulture(or CurrentUICulture) while in net48 does.
**Actual behavior:**
Created WPF appliaction add i.e. FlowDocumentReader with some Document with data. Set CultureInfo on thread or Language on framework element to desired culture. In my example "cs-CZ". Then when you try mouse over find button, there is tooltip in English not localized. Same behaviour on other components in FlowDocumentReader. Same goes for watermarks etc
When you try the same in net48 everything works.
**Expected behavior:**
All resources will be localized. I.e. "Find" should be "Najít"
Same behaviour as in net48
**Minimal repro:**
I created sample to demonstrate it. To see correct behaviour switch order of TargetFrameworks in csproj so net48 is first. Incorrect behaviour will show when order of TargetFrameworks is netcoreapp3.1 is on the first place.
https://github.com/duchacekjan/NetCoreComponentsLocalization

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.