Constant

class omni.kit.property.material.scripts.widgets.material_binding.material_utils.Constant

Bases: object

A class that defines constants for a USD stage material binding tool.

This class contains various constants such as icon size, label width, font size, and special identifiers for missing paths or mixed values. It also ensures that its attributes are immutable by raising a ValueError if an attempt is made to set an attribute. The class checks the validity of certain constants during initialization to ensure correctness of the defined values.

Methods

Attributes

BOUND_LABEL_WIDTH

Width of the bound label in pixels.

FONT_SIZE

Font size for text elements.

ICON_SIZE

Icon display size in pixels.

MIXED

Indicates a mixed value state.

MIXED_COLOR

Color code for mixed value indication.

PERSISTENT_SETTINGS_PREFIX

Prefix for persistent settings paths.

SDF_PATH_INVALID

Represents an invalid SDF path.

__init__()
BOUND_LABEL_WIDTH = 50

Width of the bound label in pixels.

Type

int

FONT_SIZE = 14.0

Font size for text elements.

Type

float

ICON_SIZE = 96

Icon display size in pixels.

Type

int

MIXED = 'Mixed'

Indicates a mixed value state.

Type

str

MIXED_COLOR = 4291599969

Color code for mixed value indication.

Type

int

PERSISTENT_SETTINGS_PREFIX = '/persistent'

Prefix for persistent settings paths.

Type

str

SDF_PATH_INVALID = '$NONE$'

Represents an invalid SDF path.

Type

str