public class NkStyleProperty
extends org.lwjgl.system.Struct
implements org.lwjgl.system.NativeResource
sym_left – one of:sym_right – see sym_left
struct nk_style_property {
struct nk_style_item normal;
struct nk_style_item hover;
struct nk_style_item active;
struct nk_color border_color;
struct nk_color label_normal;
struct nk_color label_hover;
struct nk_color label_active;
enum nk_symbol_type sym_left;
enum nk_symbol_type sym_right;
float border;
float rounding;
struct nk_vec2 padding;
struct nk_style_edit edit;
struct nk_style_button inc_button;
struct nk_style_button dec_button;
nk_handle userdata;
nk_draw_begin draw_begin;
nk_draw_end draw_end;
}| Modifier and Type | Class and Description |
|---|---|
static class |
NkStyleProperty.Buffer
An array of
NkStyleProperty structs. |
| Modifier and Type | Field and Description |
|---|---|
static int |
ACTIVE
The struct member offsets.
|
static int |
ALIGNOF
The struct alignment in bytes.
|
static int |
BORDER
The struct member offsets.
|
static int |
BORDER_COLOR
The struct member offsets.
|
static int |
DEC_BUTTON
The struct member offsets.
|
static int |
DRAW_BEGIN
The struct member offsets.
|
static int |
DRAW_END
The struct member offsets.
|
static int |
EDIT
The struct member offsets.
|
static int |
HOVER
The struct member offsets.
|
static int |
INC_BUTTON
The struct member offsets.
|
static int |
LABEL_ACTIVE
The struct member offsets.
|
static int |
LABEL_HOVER
The struct member offsets.
|
static int |
LABEL_NORMAL
The struct member offsets.
|
static int |
NORMAL
The struct member offsets.
|
static int |
PADDING
The struct member offsets.
|
static int |
ROUNDING
The struct member offsets.
|
static int |
SIZEOF
The struct size in bytes.
|
static int |
SYM_LEFT
The struct member offsets.
|
static int |
SYM_RIGHT
The struct member offsets.
|
static int |
USERDATA
The struct member offsets.
|
| Constructor and Description |
|---|
NkStyleProperty(java.nio.ByteBuffer container)
Creates a
NkStyleProperty instance at the current position of the specified ByteBuffer container. |
| Modifier and Type | Method and Description |
|---|---|
NkStyleItem |
active()
Returns a
NkStyleItem view of the active field. |
NkStyleProperty |
active(java.util.function.Consumer<NkStyleItem> consumer)
Passes the
active field to the specified Consumer. |
NkStyleProperty |
active(NkStyleItem value)
Copies the specified
NkStyleItem to the active field. |
NkColor |
border_color()
Returns a
NkColor view of the border_color field. |
NkStyleProperty |
border_color(java.util.function.Consumer<NkColor> consumer)
Passes the
border_color field to the specified Consumer. |
NkStyleProperty |
border_color(NkColor value)
Copies the specified
NkColor to the border_color field. |
float |
border()
Returns the value of the
border field. |
NkStyleProperty |
border(float value)
Sets the specified value to the
border field. |
static NkStyleProperty |
calloc()
Returns a new
NkStyleProperty instance allocated with memCalloc. |
static NkStyleProperty.Buffer |
calloc(int capacity)
Returns a new
NkStyleProperty.Buffer instance allocated with memCalloc. |
static NkStyleProperty |
callocStack()
Returns a new
NkStyleProperty instance allocated on the thread-local MemoryStack and initializes all its bits to zero. |
static NkStyleProperty.Buffer |
callocStack(int capacity)
Returns a new
NkStyleProperty.Buffer instance allocated on the thread-local MemoryStack and initializes all its bits to zero. |
static NkStyleProperty.Buffer |
callocStack(int capacity,
org.lwjgl.system.MemoryStack stack)
Returns a new
NkStyleProperty.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero. |
static NkStyleProperty |
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a new
NkStyleProperty instance allocated on the specified MemoryStack and initializes all its bits to zero. |
static NkStyleProperty |
create()
Returns a new
NkStyleProperty instance allocated with BufferUtils. |
static NkStyleProperty.Buffer |
create(int capacity)
Returns a new
NkStyleProperty.Buffer instance allocated with BufferUtils. |
static NkStyleProperty |
create(long address)
Returns a new
NkStyleProperty instance for the specified memory address. |
static NkStyleProperty.Buffer |
create(long address,
int capacity)
Create a
NkStyleProperty.Buffer instance at the specified memory. |
static NkStyleProperty |
createSafe(long address)
|
static NkStyleProperty.Buffer |
createSafe(long address,
int capacity)
|
NkStyleButton |
dec_button()
Returns a
NkStyleButton view of the dec_button field. |
NkStyleProperty |
dec_button(java.util.function.Consumer<NkStyleButton> consumer)
Passes the
dec_button field to the specified Consumer. |
NkStyleProperty |
dec_button(NkStyleButton value)
Copies the specified
NkStyleButton to the dec_button field. |
NkDrawBeginCallback |
draw_begin()
Returns the value of the
draw_begin field. |
NkStyleProperty |
draw_begin(NkDrawBeginCallbackI value)
Sets the specified value to the
draw_begin field. |
NkDrawEndCallback |
draw_end()
Returns the value of the
draw_end field. |
NkStyleProperty |
draw_end(NkDrawEndCallbackI value)
Sets the specified value to the
draw_end field. |
NkStyleEdit |
edit()
Returns a
NkStyleEdit view of the edit field. |
NkStyleProperty |
edit(java.util.function.Consumer<NkStyleEdit> consumer)
Passes the
edit field to the specified Consumer. |
NkStyleProperty |
edit(NkStyleEdit value)
Copies the specified
NkStyleEdit to the edit field. |
NkStyleItem |
hover()
Returns a
NkStyleItem view of the hover field. |
NkStyleProperty |
hover(java.util.function.Consumer<NkStyleItem> consumer)
Passes the
hover field to the specified Consumer. |
NkStyleProperty |
hover(NkStyleItem value)
Copies the specified
NkStyleItem to the hover field. |
NkStyleButton |
inc_button()
Returns a
NkStyleButton view of the inc_button field. |
NkStyleProperty |
inc_button(java.util.function.Consumer<NkStyleButton> consumer)
Passes the
inc_button field to the specified Consumer. |
NkStyleProperty |
inc_button(NkStyleButton value)
Copies the specified
NkStyleButton to the inc_button field. |
NkColor |
label_active()
Returns a
NkColor view of the label_active field. |
NkStyleProperty |
label_active(java.util.function.Consumer<NkColor> consumer)
Passes the
label_active field to the specified Consumer. |
NkStyleProperty |
label_active(NkColor value)
Copies the specified
NkColor to the label_active field. |
NkColor |
label_hover()
Returns a
NkColor view of the label_hover field. |
NkStyleProperty |
label_hover(java.util.function.Consumer<NkColor> consumer)
Passes the
label_hover field to the specified Consumer. |
NkStyleProperty |
label_hover(NkColor value)
Copies the specified
NkColor to the label_hover field. |
NkColor |
label_normal()
Returns a
NkColor view of the label_normal field. |
NkStyleProperty |
label_normal(java.util.function.Consumer<NkColor> consumer)
Passes the
label_normal field to the specified Consumer. |
NkStyleProperty |
label_normal(NkColor value)
Copies the specified
NkColor to the label_normal field. |
static NkStyleProperty |
malloc()
Returns a new
NkStyleProperty instance allocated with memAlloc. |
static NkStyleProperty.Buffer |
malloc(int capacity)
Returns a new
NkStyleProperty.Buffer instance allocated with memAlloc. |
static NkStyleProperty |
mallocStack()
Returns a new
NkStyleProperty instance allocated on the thread-local MemoryStack. |
static NkStyleProperty.Buffer |
mallocStack(int capacity)
Returns a new
NkStyleProperty.Buffer instance allocated on the thread-local MemoryStack. |
static NkStyleProperty.Buffer |
mallocStack(int capacity,
org.lwjgl.system.MemoryStack stack)
Returns a new
NkStyleProperty.Buffer instance allocated on the specified MemoryStack. |
static NkStyleProperty |
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a new
NkStyleProperty instance allocated on the specified MemoryStack. |
static NkStyleItem |
nactive(long struct)
Unsafe version of
active(). |
static void |
nactive(long struct,
NkStyleItem value)
Unsafe version of
active. |
static NkColor |
nborder_color(long struct)
Unsafe version of
border_color(). |
static void |
nborder_color(long struct,
NkColor value)
Unsafe version of
border_color. |
static float |
nborder(long struct)
Unsafe version of
border(). |
static void |
nborder(long struct,
float value)
Unsafe version of
border. |
static NkStyleButton |
ndec_button(long struct)
Unsafe version of
dec_button(). |
static void |
ndec_button(long struct,
NkStyleButton value)
Unsafe version of
dec_button. |
static NkDrawBeginCallback |
ndraw_begin(long struct)
Unsafe version of
draw_begin(). |
static void |
ndraw_begin(long struct,
NkDrawBeginCallbackI value)
Unsafe version of
draw_begin. |
static NkDrawEndCallback |
ndraw_end(long struct)
Unsafe version of
draw_end(). |
static void |
ndraw_end(long struct,
NkDrawEndCallbackI value)
Unsafe version of
draw_end. |
static NkStyleEdit |
nedit(long struct)
Unsafe version of
edit(). |
static void |
nedit(long struct,
NkStyleEdit value)
Unsafe version of
edit. |
static NkStyleItem |
nhover(long struct)
Unsafe version of
hover(). |
static void |
nhover(long struct,
NkStyleItem value)
Unsafe version of
hover. |
static NkStyleButton |
ninc_button(long struct)
Unsafe version of
inc_button(). |
static void |
ninc_button(long struct,
NkStyleButton value)
Unsafe version of
inc_button. |
static NkColor |
nlabel_active(long struct)
Unsafe version of
label_active(). |
static void |
nlabel_active(long struct,
NkColor value)
Unsafe version of
label_active. |
static NkColor |
nlabel_hover(long struct)
Unsafe version of
label_hover(). |
static void |
nlabel_hover(long struct,
NkColor value)
Unsafe version of
label_hover. |
static NkColor |
nlabel_normal(long struct)
Unsafe version of
label_normal(). |
static void |
nlabel_normal(long struct,
NkColor value)
Unsafe version of
label_normal. |
static NkStyleItem |
nnormal(long struct)
Unsafe version of
normal(). |
static void |
nnormal(long struct,
NkStyleItem value)
Unsafe version of
normal. |
NkStyleItem |
normal()
Returns a
NkStyleItem view of the normal field. |
NkStyleProperty |
normal(java.util.function.Consumer<NkStyleItem> consumer)
Passes the
normal field to the specified Consumer. |
NkStyleProperty |
normal(NkStyleItem value)
Copies the specified
NkStyleItem to the normal field. |
static NkVec2 |
npadding(long struct)
Unsafe version of
padding(). |
static void |
npadding(long struct,
NkVec2 value)
Unsafe version of
padding. |
static float |
nrounding(long struct)
Unsafe version of
rounding(). |
static void |
nrounding(long struct,
float value)
Unsafe version of
rounding. |
static int |
nsym_left(long struct)
Unsafe version of
sym_left(). |
static void |
nsym_left(long struct,
int value)
Unsafe version of
sym_left. |
static int |
nsym_right(long struct)
Unsafe version of
sym_right(). |
static void |
nsym_right(long struct,
int value)
Unsafe version of
sym_right. |
static NkHandle |
nuserdata(long struct)
Unsafe version of
userdata(). |
static void |
nuserdata(long struct,
NkHandle value)
Unsafe version of
userdata. |
NkVec2 |
padding()
Returns a
NkVec2 view of the padding field. |
NkStyleProperty |
padding(java.util.function.Consumer<NkVec2> consumer)
Passes the
padding field to the specified Consumer. |
NkStyleProperty |
padding(NkVec2 value)
Copies the specified
NkVec2 to the padding field. |
float |
rounding()
Returns the value of the
rounding field. |
NkStyleProperty |
rounding(float value)
Sets the specified value to the
rounding field. |
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,
NkStyleEdit edit,
NkStyleButton inc_button,
NkStyleButton dec_button,
NkHandle userdata,
NkDrawBeginCallbackI draw_begin,
NkDrawEndCallbackI draw_end)
Initializes this struct with the specified values.
|
NkStyleProperty |
set(NkStyleProperty src)
Copies the specified struct data to this struct.
|
int |
sizeof() |
int |
sym_left()
Returns the value of the
sym_left field. |
NkStyleProperty |
sym_left(int value)
Sets the specified value to the
sym_left field. |
int |
sym_right()
Returns the value of the
sym_right field. |
NkStyleProperty |
sym_right(int value)
Sets the specified value to the
sym_right field. |
NkHandle |
userdata()
Returns a
NkHandle view of the userdata field. |
NkStyleProperty |
userdata(java.util.function.Consumer<NkHandle> consumer)
Passes the
userdata field to the specified Consumer. |
NkStyleProperty |
userdata(NkHandle value)
Copies the specified
NkHandle to the userdata field. |
public static final int SIZEOF
public static final int ALIGNOF
public static final int NORMAL
public static final int HOVER
public static final int ACTIVE
public static final int BORDER_COLOR
public static final int LABEL_NORMAL
public static final int LABEL_HOVER
public static final int LABEL_ACTIVE
public static final int SYM_LEFT
public static final int SYM_RIGHT
public static final int BORDER
public static final int ROUNDING
public static final int PADDING
public static final int EDIT
public static final int INC_BUTTON
public static final int DEC_BUTTON
public static final int USERDATA
public static final int DRAW_BEGIN
public static final int DRAW_END
public NkStyleProperty(java.nio.ByteBuffer container)
NkStyleProperty instance at the current position of the specified ByteBuffer container. 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.
public int sizeof()
sizeof in class org.lwjgl.system.Structpublic NkStyleItem normal()
NkStyleItem view of the normal field.public NkStyleItem hover()
NkStyleItem view of the hover field.public NkStyleItem active()
NkStyleItem view of the active field.public int sym_left()
sym_left field.public int sym_right()
sym_right field.public float border()
border field.public float rounding()
rounding field.public NkStyleEdit edit()
NkStyleEdit view of the edit field.public NkStyleButton inc_button()
NkStyleButton view of the inc_button field.public NkStyleButton dec_button()
NkStyleButton view of the dec_button field.@Nullable public NkDrawBeginCallback draw_begin()
draw_begin field.@Nullable public NkDrawEndCallback draw_end()
draw_end field.public NkStyleProperty normal(NkStyleItem value)
NkStyleItem to the normal field.public NkStyleProperty normal(java.util.function.Consumer<NkStyleItem> consumer)
normal field to the specified Consumer.public NkStyleProperty hover(NkStyleItem value)
NkStyleItem to the hover field.public NkStyleProperty hover(java.util.function.Consumer<NkStyleItem> consumer)
hover field to the specified Consumer.public NkStyleProperty active(NkStyleItem value)
NkStyleItem to the active field.public NkStyleProperty active(java.util.function.Consumer<NkStyleItem> consumer)
active field to the specified Consumer.public NkStyleProperty border_color(NkColor value)
NkColor to the border_color field.public NkStyleProperty border_color(java.util.function.Consumer<NkColor> consumer)
border_color field to the specified Consumer.public NkStyleProperty label_normal(NkColor value)
NkColor to the label_normal field.public NkStyleProperty label_normal(java.util.function.Consumer<NkColor> consumer)
label_normal field to the specified Consumer.public NkStyleProperty label_hover(NkColor value)
NkColor to the label_hover field.public NkStyleProperty label_hover(java.util.function.Consumer<NkColor> consumer)
label_hover field to the specified Consumer.public NkStyleProperty label_active(NkColor value)
NkColor to the label_active field.public NkStyleProperty label_active(java.util.function.Consumer<NkColor> consumer)
label_active field to the specified Consumer.public NkStyleProperty sym_left(int value)
sym_left field.public NkStyleProperty sym_right(int value)
sym_right field.public NkStyleProperty border(float value)
border field.public NkStyleProperty rounding(float value)
rounding field.public NkStyleProperty padding(NkVec2 value)
NkVec2 to the padding field.public NkStyleProperty padding(java.util.function.Consumer<NkVec2> consumer)
padding field to the specified Consumer.public NkStyleProperty edit(NkStyleEdit value)
NkStyleEdit to the edit field.public NkStyleProperty edit(java.util.function.Consumer<NkStyleEdit> consumer)
edit field to the specified Consumer.public NkStyleProperty inc_button(NkStyleButton value)
NkStyleButton to the inc_button field.public NkStyleProperty inc_button(java.util.function.Consumer<NkStyleButton> consumer)
inc_button field to the specified Consumer.public NkStyleProperty dec_button(NkStyleButton value)
NkStyleButton to the dec_button field.public NkStyleProperty dec_button(java.util.function.Consumer<NkStyleButton> consumer)
dec_button field to the specified Consumer.public NkStyleProperty userdata(NkHandle value)
NkHandle to the userdata field.public NkStyleProperty userdata(java.util.function.Consumer<NkHandle> consumer)
userdata field to the specified Consumer.public NkStyleProperty draw_begin(@Nullable NkDrawBeginCallbackI value)
draw_begin field.public NkStyleProperty draw_end(@Nullable NkDrawEndCallbackI value)
draw_end field.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, NkStyleEdit edit, NkStyleButton inc_button, NkStyleButton dec_button, NkHandle userdata, NkDrawBeginCallbackI draw_begin, NkDrawEndCallbackI draw_end)
public NkStyleProperty set(NkStyleProperty src)
src - the source structpublic static NkStyleProperty malloc()
NkStyleProperty instance allocated with memAlloc. The instance must be explicitly freed.public static NkStyleProperty calloc()
NkStyleProperty instance allocated with memCalloc. The instance must be explicitly freed.public static NkStyleProperty create()
NkStyleProperty instance allocated with BufferUtils.public static NkStyleProperty create(long address)
NkStyleProperty instance for the specified memory address.@Nullable public static NkStyleProperty createSafe(long address)
public static NkStyleProperty.Buffer malloc(int capacity)
NkStyleProperty.Buffer instance allocated with memAlloc. The instance must be explicitly freed.capacity - the buffer capacitypublic static NkStyleProperty.Buffer calloc(int capacity)
NkStyleProperty.Buffer instance allocated with memCalloc. The instance must be explicitly freed.capacity - the buffer capacitypublic static NkStyleProperty.Buffer create(int capacity)
NkStyleProperty.Buffer instance allocated with BufferUtils.capacity - the buffer capacitypublic static NkStyleProperty.Buffer create(long address, int capacity)
NkStyleProperty.Buffer instance at the specified memory.address - the memory addresscapacity - the buffer capacity@Nullable public static NkStyleProperty.Buffer createSafe(long address, int capacity)
public static NkStyleProperty mallocStack()
NkStyleProperty instance allocated on the thread-local MemoryStack.public static NkStyleProperty callocStack()
NkStyleProperty instance allocated on the thread-local MemoryStack and initializes all its bits to zero.public static NkStyleProperty mallocStack(org.lwjgl.system.MemoryStack stack)
NkStyleProperty instance allocated on the specified MemoryStack.stack - the stack from which to allocatepublic static NkStyleProperty callocStack(org.lwjgl.system.MemoryStack stack)
NkStyleProperty instance allocated on the specified MemoryStack and initializes all its bits to zero.stack - the stack from which to allocatepublic static NkStyleProperty.Buffer mallocStack(int capacity)
NkStyleProperty.Buffer instance allocated on the thread-local MemoryStack.capacity - the buffer capacitypublic static NkStyleProperty.Buffer callocStack(int capacity)
NkStyleProperty.Buffer instance allocated on the thread-local MemoryStack and initializes all its bits to zero.capacity - the buffer capacitypublic static NkStyleProperty.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
NkStyleProperty.Buffer instance allocated on the specified MemoryStack.stack - the stack from which to allocatecapacity - the buffer capacitypublic static NkStyleProperty.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
NkStyleProperty.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.stack - the stack from which to allocatecapacity - the buffer capacitypublic static NkStyleItem nnormal(long struct)
normal().public static NkStyleItem nhover(long struct)
hover().public static NkStyleItem nactive(long struct)
active().public static NkColor nborder_color(long struct)
border_color().public static NkColor nlabel_normal(long struct)
label_normal().public static NkColor nlabel_hover(long struct)
label_hover().public static NkColor nlabel_active(long struct)
label_active().public static int nsym_left(long struct)
sym_left().public static int nsym_right(long struct)
sym_right().public static float nborder(long struct)
border().public static float nrounding(long struct)
rounding().public static NkStyleEdit nedit(long struct)
edit().public static NkStyleButton ninc_button(long struct)
inc_button().public static NkStyleButton ndec_button(long struct)
dec_button().public static NkHandle nuserdata(long struct)
userdata().@Nullable public static NkDrawBeginCallback ndraw_begin(long struct)
draw_begin().@Nullable public static NkDrawEndCallback ndraw_end(long struct)
draw_end().public static void nnormal(long struct,
NkStyleItem value)
normal.public static void nhover(long struct,
NkStyleItem value)
hover.public static void nactive(long struct,
NkStyleItem value)
active.public static void nborder_color(long struct,
NkColor value)
border_color.public static void nlabel_normal(long struct,
NkColor value)
label_normal.public static void nlabel_hover(long struct,
NkColor value)
label_hover.public static void nlabel_active(long struct,
NkColor value)
label_active.public static void nsym_left(long struct,
int value)
sym_left.public static void nsym_right(long struct,
int value)
sym_right.public static void nborder(long struct,
float value)
border.public static void nrounding(long struct,
float value)
rounding.public static void nedit(long struct,
NkStyleEdit value)
edit.public static void ninc_button(long struct,
NkStyleButton value)
inc_button.public static void ndec_button(long struct,
NkStyleButton value)
dec_button.public static void ndraw_begin(long struct,
@Nullable
NkDrawBeginCallbackI value)
draw_begin.public static void ndraw_end(long struct,
@Nullable
NkDrawEndCallbackI value)
draw_end.Copyright LWJGL. All Rights Reserved. License terms.