Set TextFormattingMode for GlyphRun
- Dominant language
- C#
- Stars
- 7.7k
- Forks
- 1.3k
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 61
Description
Is there any reason why `TextFormattingMode` is fixed to `Ideal` for `GlyphRun`s?
I need it to be `Display` and the only current way to do that is setting `_textFormattingMode` through reflection.
I suggest adding a public property that is settable only during initialization like all the others:
```C#
public TextFormattingMode TextFormattingMode
{
get
{
CheckInitialized();
return _textFormattingMode;
}
set
{
CheckInitializing(); // This can only be set during initialization.
_textFormattingMode = value;
}
}
```
Another option would be making `GlyphRun.TryCreate` method public.
https://github.com/dotnet/wpf/blob/master/src/Microsoft.DotNet.Wpf/src/PresentationCore/System/Windows/Media/GlyphRun.cs
Contributor guide
Assessment
This issue has not been assessed yet.