Documentation

Unity Engine

Download Unity

Unity Engine

GridLine

A single placement value for grid-column-start, grid-column-end, grid-row-start and grid-row-end: auto, an explicit line (a non-zero integer; negative lines count back from the end edge of the explicit grid), or span <n> (n \>= 1).
Read time 1 minuteLast updated 3 days ago

Definition

public readonly struct GridLine : IEquatable<GridLine>

Properties

Property

Description

isAutoWhether this value is
auto
.
isLineWhether this value is an explicit line.
isSpanWhether this value is a span.
lineThe line index when GridLine.isLine is true (1-based, or negative counting back from the end edge); otherwise 0.
placementWhich kind of placement this value represents.
spanThe span count when GridLine.isSpan is true; otherwise 0.

Static Properties

Property

Description

Auto
auto
: the edge is resolved by grid auto-placement.

Methods

Method

Description

ToStringThe USS text form:
auto
,
span <n>
, or the line number.

Static Methods

Method

Description

AtLineAn explicit grid line.
SpanA span of
count
tracks from the opposite edge.

Operators

Operator

Description

GridLineConverts a non-zero integer to an explicit line (see GridLine.AtLine).