Most visited

Recently visited

Added in API level 1

TableLayout.LayoutParams

public static class TableLayout.LayoutParams
extends LinearLayout.LayoutParams

java.lang.Object
   ↳ android.view.ViewGroup.LayoutParams
     ↳ android.view.ViewGroup.MarginLayoutParams
       ↳ android.widget.LinearLayout.LayoutParams
         ↳ android.widget.TableLayout.LayoutParams


这组布局参数强制每个孩子的宽度为 MATCH_PARENT ,每个孩子的高度为 WRAP_CONTENT ,但只限于未指定高度。

Summary

Inherited XML attributes

From class android.widget.LinearLayout.LayoutParams
From class android.view.ViewGroup.MarginLayoutParams
From class android.view.ViewGroup.LayoutParams

Inherited constants

From class android.view.ViewGroup.LayoutParams

Inherited fields

From class android.widget.LinearLayout.LayoutParams
From class android.view.ViewGroup.MarginLayoutParams
From class android.view.ViewGroup.LayoutParams

Public constructors

TableLayout.LayoutParams(Context c, AttributeSet attrs)

TableLayout.LayoutParams(int w, int h)

TableLayout.LayoutParams(int w, int h, float initWeight)

TableLayout.LayoutParams()

将子宽度设置为 ViewGroup.LayoutParams ,将子女高度设置为 WRAP_CONTENT

TableLayout.LayoutParams(ViewGroup.LayoutParams p)

TableLayout.LayoutParams(ViewGroup.MarginLayoutParams source)

Protected methods

void setBaseAttributes(TypedArray a, int widthAttr, int heightAttr)

将行的宽度修复为MATCH_PARENT ; 如果未指定布局高度,则行的高度固定为WRAP_CONTENT

Inherited methods

From class android.widget.LinearLayout.LayoutParams
From class android.view.ViewGroup.MarginLayoutParams
From class android.view.ViewGroup.LayoutParams
From class java.lang.Object

Public constructors

TableLayout.LayoutParams

Added in API level 1
TableLayout.LayoutParams (Context c, 
                AttributeSet attrs)

Parameters
c Context
attrs AttributeSet

TableLayout.LayoutParams

Added in API level 1
TableLayout.LayoutParams (int w, 
                int h)

Parameters
w int
h int

TableLayout.LayoutParams

Added in API level 1
TableLayout.LayoutParams (int w, 
                int h, 
                float initWeight)

Parameters
w int
h int
initWeight float

TableLayout.LayoutParams

Added in API level 1
TableLayout.LayoutParams ()

将子宽度设置为 ViewGroup.LayoutParams ,将子女高度设置为 WRAP_CONTENT

TableLayout.LayoutParams

Added in API level 1
TableLayout.LayoutParams (ViewGroup.LayoutParams p)

Parameters
p ViewGroup.LayoutParams

TableLayout.LayoutParams

Added in API level 1
TableLayout.LayoutParams (ViewGroup.MarginLayoutParams source)

Parameters
source ViewGroup.MarginLayoutParams

Protected methods

setBaseAttributes

Added in API level 1
void setBaseAttributes (TypedArray a, 
                int widthAttr, 
                int heightAttr)

将行的宽度修复为MATCH_PARENT ; 如果未指定布局高度,则行的高度固定为WRAP_CONTENT

Parameters
a TypedArray: the styled attributes set
widthAttr int: the width attribute to fetch
heightAttr int: the height attribute to fetch

Hooray!