Length

class omni.ui.Length

Bases: pybind11_object

OMNI.UI has several different units for expressing a length. Many widget properties take “Length” values, such as width, height, minWidth, minHeight, etc. Pixel is the absolute length unit. Percent and Fraction are relative length units, and they specify a length relative to the parent length. Relative length units are scaled with the parent.

Methods

__init__(*args, **kwargs)

Overloaded function.

Attributes

unit

(UnitType.) Unit.

value

(float) Value

__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: omni.ui._ui.Length, arg0: float, arg1: omni::ui::UnitType) -> None

  2. __init__(self: omni.ui._ui.Length, arg0: float) -> None

  3. __init__(self: omni.ui._ui.Length, arg0: int) -> None

Construct Length.

`kwargsdict`

See below

### Keyword Arguments:

property unit

(UnitType.) Unit.

property value

(float) Value