Android drawable Resource Induction

Source: Internet
Author: User

Android drawable Resource Induction

Clipdrawable represents a "picture fragment" from another bitmap (other animated XML resources are placed under the/res/drawable/path)
Clip label, <clip/>

        animationdrawable, including motion tweens and frames-per-frame animations
//XML resource files that define tweened animations to <set The .../> element acts as the root element within which you can specify four child elements, define the Tween animation XML resource to be placed under the/res/anmi path, interpolator, "interpolate", the way the animation transitions
 <set>    //Motion Tween XML resource file
   <alpha/>//transparency
   <scale/>//size
   <translate/> position
   <rotate/> rotate
  </set>

Animate the XML resource file by frame to <animation_list. The/> element is defined as the root element, and the frame-wise animation XML resource file is placed under the res/drawable/path
<animation_list>
<item/>
<item/>
....
<animation_list>
Animationdrawable including scaledrawable,rotatedrawable
Scaledrawable is a scaling operation on a drawable that can control the zoom ratio of the drawable based on the level property, or set the alignment of his in the container. The XML resource file uses scale as the root node to create the rotatedrawable.
<scale.../>
Rotatedrawable is a rotation operation on a drawable that controls the rotation of the drawable based on the level property, and also sets the alignment relative to the container in which he is located. Use rotate as the root node in the XML resource file to define the rotatedrawable.
<rotate.../>

Layerdrawable drawable Array (layer overlay effect)
<layer_list/>

Shapedrawable (gradientdrawable) defines a basic geometry with an XML resource file
<shape xmls:android= "http://schemas.android....>
Android:shape= ""//Select Geometry shape
<corners/>
<size/>
<gradient/>
<padding/>
<soild/>
<stroke/>
</shape>


The Drawable object displayed by the Statelistdrawable object automatically switches as the target component state changes
ANDROID:STATE_XXX: Specify a specific state


Bitmapdrawable
Use bitmap as the root node in the XML resource file to define the bitmapdrawable.
Using bitmap as a child node and other parent nodes in the XML resource asking price
<bitmap/> Tag Bitmap reference: http://blog.csdn.net/pingchuanyang/article/details/9239271

Property animations
Property animations are enhanced motion tweens that allow you to customize the view component
Animations can be animated by customizing the animation effect and attaching it to the component.


Reference: http://keeganlee.me/post/android/20150916
http://blog.csdn.net/ouyang_peng/article/details/8800743

Android drawable Resource Induction

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.