Package org.lwjgl.nuklear
Class NkStyleProperty
- All Implemented Interfaces:
AutoCloseable,NativeResource,Pointer
struct nk_style_property {
{@link NkStyleItem struct nk_style_item} normal;
{@link NkStyleItem struct nk_style_item} hover;
{@link NkStyleItem struct nk_style_item} active;
{@link NkColor struct nk_color} border_color;
{@link NkColor struct nk_color} label_normal;
{@link NkColor struct nk_color} label_hover;
{@link NkColor struct nk_color} label_active;
enum nk_symbol_type sym_left;
enum nk_symbol_type sym_right;
float border;
float rounding;
{@link NkVec2 struct nk_vec2} padding;
float color_factor;
float disabled_factor;
{@link NkStyleEdit struct nk_style_edit} edit;
{@link NkStyleButton struct nk_style_button} inc_button;
{@link NkStyleButton struct nk_style_button} dec_button;
{@link NkHandle nk_handle} userdata;
{@link NkDrawBeginCallbackI nk_draw_begin} draw_begin;
{@link NkDrawEndCallbackI nk_draw_end} draw_end;
}-
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 member offsets.static 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 member offsets.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 member offsets.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 member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionNkStyleProperty(ByteBuffer container) Creates aNkStylePropertyinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionactive()active(Consumer<NkStyleItem> consumer) Passes theactivefield to the specifiedConsumer.active(NkStyleItem value) Copies the specifiedNkStyleItemto theactivefield.floatborder()border(float value) Sets the specified value to theborderfield.border_color(Consumer<NkColor> consumer) Passes theborder_colorfield to the specifiedConsumer.border_color(NkColor value) Copies the specifiedNkColorto theborder_colorfield.static NkStylePropertycalloc()Returns a newNkStylePropertyinstance allocated withmemCalloc.static NkStyleProperty.Buffercalloc(int capacity) Returns a newNkStyleProperty.Bufferinstance allocated withmemCalloc.static NkStyleProperty.Buffercalloc(int capacity, MemoryStack stack) Returns a newNkStyleProperty.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static NkStylePropertycalloc(MemoryStack stack) Returns a newNkStylePropertyinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static NkStylePropertyDeprecated.static NkStyleProperty.BuffercallocStack(int capacity) Deprecated.static NkStyleProperty.BuffercallocStack(int capacity, MemoryStack stack) Deprecated.static NkStylePropertycallocStack(MemoryStack stack) Deprecated.floatcolor_factor(float value) Sets the specified value to thecolor_factorfield.static NkStylePropertycreate()Returns a newNkStylePropertyinstance allocated withBufferUtils.static NkStyleProperty.Buffercreate(int capacity) Returns a newNkStyleProperty.Bufferinstance allocated withBufferUtils.static NkStylePropertycreate(long address) Returns a newNkStylePropertyinstance for the specified memory address.static NkStyleProperty.Buffercreate(long address, int capacity) Create aNkStyleProperty.Bufferinstance at the specified memory.static @Nullable NkStylePropertycreateSafe(long address) static @Nullable NkStyleProperty.BuffercreateSafe(long address, int capacity) dec_button(Consumer<NkStyleButton> consumer) Passes thedec_buttonfield to the specifiedConsumer.dec_button(NkStyleButton value) Copies the specifiedNkStyleButtonto thedec_buttonfield.floatdisabled_factor(float value) Sets the specified value to thedisabled_factorfield.@Nullable NkDrawBeginCallbackdraw_begin(@Nullable NkDrawBeginCallbackI value) Sets the specified value to thedraw_beginfield.@Nullable NkDrawEndCallbackdraw_end()draw_end(@Nullable NkDrawEndCallbackI value) Sets the specified value to thedraw_endfield.edit()edit(Consumer<NkStyleEdit> consumer) Passes theeditfield to the specifiedConsumer.edit(NkStyleEdit value) Copies the specifiedNkStyleEditto theeditfield.hover()hover(Consumer<NkStyleItem> consumer) Passes thehoverfield to the specifiedConsumer.hover(NkStyleItem value) Copies the specifiedNkStyleItemto thehoverfield.inc_button(Consumer<NkStyleButton> consumer) Passes theinc_buttonfield to the specifiedConsumer.inc_button(NkStyleButton value) Copies the specifiedNkStyleButtonto theinc_buttonfield.label_active(Consumer<NkColor> consumer) Passes thelabel_activefield to the specifiedConsumer.label_active(NkColor value) Copies the specifiedNkColorto thelabel_activefield.label_hover(Consumer<NkColor> consumer) Passes thelabel_hoverfield to the specifiedConsumer.label_hover(NkColor value) Copies the specifiedNkColorto thelabel_hoverfield.label_normal(Consumer<NkColor> consumer) Passes thelabel_normalfield to the specifiedConsumer.label_normal(NkColor value) Copies the specifiedNkColorto thelabel_normalfield.static NkStylePropertymalloc()Returns a newNkStylePropertyinstance allocated withmemAlloc.static NkStyleProperty.Buffermalloc(int capacity) Returns a newNkStyleProperty.Bufferinstance allocated withmemAlloc.static NkStyleProperty.Buffermalloc(int capacity, MemoryStack stack) Returns a newNkStyleProperty.Bufferinstance allocated on the specifiedMemoryStack.static NkStylePropertymalloc(MemoryStack stack) Returns a newNkStylePropertyinstance allocated on the specifiedMemoryStack.static NkStylePropertyDeprecated.static NkStyleProperty.BuffermallocStack(int capacity) Deprecated.static NkStyleProperty.BuffermallocStack(int capacity, MemoryStack stack) Deprecated.static NkStylePropertymallocStack(MemoryStack stack) Deprecated.static NkStyleItemnactive(long struct) Unsafe version ofactive().static voidnactive(long struct, NkStyleItem value) Unsafe version ofactive.static floatnborder(long struct) Unsafe version ofborder().static voidnborder(long struct, float value) Unsafe version ofborder.static NkColornborder_color(long struct) Unsafe version ofborder_color().static voidnborder_color(long struct, NkColor value) Unsafe version ofborder_color.static floatncolor_factor(long struct) Unsafe version ofcolor_factor().static voidncolor_factor(long struct, float value) Unsafe version ofcolor_factor.static NkStyleButtonndec_button(long struct) Unsafe version ofdec_button().static voidndec_button(long struct, NkStyleButton value) Unsafe version ofdec_button.static floatndisabled_factor(long struct) Unsafe version ofdisabled_factor().static voidndisabled_factor(long struct, float value) Unsafe version ofdisabled_factor.static @Nullable NkDrawBeginCallbackndraw_begin(long struct) Unsafe version ofdraw_begin().static voidndraw_begin(long struct, @Nullable NkDrawBeginCallbackI value) Unsafe version ofdraw_begin.static @Nullable NkDrawEndCallbackndraw_end(long struct) Unsafe version ofdraw_end().static voidndraw_end(long struct, @Nullable NkDrawEndCallbackI value) Unsafe version ofdraw_end.static NkStyleEditnedit(long struct) Unsafe version ofedit().static voidnedit(long struct, NkStyleEdit value) Unsafe version ofedit.static NkStyleItemnhover(long struct) Unsafe version ofhover().static voidnhover(long struct, NkStyleItem value) Unsafe version ofhover.static NkStyleButtonninc_button(long struct) Unsafe version ofinc_button().static voidninc_button(long struct, NkStyleButton value) Unsafe version ofinc_button.static NkColornlabel_active(long struct) Unsafe version oflabel_active().static voidnlabel_active(long struct, NkColor value) Unsafe version oflabel_active.static NkColornlabel_hover(long struct) Unsafe version oflabel_hover().static voidnlabel_hover(long struct, NkColor value) Unsafe version oflabel_hover.static NkColornlabel_normal(long struct) Unsafe version oflabel_normal().static voidnlabel_normal(long struct, NkColor value) Unsafe version oflabel_normal.static NkStyleItemnnormal(long struct) Unsafe version ofnormal().static voidnnormal(long struct, NkStyleItem value) Unsafe version ofnormal.normal()normal(Consumer<NkStyleItem> consumer) Passes thenormalfield to the specifiedConsumer.normal(NkStyleItem value) Copies the specifiedNkStyleItemto thenormalfield.static NkVec2npadding(long struct) Unsafe version ofpadding().static voidUnsafe version ofpadding.static floatnrounding(long struct) Unsafe version ofrounding().static voidnrounding(long struct, float value) Unsafe version ofrounding.static intnsym_left(long struct) Unsafe version ofsym_left().static voidnsym_left(long struct, int value) Unsafe version ofsym_left.static intnsym_right(long struct) Unsafe version ofsym_right().static voidnsym_right(long struct, int value) Unsafe version ofsym_right.static NkHandlenuserdata(long struct) Unsafe version ofuserdata().static voidUnsafe version ofuserdata.padding()Passes thepaddingfield to the specifiedConsumer.Copies the specifiedNkVec2to thepaddingfield.floatrounding()rounding(float value) Sets the specified value to theroundingfield.set(NkStyleItem normal, NkStyleItem hover, NkStyleItem active, NkColor border_color, NkColor label_normal, NkColor label_hover, NkColor label_active, int sym_left, int sym_right, float border, float rounding, NkVec2 padding, float color_factor, float disabled_factor, NkStyleEdit edit, NkStyleButton inc_button, NkStyleButton dec_button, NkHandle userdata, NkDrawBeginCallbackI draw_begin, NkDrawEndCallbackI draw_end) Initializes this struct with the specified values.set(NkStyleProperty src) Copies the specified struct data to this struct.intsizeof()Returnssizeof(struct).intsym_left()sym_left(int value) Sets the specified value to thesym_leftfield.intsym_right(int value) Sets the specified value to thesym_rightfield.userdata()Passes theuserdatafield to the specifiedConsumer.Copies the specifiedNkHandleto theuserdatafield.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. -
NORMAL
public static final int NORMALThe struct member offsets. -
HOVER
public static final int HOVERThe struct member offsets. -
ACTIVE
public static final int ACTIVEThe struct member offsets. -
BORDER_COLOR
public static final int BORDER_COLORThe struct member offsets. -
LABEL_NORMAL
public static final int LABEL_NORMALThe struct member offsets. -
LABEL_HOVER
public static final int LABEL_HOVERThe struct member offsets. -
LABEL_ACTIVE
public static final int LABEL_ACTIVEThe struct member offsets. -
SYM_LEFT
public static final int SYM_LEFTThe struct member offsets. -
SYM_RIGHT
public static final int SYM_RIGHTThe struct member offsets. -
BORDER
public static final int BORDERThe struct member offsets. -
ROUNDING
public static final int ROUNDINGThe 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. -
EDIT
public static final int EDITThe struct member offsets. -
INC_BUTTON
public static final int INC_BUTTONThe struct member offsets. -
DEC_BUTTON
public static final int DEC_BUTTONThe struct member offsets. -
USERDATA
public static final int USERDATAThe struct member offsets. -
DRAW_BEGIN
public static final int DRAW_BEGINThe struct member offsets. -
DRAW_END
public static final int DRAW_ENDThe struct member offsets.
-
-
Constructor Details
-
NkStyleProperty
Creates aNkStylePropertyinstance 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<NkStyleProperty>
-
normal
- Returns:
- a
NkStyleItemview of thenormalfield.
-
hover
- Returns:
- a
NkStyleItemview of thehoverfield.
-
active
- Returns:
- a
NkStyleItemview of theactivefield.
-
border_color
- Returns:
- a
NkColorview of theborder_colorfield.
-
label_normal
- Returns:
- a
NkColorview of thelabel_normalfield.
-
label_hover
- Returns:
- a
NkColorview of thelabel_hoverfield.
-
label_active
- Returns:
- a
NkColorview of thelabel_activefield.
-
sym_left
public int sym_left()- Returns:
- the value of the
sym_leftfield.
-
sym_right
public int sym_right()- Returns:
- the value of the
sym_rightfield.
-
border
public float border()- Returns:
- the value of the
borderfield.
-
rounding
public float rounding()- Returns:
- the value of the
roundingfield.
-
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.
-
edit
- Returns:
- a
NkStyleEditview of theeditfield.
-
inc_button
- Returns:
- a
NkStyleButtonview of theinc_buttonfield.
-
dec_button
- Returns:
- a
NkStyleButtonview of thedec_buttonfield.
-
userdata
- Returns:
- a
NkHandleview of theuserdatafield.
-
draw_begin
- Returns:
- the value of the
draw_beginfield.
-
draw_end
- Returns:
- the value of the
draw_endfield.
-
normal
Copies the specifiedNkStyleItemto thenormalfield. -
normal
Passes thenormalfield to the specifiedConsumer. -
hover
Copies the specifiedNkStyleItemto thehoverfield. -
hover
Passes thehoverfield to the specifiedConsumer. -
active
Copies the specifiedNkStyleItemto theactivefield. -
active
Passes theactivefield to the specifiedConsumer. -
border_color
Copies the specifiedNkColorto theborder_colorfield. -
border_color
Passes theborder_colorfield to the specifiedConsumer. -
label_normal
Copies the specifiedNkColorto thelabel_normalfield. -
label_normal
Passes thelabel_normalfield to the specifiedConsumer. -
label_hover
Copies the specifiedNkColorto thelabel_hoverfield. -
label_hover
Passes thelabel_hoverfield to the specifiedConsumer. -
label_active
Copies the specifiedNkColorto thelabel_activefield. -
label_active
Passes thelabel_activefield to the specifiedConsumer. -
sym_left
Sets the specified value to thesym_leftfield. -
sym_right
Sets the specified value to thesym_rightfield. -
border
Sets the specified value to theborderfield. -
rounding
Sets the specified value to theroundingfield. -
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. -
edit
Copies the specifiedNkStyleEditto theeditfield. -
edit
Passes theeditfield to the specifiedConsumer. -
inc_button
Copies the specifiedNkStyleButtonto theinc_buttonfield. -
inc_button
Passes theinc_buttonfield to the specifiedConsumer. -
dec_button
Copies the specifiedNkStyleButtonto thedec_buttonfield. -
dec_button
Passes thedec_buttonfield to the specifiedConsumer. -
userdata
Copies the specifiedNkHandleto theuserdatafield. -
userdata
Passes theuserdatafield to the specifiedConsumer. -
draw_begin
Sets the specified value to thedraw_beginfield. -
draw_end
Sets the specified value to thedraw_endfield. -
set
public NkStyleProperty set(NkStyleItem normal, NkStyleItem hover, NkStyleItem active, NkColor border_color, NkColor label_normal, NkColor label_hover, NkColor label_active, int sym_left, int sym_right, float border, float rounding, NkVec2 padding, float color_factor, float disabled_factor, NkStyleEdit edit, NkStyleButton inc_button, NkStyleButton dec_button, NkHandle userdata, NkDrawBeginCallbackI draw_begin, NkDrawEndCallbackI draw_end) 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 newNkStylePropertyinstance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newNkStylePropertyinstance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newNkStylePropertyinstance allocated withBufferUtils. -
create
Returns a newNkStylePropertyinstance for the specified memory address. -
createSafe
-
malloc
Returns a newNkStyleProperty.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
Returns a newNkStyleProperty.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
Returns a newNkStyleProperty.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
Create aNkStyleProperty.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead. -
malloc
Returns a newNkStylePropertyinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newNkStylePropertyinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
Returns a newNkStyleProperty.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
calloc
Returns a newNkStyleProperty.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
nnormal
Unsafe version ofnormal(). -
nhover
Unsafe version ofhover(). -
nactive
Unsafe version ofactive(). -
nborder_color
Unsafe version ofborder_color(). -
nlabel_normal
Unsafe version oflabel_normal(). -
nlabel_hover
Unsafe version oflabel_hover(). -
nlabel_active
Unsafe version oflabel_active(). -
nsym_left
public static int nsym_left(long struct) Unsafe version ofsym_left(). -
nsym_right
public static int nsym_right(long struct) Unsafe version ofsym_right(). -
nborder
public static float nborder(long struct) Unsafe version ofborder(). -
nrounding
public static float nrounding(long struct) Unsafe version ofrounding(). -
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(). -
nedit
Unsafe version ofedit(). -
ninc_button
Unsafe version ofinc_button(). -
ndec_button
Unsafe version ofdec_button(). -
nuserdata
Unsafe version ofuserdata(). -
ndraw_begin
Unsafe version ofdraw_begin(). -
ndraw_end
Unsafe version ofdraw_end(). -
nnormal
Unsafe version ofnormal. -
nhover
Unsafe version ofhover. -
nactive
Unsafe version ofactive. -
nborder_color
Unsafe version ofborder_color. -
nlabel_normal
Unsafe version oflabel_normal. -
nlabel_hover
Unsafe version oflabel_hover. -
nlabel_active
Unsafe version oflabel_active. -
nsym_left
public static void nsym_left(long struct, int value) Unsafe version ofsym_left. -
nsym_right
public static void nsym_right(long struct, int value) Unsafe version ofsym_right. -
nborder
public static void nborder(long struct, float value) Unsafe version ofborder. -
nrounding
public static void nrounding(long struct, float value) Unsafe version ofrounding. -
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. -
nedit
Unsafe version ofedit. -
ninc_button
Unsafe version ofinc_button. -
ndec_button
Unsafe version ofdec_button. -
nuserdata
Unsafe version ofuserdata. -
ndraw_begin
Unsafe version ofdraw_begin. -
ndraw_end
Unsafe version ofdraw_end.
-