TableRow
declare class TableRow extends ViewGroup {}
A layout that arranges its children horizontally. A TableRow
should always be used as a child of a TableLayout
.
If a TableRow
's parent is not a TableLayout
, the TableRow
will behave as an horizontal LinearLayout
.
The children of a TableRow
do not need to specify the layout_width
and layout_height
attributes in the XML file.
TableRow
always enforces those values to be respectively ViewGroup.LayoutParams.MATCH_PARENT
and ViewGroup.LayoutParams.WRAP_CONTENT
.
TableRow.LayoutParams
Set of layout parameters used in table rows.
declare class LayoutParams extends LinearLayout.MarginLayoutParams {}
Attribute
layout_column
<TableRow>
<View layout_column="2"
layout_width="20px"
layout_height="20px"
background="#000000"/>
</TableRow>
Description
The index of the column in which this child should be.
layout_span
<TableRow>
<View layout_span="2"
layout_width="20px"
layout_height="20px"
background="#000000"/>
</TableRow>
Description
Defines how many columns this child should span.