Package org.lwjgl.nuklear
Class NkStyleText
- All Implemented Interfaces:
AutoCloseable,NativeResource,Pointer
struct nk_style_text {
struct nk_color color;
struct nk_vec2 padding;
float color_factor;
float disabled_factor;
}-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidationNested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe struct alignment in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionNkStyleText(ByteBuffer container) Creates aNkStyleTextinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionstatic NkStyleTextcalloc()Returns a newNkStyleTextinstance allocated withmemCalloc.static NkStyleText.Buffercalloc(int capacity) Returns a newNkStyleText.Bufferinstance allocated withmemCalloc.static NkStyleText.Buffercalloc(int capacity, MemoryStack stack) Returns a newNkStyleText.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static NkStyleTextcalloc(MemoryStack stack) Returns a newNkStyleTextinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.color()Passes thecolorfield to the specifiedConsumer.Copies the specifiedNkColorto thecolorfield.floatcolor_factor(float value) Sets the specified value to thecolor_factorfield.static NkStyleTextcreate()Returns a newNkStyleTextinstance allocated withBufferUtils.static NkStyleText.Buffercreate(int capacity) Returns a newNkStyleText.Bufferinstance allocated withBufferUtils.static NkStyleTextcreate(long address) Returns a newNkStyleTextinstance for the specified memory address.static NkStyleText.Buffercreate(long address, int capacity) Create aNkStyleText.Bufferinstance at the specified memory.static @Nullable NkStyleTextcreateSafe(long address) static @Nullable NkStyleText.BuffercreateSafe(long address, int capacity) floatdisabled_factor(float value) Sets the specified value to thedisabled_factorfield.static NkStyleTextmalloc()Returns a newNkStyleTextinstance allocated withmemAlloc.static NkStyleText.Buffermalloc(int capacity) Returns a newNkStyleText.Bufferinstance allocated withmemAlloc.static NkStyleText.Buffermalloc(int capacity, MemoryStack stack) Returns a newNkStyleText.Bufferinstance allocated on the specifiedMemoryStack.static NkStyleTextmalloc(MemoryStack stack) Returns a newNkStyleTextinstance allocated on the specifiedMemoryStack.static NkColorncolor(long struct) Unsafe version ofcolor().static voidUnsafe version ofcolor.static floatncolor_factor(long struct) Unsafe version ofcolor_factor().static voidncolor_factor(long struct, float value) Unsafe version ofcolor_factor.static floatndisabled_factor(long struct) Unsafe version ofdisabled_factor().static voidndisabled_factor(long struct, float value) Unsafe version ofdisabled_factor.static NkVec2npadding(long struct) Unsafe version ofpadding().static voidUnsafe version ofpadding.padding()Passes thepaddingfield to the specifiedConsumer.Copies the specifiedNkVec2to thepaddingfield.Initializes this struct with the specified values.set(NkStyleText src) Copies the specified struct data to this struct.intsizeof()Returnssizeof(struct).Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toStringMethods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
COLOR
public static final int COLORThe struct member offsets. -
PADDING
public static final int PADDINGThe struct member offsets. -
COLOR_FACTOR
public static final int COLOR_FACTORThe struct member offsets. -
DISABLED_FACTOR
public static final int DISABLED_FACTORThe struct member offsets.
-
-
Constructor Details
-
NkStyleText
Creates aNkStyleTextinstance at the current position of the specifiedByteBuffercontainer. Changes to the buffer's content will be visible to the struct instance and vice versa.The created instance holds a strong reference to the container object.
-
-
Method Details
-
sizeof
public int sizeof()Description copied from class:StructReturnssizeof(struct).- Specified by:
sizeofin classStruct<NkStyleText>
-
color
- Returns:
- a
NkColorview of thecolorfield.
-
padding
- Returns:
- a
NkVec2view of thepaddingfield.
-
color_factor
public float color_factor()- Returns:
- the value of the
color_factorfield.
-
disabled_factor
public float disabled_factor()- Returns:
- the value of the
disabled_factorfield.
-
color
Copies the specifiedNkColorto thecolorfield. -
color
Passes thecolorfield to the specifiedConsumer. -
padding
Copies the specifiedNkVec2to thepaddingfield. -
padding
Passes thepaddingfield to the specifiedConsumer. -
color_factor
Sets the specified value to thecolor_factorfield. -
disabled_factor
Sets the specified value to thedisabled_factorfield. -
set
Initializes this struct with the specified values. -
set
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
Returns a newNkStyleTextinstance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newNkStyleTextinstance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newNkStyleTextinstance allocated withBufferUtils. -
create
Returns a newNkStyleTextinstance for the specified memory address. -
createSafe
-
malloc
Returns a newNkStyleText.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
Returns a newNkStyleText.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
Returns a newNkStyleText.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
Create aNkStyleText.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
malloc
Returns a newNkStyleTextinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newNkStyleTextinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
Returns a newNkStyleText.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
calloc
Returns a newNkStyleText.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
ncolor
Unsafe version ofcolor(). -
npadding
Unsafe version ofpadding(). -
ncolor_factor
public static float ncolor_factor(long struct) Unsafe version ofcolor_factor(). -
ndisabled_factor
public static float ndisabled_factor(long struct) Unsafe version ofdisabled_factor(). -
ncolor
Unsafe version ofcolor. -
npadding
Unsafe version ofpadding. -
ncolor_factor
public static void ncolor_factor(long struct, float value) Unsafe version ofcolor_factor. -
ndisabled_factor
public static void ndisabled_factor(long struct, float value) Unsafe version ofdisabled_factor.
-