lightbulb_outline Help shape the future of the Google Play Console, Android Studio, and Firebase. Start survey

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


This set of layout parameters enforces the width of each child to be ViewGroup.LayoutParams.MATCH_PARENT and the height of each child to be ViewGroup.LayoutParams.WRAP_CONTENT, but only if the height is not specified.

Summary

Inherited XML attributes

Inherited constants

Inherited fields

Public constructors

TableLayout.LayoutParams(Context c, AttributeSet attrs)

TableLayout.LayoutParams(int w, int h)

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

TableLayout.LayoutParams()

Sets the child width to ViewGroup.LayoutParams and the child height to ViewGroup.LayoutParams.WRAP_CONTENT.

TableLayout.LayoutParams(ViewGroup.LayoutParams p)

TableLayout.LayoutParams(ViewGroup.MarginLayoutParams source)

Protected methods

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

Fixes the row's width to ViewGroup.LayoutParams.MATCH_PARENT; the row's height is fixed to ViewGroup.LayoutParams.WRAP_CONTENT if no layout height is specified.

Inherited methods

Public constructors

TableLayout.LayoutParams

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

Parameters
c Context

attrs AttributeSet

TableLayout.LayoutParams

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

Parameters
w int

h int

TableLayout.LayoutParams

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

Parameters
w int

h int

initWeight float

TableLayout.LayoutParams

added in API level 1
public TableLayout.LayoutParams ()

Sets the child width to ViewGroup.LayoutParams and the child height to ViewGroup.LayoutParams.WRAP_CONTENT.

TableLayout.LayoutParams

added in API level 1
public TableLayout.LayoutParams (ViewGroup.LayoutParams p)

Parameters
p ViewGroup.LayoutParams

TableLayout.LayoutParams

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

Parameters
source ViewGroup.MarginLayoutParams

Protected methods

setBaseAttributes

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

Fixes the row's width to ViewGroup.LayoutParams.MATCH_PARENT; the row's height is fixed to ViewGroup.LayoutParams.WRAP_CONTENT if no layout height is specified.

Parameters
a TypedArray: the styled attributes set

widthAttr int: the width attribute to fetch

heightAttr int: the height attribute to fetch