Consider adding android:paddingstart= "1dip" to better support right-to-left layouts ...

Source: Internet
Author: User

Warning

<span style= "color: #FF0000;" >multiple annotations found at the line:-consider adding android:paddingstart= "1dip" to better support right-to-left< C0/>layouts-when define paddingleft You should probably also define paddingright for  right-to-left symmetry</s Pan>
The warning code is as follows
<imageview android:layout_height= "wrap_content" android:layout_width= "Wrap_content" android:contentDescription = "@null" <span style= "color: #FF0000;" >android:paddingleft= "1dip" </span>android:layout_gravity= "Center_horizontal" android:src= "@drawable/ Registered_logo_white "/>

Analysis Reason

android: Paddingstart is a the newly launched label on Android 4.2 (SDK17) Use .

If your app runs after 4.2, you can use

Android:paddingstart= "1dip"

If your app runs before 4.2 or is used in any version you can use

Android:paddingstart= "1dip" android:paddingleft= "1dip"
Otherwise it will be an error

<span style= "color: #FF0000;" >multiple annotations found at the line:-to support older versions than API (project specifies one) you should *als o* add  android:paddingleft= "1dip"-when the define Paddingstart you should probably also define paddingend for  rig Ht-to-left symmetry</span>

The overall code

<imageview android:layout_height= "wrap_content" android:layout_width= "Wrap_content" android:contentDescription = "@null" android:paddingstart= "1dip" android:paddingleft= "1dip" android:paddingright= "0dip" android:paddingend= " 0dip "android:layout_gravity=" Center_horizontal "android:src=" @drawable/registered_logo_white "/>
That's it.

Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

Consider adding android:paddingstart= "1dip" to better support right-to-left layouts ...

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.