Home | History | Annotate | Download | only in custom-views
      1 page.title=Creating Custom Views
      2 
      3 trainingnavtop=true
      4 startpage=true
      5 next.title=Creating a View Class
      6 next.link=create-view.html
      7 
      8 @jd:body
      9 
     10 <div id="tb-wrapper">
     11     <div id="tb">
     12 
     13         <h2>Dependencies and prerequisites</h2>
     14         <ul>
     15             <li>Android 2.1 (API level 7) or higher</li>
     16         </ul>
     17 
     18         <h2>You should also read</h2>
     19         <ul>
     20             <li><a href="{@docRoot}/guide/topics/ui/custom-components.html">Custom Components</a>
     21             </li>
     22             <li><a href="{@docRoot}/guide/topics/ui/ui-events.html">Input Events</a></li>
     23             <li><a href="{@docRoot}/guide/topics/graphics/prop-animation.html">Property
     24                 Animation</a></li>
     25             <li><a href="{@docRoot}/guide/topics/graphics/hardware-accel.html">Hardware
     26                 Acceleration</a></li>
     27             <li><a href="{@docRoot}guide/topics/ui/accessibility/index.html">
     28                 Accessibility</a> developer guide</li>
     29         </ul>
     30 <h2>Try it out</h2>
     31 <div class="download-box">
     32 <a href="{@docRoot}shareables/training/CustomView.zip"
     33 class="button">Download the sample</a>
     34 <p class="filename">CustomView.zip</p>
     35 </div>
     36     </div>
     37 </div>
     38 
     39 <p>
     40 The Android framework has a large set of {@link android.view.View} classes for
     41 interacting with the user and displaying various
     42 types of data. But
     43 sometimes your app has unique needs that arent covered by the built-in views. This class shows you
     44 how to create your
     45 own views that are robust and reusable.</p>
     46 
     47 <h2>Lessons</h2>
     48 
     49 <dl>
     50 <dt><b><a href="create-view.html">Creating a View Class</a></b></dt>
     51 <dd>Create a class that acts like a built-in view, with custom
     52     attributes and support from the <a href="http://developer.android.com/sdk/eclipse-adt.html">ADT</a> layout editor.
     53 </dd>
     54 
     55 <dt><b><a href="custom-drawing.html">Custom Drawing</a></b></dt>
     56 <dd>Make your view visually distinctive using the Android graphics system.</dd>
     57 
     58 <dt><b><a href="making-interactive.html">Making the View Interactive</a></b></dt>
     59 <dd>Users expect a view to react smoothly and naturally to input gestures.
     60     This lesson discusses how to use gesture detection, physics, and animation
     61     to give your user interface a professional feel.
     62 </dd>
     63 
     64 <dt><b><a href="optimizing-view.html">Optimizing the View</a></b></dt>
     65 <dd>No matter how beautiful your UI is, users won't love it if it
     66     doesn't run at a consistently high frame rate. Learn how to avoid common
     67     performance problems, and how to use hardware acceleration to make your
     68     custom drawings run faster.
     69 </dd>
     70 
     71 </dl> 
     72 
     73 
     74 
     75 
     76 
     77 
     78 
     79 
     80