Ana*_*d.B 8 xml eclipse android adt
我最近下载了一个新的ADT.每次保存我的项目后,它都会显示以下XML错误.但是当我清理它时,同样会消失.有没有永久的解决方案.
提前致谢.
<TextView
android:id="@+id/selectquantityprompt"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="2dip"
android:layout_marginRight="50dip"
android:layout_marginTop="2dip"
android:text="Select Quantity"
android:textSize="20sp"
android:textColor="#33b5e5"
android:paddingLeft="25dp" //error at this line
android:paddingTop="5dp"
android:paddingBottom="5dp"
/>
Run Code Online (Sandbox Code Playgroud)
在此行找到多个注释:
- Consider adding android:paddingStart="25dp" to better support right-to-left layouts
- When you define %1$s you should probably also define %2$s for right-to-left
Run Code Online (Sandbox Code Playgroud)
Yas*_*tel 14
android:paddingStart是android 4.2以后新引入的标签.
现在,RTL意味着从右到左的布局,这些布局在RTL语言中使用,如阿拉伯语.
因此,在开发布局时,您可以向paddingStart添加相同的值作为左边的填充.因此,当android渲染RTL布局时,它会考虑paddingStart.
参考链接:RTL布局支持
开发人员博客:Android 4.2中的Native RTL支持
| 归档时间: |
|
| 查看次数: |
11683 次 |
| 最近记录: |