Struct LayoutItem

helper for layouts

struct LayoutItem;

Fields

NameTypeDescription
_fillParent booltrue when layoutWidth/layoutHeight == FILL_PARENT; drives whether this item participates in space distribution
_isResizer bool
_layoutSize int
_maxSize int
_measuredSize int
_minSize int
_orientation Orientation
_resizerDelta int
_secondarySize int
_weight intproportional share of leftover space; higher value = larger share (like CSS flex-grow)
_widget Widget

Properties

NameTypeDescription
canExtend[get] bool
fillParent[get] bool
layoutSize[get] int
maxSize[get] int
measuredSize[get] int
minSize[get] int
secondarySize[get] int
weight[get] int

Methods

NameDescription
clear ()
layout (rc)
measure (parentWidth, parentHeight) set item and measure it
set (widget, orientation) sets item for widget