本文介绍了如何忽略“易于访问"Windows Phone 上的设置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

限时删除!!

Windows Phone 上的轻松访问"设置类别中有文本大小"和高对比度"设置.有没有办法忽略它们或让应用遵循我自己的无障碍风格?

There are 'TextSize' and 'High contrast' settings in 'ease of access' settings category on Windows Phone. Is there a way to ignore them or make an app to follow my own accessibility styles?

推荐答案

应用程序中的一个常见错误是它们忽略高对比度设置并硬编码自己的颜色.所以是的:您可以通过做错误的事情并硬编码您的设置而不是使用系统资源来做到这一点.您可以在 app.xaml 的应用程序资源中覆盖大多数系统画笔,并且可以在 Xaml 和控件样式中对颜色进行硬编码.

It's a common bug in apps that they ignore the high contrast settings and hardcode their own colours. So yes: you can do this by doing the wrong thing and hardcoding your settings instead of using the system resources. You can override most system brushes in your app resources in app.xaml and you can hardcode colours in your Xaml and control styles.

也就是说,请将此用于善而不是恶.人们选择这些选项是因为他们需要它们.使用 HighContrast 字典确保您的非标准样式遵循用户的高对比度主题请求,而不是避免它:

That said, please use this for good not evil. People choose these options because they need them. Use the HighContrast dictionary to make sure your non-standard styles follow the users high contrast theme request rather than to avoid it:

<ResourceDictionary.ThemeDictionaries>
    <ResourceDictionary x:Key="Default">
        <ImageBrush x:Key="PageBackground" Stretch="Fill" ImageSource="Assets/owlvcrow.jpg"/>
    </ResourceDictionary>
    <ResourceDictionary x:Key="HighContrast">
        <SolidColorBrush x:Key="PageBackground" Color="{ThemeResource SystemColorWindowColor}" />
    </ResourceDictionary>
</ResourceDictionary.ThemeDictionaries>

这篇关于如何忽略“易于访问"Windows Phone 上的设置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

1403页,肝出来的..

09-07 01:19