【问题标题】:Change font size based on Accessibility Settings in Appcelerator Studio根据 Appcelerator Studio 中的辅助功能设置更改字体大小
【发布时间】:2017-06-19 07:51:16
【问题描述】:

我正在开发适用于 Android 和 iPhone 的 Titanium 应用程序。我的目标是在我们从辅助功能设置更改字体大小时更改整个应用程序的字体大小。 (设置->通用->辅助功能->大文本->设置最大尺寸)

目前字体大小的变化只反映在 AlertDialog 中。我想对标签、按钮、列表视图等所有元素进行更改。

在 android 中,当我从辅助功能设置字体大小时,字体大小会反映出来。

您能否为此提出任何解决方案!

谢谢!!

【问题讨论】:

  • 有人知道吗?

标签: titanium accessibility appcelerator appcelerator-titanium appcelerator-mobile


【解决方案1】:

尝试在sp中使用字体大小(与比例无关的像素)

"#myLabel": {
    font: {
         fontSize: '14sp'
    }
}

这样就可以了

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-08-21
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多