在Androidmanifest中警告android:supportsRtl

在Androidmanifest中警告android:supportsRtl,第1张

概述我正在使用android:minSdkVersion=“12”和android:targetSdkVersion=“21”开发android应用程序.在清单文件中,我看到一个警告:“该项目引用了RTL属性,但未在android:supportsRtl中显式启用或禁用RTL支持 清单“.这实际上是什么意思.我只是通过链接http://developer.android.com

我正在使用android:minSdkVersion =“ 12”和androID:targetSdkVersion =“ 21”开发androID应用程序.在清单文件中,我看到一个警告:“该项目引用了RTL属性,但未在androID:supportsRtl中显式启用或禁用RTL支持
 清单“.这实际上是什么意思.我只是通过链接http://developer.android.com/guide/topics/manifest/application-element.html.But并没有对该问题有太多的了解.以下是我在xml中用于一个视图的代码.

<EditText        androID:ID="@+ID/terminal_ID_edit_text"        androID:layout_wIDth="fill_parent"        androID:layout_height="@dimen/edit_text_height"        androID:layout_marginEnd="@dimen/edit_text_right_margin"        androID:layout_marginleft="@dimen/edit_text_left_margin"        androID:layout_marginRight="@dimen/edit_text_right_margin"        androID:layout_marginStart="@dimen/edit_text_left_margin"        androID:background="@drawable/editetxt_bg"        androID:inputType="text"        androID:hint="@string/terminal_ID_text"         androID:maxLength="8"        androID:nextFocusDown="@+ID/clIEnt_ID_edit_text"        androID:paddingleft="@dimen/edit_text_padding"        androID:paddingRight="@dimen/edit_text_padding"        androID:singleline="true"        androID:textcolor="@color/color_white"        androID:textCursorDrawable="@null"        androID:textSize="@dimen/normal_text_size" />`

解决方法:

androID:supportsRtl
声明您的应用程序是否愿意支持从右到左(RTL)布局.
如果设置为true且targetSdkVersion设置为17或更高,系统将激活并使用各种RTL API,以便您的应用可以显示RTL布局.如果设置为false或targetSdkVersion设置为16或更低,则RTL API将被忽略或无效,并且无论与用户的区域设置选择相关的布局方向如何,您的应用程序的行为都一样(您的布局将始终保留-至右).
此属性的默认值为false.
此属性是在API级别17中添加的.

更多:android:supportsRtl

总结

以上是内存溢出为你收集整理的在Androidmanifest中警告android:supportsRtl全部内容,希望文章能够帮你解决在Androidmanifest中警告android:supportsRtl所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址: https://outofmemory.cn/web/1079169.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-27
下一篇 2022-05-27

发表评论

登录后才能评论

评论列表(0条)

保存