Class Rectangle | Vector Graphics | 1.0.0-preview.34
docs.unity.cn
    Show / Hide Table of Contents

    Class Rectangle

    Defines a rectangle shape, which may be rounded.

    Inheritance
    Object
    Filled
    Rectangle
    Inherited Members
    Filled.Fill
    Filled.FillTransform
    Filled.PathProps
    Namespace: Unity.VectorGraphics
    Syntax
    [Obsolete("Use the Shape class and call VectorUtils.MakeRectangleShape() instead")]
    public class Rectangle : Filled, IDrawable

    Properties

    Position

    The position of the rectangle.

    Declaration
    public Vector2 Position { get; set; }
    Property Value
    Type Description
    Vector2
    Remarks

    Rectangles are anchored on their top-left corner, not their center.

    RadiusBL

    The bottom-left radius of the rectangle.

    Declaration
    public Vector2 RadiusBL { get; set; }
    Property Value
    Type Description
    Vector2

    RadiusBR

    The bottom-right radius of the rectangle.

    Declaration
    public Vector2 RadiusBR { get; set; }
    Property Value
    Type Description
    Vector2

    RadiusTL

    The top-left radius of the rectangle.

    Declaration
    public Vector2 RadiusTL { get; set; }
    Property Value
    Type Description
    Vector2

    RadiusTR

    The top-right radius of the rectangle.

    Declaration
    public Vector2 RadiusTR { get; set; }
    Property Value
    Type Description
    Vector2

    Size

    The size of the rectangle.

    Declaration
    public Vector2 Size { get; set; }
    Property Value
    Type Description
    Vector2
    Back to top Copyright © 2020 Unity Technologies
    Generated by DocFX