Save the date! Android Dev Summit is coming to Mountain View, CA on November 7-8, 2018.
added in version 1.0.0
belongs to Maven artifact androidx.wear:wear:1.0.0-rc01

BoxInsetLayout.LayoutParams

public static class BoxInsetLayout.LayoutParams
extends FrameLayout.LayoutParams

java.lang.Object
   ↳ android.view.ViewGroup.LayoutParams
     ↳ android.view.ViewGroup.MarginLayoutParams
       ↳ android.widget.FrameLayout.LayoutParams
         ↳ androidx.wear.widget.BoxInsetLayout.LayoutParams


Per-child layout information for layouts that support margins, gravity and boxedEdges. See BoxInsetLayout Layout Attributes for a list of all child view attributes that this class supports.

Summary

XML attributes

BoxInsetLayout_Layout_boxedEdges  

Constants

int BOX_ALL

The view will force an inset on all of the edges of the children.

int BOX_BOTTOM

The view will force an inset on the bottom edge of the children.

int BOX_LEFT

The view will force an inset on the left edge of the children.

int BOX_NONE

Default boxing setting.

int BOX_RIGHT

The view will force an inset on the right edge of the children.

int BOX_TOP

The view will force an inset on the top edge of the children.

Inherited constants

Fields

public int boxedEdges

Specifies the screen-specific insets for each of the child edges.

Inherited fields

Public constructors

BoxInsetLayout.LayoutParams(Context context, AttributeSet attrs)

Creates a new set of layout parameters.

BoxInsetLayout.LayoutParams(int width, int height)

Creates a new set of layout parameters with the specified width and height.

BoxInsetLayout.LayoutParams(int width, int height, int gravity)

Creates a new set of layout parameters with the specified width, height and gravity.

BoxInsetLayout.LayoutParams(int width, int height, int gravity, int boxed)
BoxInsetLayout.LayoutParams(ViewGroup.LayoutParams source)

Copy constructor.

BoxInsetLayout.LayoutParams(ViewGroup.MarginLayoutParams source)

Copy constructor.

BoxInsetLayout.LayoutParams(FrameLayout.LayoutParams source)

Copy constructor.

BoxInsetLayout.LayoutParams(BoxInsetLayout.LayoutParams source)

Copy constructor.

Inherited methods

XML attributes

BoxInsetLayout_Layout_boxedEdges

Constants

BOX_ALL

added in version 1.0.0
public static final int BOX_ALL

The view will force an inset on all of the edges of the children.

Constant Value: 15 (0x0000000f)

BOX_BOTTOM

added in version 1.0.0
public static final int BOX_BOTTOM

The view will force an inset on the bottom edge of the children.

Constant Value: 8 (0x00000008)

BOX_LEFT

added in version 1.0.0
public static final int BOX_LEFT

The view will force an inset on the left edge of the children.

Constant Value: 1 (0x00000001)

BOX_NONE

added in version 1.0.0
public static final int BOX_NONE

Default boxing setting. There are no insets forced on the child views.

Constant Value: 0 (0x00000000)

BOX_RIGHT

added in version 1.0.0
public static final int BOX_RIGHT

The view will force an inset on the right edge of the children.

Constant Value: 4 (0x00000004)

BOX_TOP

added in version 1.0.0
public static final int BOX_TOP

The view will force an inset on the top edge of the children.

Constant Value: 2 (0x00000002)

Fields

boxedEdges

added in version 1.0.0
public int boxedEdges

Specifies the screen-specific insets for each of the child edges.

Public constructors

BoxInsetLayout.LayoutParams

added in version 1.0.0
public BoxInsetLayout.LayoutParams (Context context, 
                AttributeSet attrs)

Creates a new set of layout parameters. The values are extracted from the supplied attributes set and context.

Parameters
context Context: the application environment

attrs AttributeSet: the set of attributes from which to extract the layout parameters' values

BoxInsetLayout.LayoutParams

added in version 1.0.0
public BoxInsetLayout.LayoutParams (int width, 
                int height)

Creates a new set of layout parameters with the specified width and height.

Parameters
width int: the width, either ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT or a fixed size in pixels

height int: the height, either ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT or a fixed size in pixelsy

BoxInsetLayout.LayoutParams

added in version 1.0.0
public BoxInsetLayout.LayoutParams (int width, 
                int height, 
                int gravity)

Creates a new set of layout parameters with the specified width, height and gravity.

Parameters
width int: the width, either ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT or a fixed size in pixels

height int: the height, either ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT or a fixed size in pixels

gravity int: the gravity

See also:

BoxInsetLayout.LayoutParams

added in version 1.0.0
public BoxInsetLayout.LayoutParams (int width, 
                int height, 
                int gravity, 
                int boxed)

Parameters
width int

height int

gravity int

boxed int

BoxInsetLayout.LayoutParams

added in version 1.0.0
public BoxInsetLayout.LayoutParams (ViewGroup.LayoutParams source)

Copy constructor. Clones the width and height of the source.

Parameters
source ViewGroup.LayoutParams: The layout params to copy from.

BoxInsetLayout.LayoutParams

added in version 1.0.0
public BoxInsetLayout.LayoutParams (ViewGroup.MarginLayoutParams source)

Copy constructor. Clones the width, height and margin values.

Parameters
source ViewGroup.MarginLayoutParams: The layout params to copy from.

BoxInsetLayout.LayoutParams

added in version 1.0.0
public BoxInsetLayout.LayoutParams (FrameLayout.LayoutParams source)

Copy constructor. Clones the width, height, margin values, and gravity of the source.

Parameters
source FrameLayout.LayoutParams: The layout params to copy from.

BoxInsetLayout.LayoutParams

added in version 1.0.0
public BoxInsetLayout.LayoutParams (BoxInsetLayout.LayoutParams source)

Copy constructor. Clones the width, height, margin values, boxedEdges and gravity of the source.

Parameters
source BoxInsetLayout.LayoutParams: The layout params to copy from.