开发者

Dynamically update Font Size of application with a single trigger in WPF

I h开发者_C百科ave an application which has different font sizes for different controls say Button: 10, TextBlock : 12 etc. I want to give options to the user where he can select any one of the below say Normal , Small, Big, Bigger.

Suppose one selects "small" I would want to decrease every distinct font size by 2. If "Big", I would want to increase every font size by 2. I hope we can do this using converter sending actual font size as parameter and render as per the selected choice if I am not wrong. What will be the best option. Sorry if my doubt is absurd or silly. Thank you.


If you don't mind scaling graphics as well as text, you can use a transform to scale the content for the main portion of your app as described here. If you have a status bar in your app, that might be a good place for the zoom slider.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜