Lines Matching full:layout
1 page.title=Layout Tricks: Creating Reusable UI Components
18 <p>In Android XML layout files, each tag is mapped to an actual class instance
26 href="{@docRoot}resources/articles/layout-tricks-merge.html">Merging Layouts</a>
30 suggests; it includes another XML layout. Using this tag is straightforward as
43 <include android:id="@+id/cell1" layout="@layout/workspace_screen" />
44 <include android:id="@+id/cell2" layout="@layout/workspace_screen" />
45 <include android:id="@+id/cell3" layout="@layout/workspace_screen" />
49 <p>In the <code><include /></code> only the <code>layout</code> attribute
51 is a reference to the layout file you wish to include. In this example, the same
52 layout is included three times in a row. This tag also lets you override a few
53 attributes of the included layout. The above example shows that you can use
55 layout; it will also override the id of the included layout if one is defined.
56 Similarly, you can override all the layout parameters. This means that any
59 which the same layout is included twice, but only the first one overrides the layout properties:</p>
62 <!-- override the layout height and width -->
63 <include layout="@layout/image_holder"
66 <!-- do not override layout dimensions; inherit them from image_holder -->
67 <include layout="@layout/image_holder" />
70 <p class="caution"><strong>Caution:</strong> If you want to override the layout dimensions,
73 If you override only one, it will not take effect. (Other layout properties, such as weight,
74 are still inherited from the source layout.)</p>
77 UI depending on the device's configuration. For instance, the main layout of
78 your activity can be placed in the <code>layout/</code> directory and can
79 include another layout which exists in two flavors, in <code>layout-land/</code>
80 and <code>layout-port/</code>. This allows you to share most of the UI in