logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Struct LayoutPadding

    Inner spacing of a layout container, in pixels, mirroring CSS padding. Applied between the container's edges and its children.

    Inherited Members
    ValueType.Equals(object)
    ValueType.GetHashCode()
    ValueType.ToString()
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetType()
    Namespace: Serenity.Ui.Domain.Entities
    Assembly: Serenity.Ui.Domain.dll
    Syntax
    public struct LayoutPadding

    Fields

    Bottom

    Padding on the bottom edge, in pixels.

    Declaration
    public float Bottom
    Field Value
    Type Description
    float

    Left

    Padding on the left edge, in pixels.

    Declaration
    public float Left
    Field Value
    Type Description
    float

    Right

    Padding on the right edge, in pixels.

    Declaration
    public float Right
    Field Value
    Type Description
    float

    Top

    Padding on the top edge, in pixels.

    Declaration
    public float Top
    Field Value
    Type Description
    float

    Methods

    All(float)

    Uniform padding on all four edges.

    Declaration
    public static LayoutPadding All(float value)
    Parameters
    Type Name Description
    float value
    Returns
    Type Description
    LayoutPadding

    Symmetric(float, float)

    Separate horizontal (left/right) and vertical (top/bottom) padding.

    Declaration
    public static LayoutPadding Symmetric(float horizontal, float vertical)
    Parameters
    Type Name Description
    float horizontal
    float vertical
    Returns
    Type Description
    LayoutPadding
    In this article
    © 2026 Serenity. All Rights Reserved