In .NET Framework 4.6.2 the FormattedText() is Obsoleted, how can I fix it

asked9 years ago
last updated5 years ago
viewed9.5k times
Up Vote20Down Vote

When I try to build the WPF project with .net framework 4.6.2, I got an error, Because the FormattedText() is Obsoleted as below:

The new override method is

Q: How can I determine the pixelsPerDip ?

Q: How can I use old constructor without pixelsPerDip?, because the pixelsPerDip is useless for my project.