Class NkStyleCombo

All Implemented Interfaces:
AutoCloseable, NativeResource, Pointer

public class NkStyleCombo extends Struct<NkStyleCombo> implements NativeResource

 struct nk_style_combo {
     {@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;
     {@link NkColor struct nk_color} symbol_normal;
     {@link NkColor struct nk_color} symbol_hover;
     {@link NkColor struct nk_color} symbol_active;
     {@link NkStyleButton struct nk_style_button} button;
     enum nk_symbol_type sym_normal;
     enum nk_symbol_type sym_hover;
     enum nk_symbol_type sym_active;
     float border;
     float rounding;
     {@link NkVec2 struct nk_vec2} content_padding;
     {@link NkVec2 struct nk_vec2} button_padding;
     {@link NkVec2 struct nk_vec2} spacing;
     float color_factor;
     float disabled_factor;
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • NORMAL

      public static final int NORMAL
      The struct member offsets.
    • HOVER

      public static final int HOVER
      The struct member offsets.
    • ACTIVE

      public static final int ACTIVE
      The struct member offsets.
    • BORDER_COLOR

      public static final int BORDER_COLOR
      The struct member offsets.
    • LABEL_NORMAL

      public static final int LABEL_NORMAL
      The struct member offsets.
    • LABEL_HOVER

      public static final int LABEL_HOVER
      The struct member offsets.
    • LABEL_ACTIVE

      public static final int LABEL_ACTIVE
      The struct member offsets.
    • SYMBOL_NORMAL

      public static final int SYMBOL_NORMAL
      The struct member offsets.
    • SYMBOL_HOVER

      public static final int SYMBOL_HOVER
      The struct member offsets.
    • SYMBOL_ACTIVE

      public static final int SYMBOL_ACTIVE
      The struct member offsets.
    • BUTTON

      public static final int BUTTON
      The struct member offsets.
    • SYM_NORMAL

      public static final int SYM_NORMAL
      The struct member offsets.
    • SYM_HOVER

      public static final int SYM_HOVER
      The struct member offsets.
    • SYM_ACTIVE

      public static final int SYM_ACTIVE
      The struct member offsets.
    • BORDER

      public static final int BORDER
      The struct member offsets.
    • ROUNDING

      public static final int ROUNDING
      The struct member offsets.
    • CONTENT_PADDING

      public static final int CONTENT_PADDING
      The struct member offsets.
    • BUTTON_PADDING

      public static final int BUTTON_PADDING
      The struct member offsets.
    • SPACING

      public static final int SPACING
      The struct member offsets.
    • COLOR_FACTOR

      public static final int COLOR_FACTOR
      The struct member offsets.
    • DISABLED_FACTOR

      public static final int DISABLED_FACTOR
      The struct member offsets.
  • Constructor Details

    • NkStyleCombo

      public NkStyleCombo(ByteBuffer container)
      Creates a NkStyleCombo 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.

  • Method Details

    • sizeof

      public int sizeof()
      Description copied from class: Struct
      Returns sizeof(struct).
      Specified by:
      sizeof in class Struct<NkStyleCombo>
    • normal

      public NkStyleItem normal()
      Returns:
      a NkStyleItem view of the normal field.
    • hover

      public NkStyleItem hover()
      Returns:
      a NkStyleItem view of the hover field.
    • active

      public NkStyleItem active()
      Returns:
      a NkStyleItem view of the active field.
    • border_color

      public NkColor border_color()
      Returns:
      a NkColor view of the border_color field.
    • label_normal

      public NkColor label_normal()
      Returns:
      a NkColor view of the label_normal field.
    • label_hover

      public NkColor label_hover()
      Returns:
      a NkColor view of the label_hover field.
    • label_active

      public NkColor label_active()
      Returns:
      a NkColor view of the label_active field.
    • symbol_normal

      public NkColor symbol_normal()
      Returns:
      a NkColor view of the symbol_normal field.
    • symbol_hover

      public NkColor symbol_hover()
      Returns:
      a NkColor view of the symbol_hover field.
    • symbol_active

      public NkColor symbol_active()
      Returns:
      a NkColor view of the symbol_active field.
    • button

      public NkStyleButton button()
      Returns:
      a NkStyleButton view of the button field.
    • sym_normal

      public int sym_normal()
      Returns:
      the value of the sym_normal field.
    • sym_hover

      public int sym_hover()
      Returns:
      the value of the sym_hover field.
    • sym_active

      public int sym_active()
      Returns:
      the value of the sym_active field.
    • border

      public float border()
      Returns:
      the value of the border field.
    • rounding

      public float rounding()
      Returns:
      the value of the rounding field.
    • content_padding

      public NkVec2 content_padding()
      Returns:
      a NkVec2 view of the content_padding field.
    • button_padding

      public NkVec2 button_padding()
      Returns:
      a NkVec2 view of the button_padding field.
    • spacing

      public NkVec2 spacing()
      Returns:
      a NkVec2 view of the spacing field.
    • color_factor

      public float color_factor()
      Returns:
      the value of the color_factor field.
    • disabled_factor

      public float disabled_factor()
      Returns:
      the value of the disabled_factor field.
    • normal

      public NkStyleCombo normal(NkStyleItem value)
      Copies the specified NkStyleItem to the normal field.
    • normal

      public NkStyleCombo normal(Consumer<NkStyleItem> consumer)
      Passes the normal field to the specified Consumer.
    • hover

      public NkStyleCombo hover(NkStyleItem value)
      Copies the specified NkStyleItem to the hover field.
    • hover

      public NkStyleCombo hover(Consumer<NkStyleItem> consumer)
      Passes the hover field to the specified Consumer.
    • active

      public NkStyleCombo active(NkStyleItem value)
      Copies the specified NkStyleItem to the active field.
    • active

      public NkStyleCombo active(Consumer<NkStyleItem> consumer)
      Passes the active field to the specified Consumer.
    • border_color

      public NkStyleCombo border_color(NkColor value)
      Copies the specified NkColor to the border_color field.
    • border_color

      public NkStyleCombo border_color(Consumer<NkColor> consumer)
      Passes the border_color field to the specified Consumer.
    • label_normal

      public NkStyleCombo label_normal(NkColor value)
      Copies the specified NkColor to the label_normal field.
    • label_normal

      public NkStyleCombo label_normal(Consumer<NkColor> consumer)
      Passes the label_normal field to the specified Consumer.
    • label_hover

      public NkStyleCombo label_hover(NkColor value)
      Copies the specified NkColor to the label_hover field.
    • label_hover

      public NkStyleCombo label_hover(Consumer<NkColor> consumer)
      Passes the label_hover field to the specified Consumer.
    • label_active

      public NkStyleCombo label_active(NkColor value)
      Copies the specified NkColor to the label_active field.
    • label_active

      public NkStyleCombo label_active(Consumer<NkColor> consumer)
      Passes the label_active field to the specified Consumer.
    • symbol_normal

      public NkStyleCombo symbol_normal(NkColor value)
      Copies the specified NkColor to the symbol_normal field.
    • symbol_normal

      public NkStyleCombo symbol_normal(Consumer<NkColor> consumer)
      Passes the symbol_normal field to the specified Consumer.
    • symbol_hover

      public NkStyleCombo symbol_hover(NkColor value)
      Copies the specified NkColor to the symbol_hover field.
    • symbol_hover

      public NkStyleCombo symbol_hover(Consumer<NkColor> consumer)
      Passes the symbol_hover field to the specified Consumer.
    • symbol_active

      public NkStyleCombo symbol_active(NkColor value)
      Copies the specified NkColor to the symbol_active field.
    • symbol_active

      public NkStyleCombo symbol_active(Consumer<NkColor> consumer)
      Passes the symbol_active field to the specified Consumer.
    • button

      public NkStyleCombo button(NkStyleButton value)
      Copies the specified NkStyleButton to the button field.
    • button

      public NkStyleCombo button(Consumer<NkStyleButton> consumer)
      Passes the button field to the specified Consumer.
    • sym_normal

      public NkStyleCombo sym_normal(int value)
      Sets the specified value to the sym_normal field.
    • sym_hover

      public NkStyleCombo sym_hover(int value)
      Sets the specified value to the sym_hover field.
    • sym_active

      public NkStyleCombo sym_active(int value)
      Sets the specified value to the sym_active field.
    • border

      public NkStyleCombo border(float value)
      Sets the specified value to the border field.
    • rounding

      public NkStyleCombo rounding(float value)
      Sets the specified value to the rounding field.
    • content_padding

      public NkStyleCombo content_padding(NkVec2 value)
      Copies the specified NkVec2 to the content_padding field.
    • content_padding

      public NkStyleCombo content_padding(Consumer<NkVec2> consumer)
      Passes the content_padding field to the specified Consumer.
    • button_padding

      public NkStyleCombo button_padding(NkVec2 value)
      Copies the specified NkVec2 to the button_padding field.
    • button_padding

      public NkStyleCombo button_padding(Consumer<NkVec2> consumer)
      Passes the button_padding field to the specified Consumer.
    • spacing

      public NkStyleCombo spacing(NkVec2 value)
      Copies the specified NkVec2 to the spacing field.
    • spacing

      public NkStyleCombo spacing(Consumer<NkVec2> consumer)
      Passes the spacing field to the specified Consumer.
    • color_factor

      public NkStyleCombo color_factor(float value)
      Sets the specified value to the color_factor field.
    • disabled_factor

      public NkStyleCombo disabled_factor(float value)
      Sets the specified value to the disabled_factor field.
    • set

      public NkStyleCombo set(NkStyleItem normal, NkStyleItem hover, NkStyleItem active, NkColor border_color, NkColor label_normal, NkColor label_hover, NkColor label_active, NkColor symbol_normal, NkColor symbol_hover, NkColor symbol_active, NkStyleButton button, int sym_normal, int sym_hover, int sym_active, float border, float rounding, NkVec2 content_padding, NkVec2 button_padding, NkVec2 spacing, float color_factor, float disabled_factor)
      Initializes this struct with the specified values.
    • set

      public NkStyleCombo set(NkStyleCombo src)
      Copies the specified struct data to this struct.
      Parameters:
      src - the source struct
      Returns:
      this struct
    • malloc

      public static NkStyleCombo malloc()
      Returns a new NkStyleCombo instance allocated with memAlloc. The instance must be explicitly freed.
    • calloc

      public static NkStyleCombo calloc()
      Returns a new NkStyleCombo instance allocated with memCalloc. The instance must be explicitly freed.
    • create

      public static NkStyleCombo create()
      Returns a new NkStyleCombo instance allocated with BufferUtils.
    • create

      public static NkStyleCombo create(long address)
      Returns a new NkStyleCombo instance for the specified memory address.
    • createSafe

      public static @Nullable NkStyleCombo createSafe(long address)
      Like create, but returns null if address is NULL.
    • malloc

      public static NkStyleCombo.Buffer malloc(int capacity)
      Returns a new NkStyleCombo.Buffer instance allocated with memAlloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • calloc

      public static NkStyleCombo.Buffer calloc(int capacity)
      Returns a new NkStyleCombo.Buffer instance allocated with memCalloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • create

      public static NkStyleCombo.Buffer create(int capacity)
      Returns a new NkStyleCombo.Buffer instance allocated with BufferUtils.
      Parameters:
      capacity - the buffer capacity
    • create

      public static NkStyleCombo.Buffer create(long address, int capacity)
      Create a NkStyleCombo.Buffer instance at the specified memory.
      Parameters:
      address - the memory address
      capacity - the buffer capacity
    • createSafe

      public static @Nullable NkStyleCombo.Buffer createSafe(long address, int capacity)
      Like create, but returns null if address is NULL.
    • mallocStack

      @Deprecated public static NkStyleCombo mallocStack()
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.
    • callocStack

      @Deprecated public static NkStyleCombo callocStack()
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.
    • mallocStack

      @Deprecated public static NkStyleCombo mallocStack(MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.
    • callocStack

      @Deprecated public static NkStyleCombo callocStack(MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.
    • mallocStack

      @Deprecated public static NkStyleCombo.Buffer mallocStack(int capacity)
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(int, MemoryStack) instead.
    • callocStack

      @Deprecated public static NkStyleCombo.Buffer callocStack(int capacity)
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(int, MemoryStack) instead.
    • mallocStack

      @Deprecated public static NkStyleCombo.Buffer mallocStack(int capacity, MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(int, MemoryStack) instead.
    • callocStack

      @Deprecated public static NkStyleCombo.Buffer callocStack(int capacity, MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(int, MemoryStack) instead.
    • malloc

      public static NkStyleCombo malloc(MemoryStack stack)
      Returns a new NkStyleCombo instance allocated on the specified MemoryStack.
      Parameters:
      stack - the stack from which to allocate
    • calloc

      public static NkStyleCombo calloc(MemoryStack stack)
      Returns a new NkStyleCombo instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      stack - the stack from which to allocate
    • malloc

      public static NkStyleCombo.Buffer malloc(int capacity, MemoryStack stack)
      Returns a new NkStyleCombo.Buffer instance allocated on the specified MemoryStack.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • calloc

      public static NkStyleCombo.Buffer calloc(int capacity, MemoryStack stack)
      Returns a new NkStyleCombo.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • nnormal

      public static NkStyleItem nnormal(long struct)
      Unsafe version of normal().
    • nhover

      public static NkStyleItem nhover(long struct)
      Unsafe version of hover().
    • nactive

      public static NkStyleItem nactive(long struct)
      Unsafe version of active().
    • nborder_color

      public static NkColor nborder_color(long struct)
      Unsafe version of border_color().
    • nlabel_normal

      public static NkColor nlabel_normal(long struct)
      Unsafe version of label_normal().
    • nlabel_hover

      public static NkColor nlabel_hover(long struct)
      Unsafe version of label_hover().
    • nlabel_active

      public static NkColor nlabel_active(long struct)
      Unsafe version of label_active().
    • nsymbol_normal

      public static NkColor nsymbol_normal(long struct)
      Unsafe version of symbol_normal().
    • nsymbol_hover

      public static NkColor nsymbol_hover(long struct)
      Unsafe version of symbol_hover().
    • nsymbol_active

      public static NkColor nsymbol_active(long struct)
      Unsafe version of symbol_active().
    • nbutton

      public static NkStyleButton nbutton(long struct)
      Unsafe version of button().
    • nsym_normal

      public static int nsym_normal(long struct)
      Unsafe version of sym_normal().
    • nsym_hover

      public static int nsym_hover(long struct)
      Unsafe version of sym_hover().
    • nsym_active

      public static int nsym_active(long struct)
      Unsafe version of sym_active().
    • nborder

      public static float nborder(long struct)
      Unsafe version of border().
    • nrounding

      public static float nrounding(long struct)
      Unsafe version of rounding().
    • ncontent_padding

      public static NkVec2 ncontent_padding(long struct)
      Unsafe version of content_padding().
    • nbutton_padding

      public static NkVec2 nbutton_padding(long struct)
      Unsafe version of button_padding().
    • nspacing

      public static NkVec2 nspacing(long struct)
      Unsafe version of spacing().
    • ncolor_factor

      public static float ncolor_factor(long struct)
      Unsafe version of color_factor().
    • ndisabled_factor

      public static float ndisabled_factor(long struct)
      Unsafe version of disabled_factor().
    • nnormal

      public static void nnormal(long struct, NkStyleItem value)
      Unsafe version of normal.
    • nhover

      public static void nhover(long struct, NkStyleItem value)
      Unsafe version of hover.
    • nactive

      public static void nactive(long struct, NkStyleItem value)
      Unsafe version of active.
    • nborder_color

      public static void nborder_color(long struct, NkColor value)
      Unsafe version of border_color.
    • nlabel_normal

      public static void nlabel_normal(long struct, NkColor value)
      Unsafe version of label_normal.
    • nlabel_hover

      public static void nlabel_hover(long struct, NkColor value)
      Unsafe version of label_hover.
    • nlabel_active

      public static void nlabel_active(long struct, NkColor value)
      Unsafe version of label_active.
    • nsymbol_normal

      public static void nsymbol_normal(long struct, NkColor value)
      Unsafe version of symbol_normal.
    • nsymbol_hover

      public static void nsymbol_hover(long struct, NkColor value)
      Unsafe version of symbol_hover.
    • nsymbol_active

      public static void nsymbol_active(long struct, NkColor value)
      Unsafe version of symbol_active.
    • nbutton

      public static void nbutton(long struct, NkStyleButton value)
      Unsafe version of button.
    • nsym_normal

      public static void nsym_normal(long struct, int value)
      Unsafe version of sym_normal.
    • nsym_hover

      public static void nsym_hover(long struct, int value)
      Unsafe version of sym_hover.
    • nsym_active

      public static void nsym_active(long struct, int value)
      Unsafe version of sym_active.
    • nborder

      public static void nborder(long struct, float value)
      Unsafe version of border.
    • nrounding

      public static void nrounding(long struct, float value)
      Unsafe version of rounding.
    • ncontent_padding

      public static void ncontent_padding(long struct, NkVec2 value)
      Unsafe version of content_padding.
    • nbutton_padding

      public static void nbutton_padding(long struct, NkVec2 value)
      Unsafe version of button_padding.
    • nspacing

      public static void nspacing(long struct, NkVec2 value)
      Unsafe version of spacing.
    • ncolor_factor

      public static void ncolor_factor(long struct, float value)
      Unsafe version of color_factor.
    • ndisabled_factor

      public static void ndisabled_factor(long struct, float value)
      Unsafe version of disabled_factor.