Class NkRowLayout

All Implemented Interfaces:
Pointer

public class NkRowLayout extends Struct<NkRowLayout>

Layout


 struct nk_row_layout {
     enum nk_panel_row_layout_type type();
     int index;
     float height;
     float min_height;
     int columns;
     float const * ratio;
     float item_width;
     float item_height;
     float item_offset;
     float filled;
     struct nk_rect item;
     int tree_depth;
     float templates[16];
 }
  • Field Details

    • SIZEOF

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

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

      public static final int TYPE
      The struct member offsets.
    • INDEX

      public static final int INDEX
      The struct member offsets.
    • HEIGHT

      public static final int HEIGHT
      The struct member offsets.
    • MIN_HEIGHT

      public static final int MIN_HEIGHT
      The struct member offsets.
    • COLUMNS

      public static final int COLUMNS
      The struct member offsets.
    • RATIO

      public static final int RATIO
      The struct member offsets.
    • ITEM_WIDTH

      public static final int ITEM_WIDTH
      The struct member offsets.
    • ITEM_HEIGHT

      public static final int ITEM_HEIGHT
      The struct member offsets.
    • ITEM_OFFSET

      public static final int ITEM_OFFSET
      The struct member offsets.
    • FILLED

      public static final int FILLED
      The struct member offsets.
    • ITEM

      public static final int ITEM
      The struct member offsets.
    • TREE_DEPTH

      public static final int TREE_DEPTH
      The struct member offsets.
    • TEMPLATES

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

    • NkRowLayout

      public NkRowLayout(ByteBuffer container)
      Creates a NkRowLayout 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<NkRowLayout>
    • type

      public int type()
    • index

      public int index()
      Returns:
      the value of the index field.
    • height

      public float height()
      Returns:
      the value of the height field.
    • min_height

      public float min_height()
      Returns:
      the value of the min_height field.
    • columns

      public int columns()
      Returns:
      the value of the columns field.
    • ratio

      public FloatBuffer ratio(int capacity)
      Parameters:
      capacity - the number of elements in the returned buffer
      Returns:
      a FloatBuffer view of the data pointed to by the ratio field.
    • item_width

      public float item_width()
      Returns:
      the value of the item_width field.
    • item_height

      public float item_height()
      Returns:
      the value of the item_height field.
    • item_offset

      public float item_offset()
      Returns:
      the value of the item_offset field.
    • filled

      public float filled()
      Returns:
      the value of the filled field.
    • item

      public NkRect item()
      Returns:
      a NkRect view of the item field.
    • tree_depth

      public int tree_depth()
      Returns:
      the value of the tree_depth field.
    • templates

      public FloatBuffer templates()
      Returns:
      a FloatBuffer view of the templates field.
    • templates

      public float templates(int index)
      Returns:
      the value at the specified index of the templates field.
    • create

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

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

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

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

      public static int ntype(long struct)
      Unsafe version of type().
    • nindex

      public static int nindex(long struct)
      Unsafe version of index().
    • nheight

      public static float nheight(long struct)
      Unsafe version of height().
    • nmin_height

      public static float nmin_height(long struct)
      Unsafe version of min_height().
    • ncolumns

      public static int ncolumns(long struct)
      Unsafe version of columns().
    • nratio

      public static FloatBuffer nratio(long struct, int capacity)
      Unsafe version of ratio.
    • nitem_width

      public static float nitem_width(long struct)
      Unsafe version of item_width().
    • nitem_height

      public static float nitem_height(long struct)
      Unsafe version of item_height().
    • nitem_offset

      public static float nitem_offset(long struct)
      Unsafe version of item_offset().
    • nfilled

      public static float nfilled(long struct)
      Unsafe version of filled().
    • nitem

      public static NkRect nitem(long struct)
      Unsafe version of item().
    • ntree_depth

      public static int ntree_depth(long struct)
      Unsafe version of tree_depth().
    • ntemplates

      public static FloatBuffer ntemplates(long struct)
      Unsafe version of templates().
    • ntemplates

      public static float ntemplates(long struct, int index)
      Unsafe version of templates.