Package org.lwjgl.util.yoga
Class YGLayout.Buffer
- Enclosing class:
YGLayout
An array of
YGLayout
structs.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
Field Summary
Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
Constructor Summary
ConstructorDescriptionBuffer
(long address, int cap) Buffer
(ByteBuffer container) Creates a newYGLayout.Buffer
instance backed by the specified container. -
Method Summary
Modifier and TypeMethodDescriptionborder()
float
border
(int index) cachedMeasurements
(int index) int
boolean
float
dimensions
(int index) int
boolean
int
boolean
int
margin()
float
margin
(int index) float
measuredDimensions
(int index) int
padding()
float
padding
(int index) float
positions
(int index) Methods inherited from class org.lwjgl.system.StructBuffer
apply, apply, forEach, get, get, get, get, iterator, parallelStream, put, put, sizeof, spliterator, stream
Methods inherited from class org.lwjgl.system.CustomBuffer
address, address, address0, capacity, clear, compact, duplicate, flip, free, hasRemaining, limit, limit, mark, position, position, put, remaining, reset, rewind, slice, slice, toString
Methods inherited from class org.lwjgl.system.Pointer.Default
equals, hashCode
-
Constructor Details
-
Buffer
Creates a newYGLayout.Buffer
instance backed by the specified container.Changes to the container's content will be visible to the struct buffer instance and vice versa. The two buffers' position, limit, and mark values will be independent. The new buffer's position will be zero, its capacity and its limit will be the number of bytes remaining in this buffer divided by
YGLayout.SIZEOF
, and its mark will be undefined.The created buffer instance holds a strong reference to the container object.
-
Buffer
public Buffer(long address, int cap)
-
-
Method Details
-
positions
- Returns:
- a
FloatBuffer
view of thepositions
field.
-
positions
public float positions(int index) - Returns:
- the value at the specified index of the
positions
field.
-
dimensions
- Returns:
- a
FloatBuffer
view of thedimensions
field.
-
dimensions
public float dimensions(int index) - Returns:
- the value at the specified index of the
dimensions
field.
-
margin
- Returns:
- a
FloatBuffer
view of themargin
field.
-
margin
public float margin(int index) - Returns:
- the value at the specified index of the
margin
field.
-
border
- Returns:
- a
FloatBuffer
view of theborder
field.
-
border
public float border(int index) - Returns:
- the value at the specified index of the
border
field.
-
padding
- Returns:
- a
FloatBuffer
view of thepadding
field.
-
padding
public float padding(int index) - Returns:
- the value at the specified index of the
padding
field.
-
direction
public int direction()- Returns:
- the value of the
direction
field.
-
didUseLegacyFlag
public boolean didUseLegacyFlag()- Returns:
- the value of the
didUseLegacyFlag
field.
-
doesLegacyStretchFlagAffectsLayout
public boolean doesLegacyStretchFlagAffectsLayout()- Returns:
- the value of the
doesLegacyStretchFlagAffectsLayout
field.
-
hadOverflow
public boolean hadOverflow()- Returns:
- the value of the
hadOverflow
field.
-
computedFlexBasisGeneration
public int computedFlexBasisGeneration()- Returns:
- the value of the
computedFlexBasisGeneration
field.
-
computedFlexBasis
- Returns:
- a
YGFloatOptional
view of thecomputedFlexBasis
field.
-
generationCount
public int generationCount()- Returns:
- the value of the
generationCount
field.
-
lastOwnerDirection
public int lastOwnerDirection()- Returns:
- the value of the
lastOwnerDirection
field.
-
nextCachedMeasurementsIndex
public int nextCachedMeasurementsIndex()- Returns:
- the value of the
nextCachedMeasurementsIndex
field.
-
cachedMeasurements
- Returns:
- a
YGCachedMeasurement
.Buffer view of thecachedMeasurements
field.
-
cachedMeasurements
- Returns:
- a
YGCachedMeasurement
view of the struct at the specified index of thecachedMeasurements
field.
-
measuredDimensions
- Returns:
- a
FloatBuffer
view of themeasuredDimensions
field.
-
measuredDimensions
public float measuredDimensions(int index) - Returns:
- the value at the specified index of the
measuredDimensions
field.
-
cachedLayout
- Returns:
- a
YGCachedMeasurement
view of thecachedLayout
field.
-