Top Description Inners Fields Constructors Methods
org.lwjgl.nuklear

public Class NkStyleItemData

extends Struct<NkStyleItemData>
implements NativeResource
Class Inheritance
All Implemented Interfaces
org.lwjgl.system.NativeResource, java.lang.AutoCloseable
Annotations
@NativeType:union nk_style_item_data
Imports
javax.annotation.*, java.nio.*, org.lwjgl.*, org.lwjgl.system.*

Layout


union nk_style_item_data {
    struct nk_color color;
    struct nk_image image;
    struct nk_nine_slice slice;
}

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
public static final int
ALIGNOF

The struct alignment in bytes.

public static final int
COLOR

The struct member offsets.

public static final int
IMAGE

The struct member offsets.

public static final int
SIZEOF

The struct size in bytes.

public static final int
SLICE

The struct member offsets.

Inherited from org.lwjgl.system.Struct:
containerDEFAULT_ALIGN_ASDEFAULT_PACK_ALIGNMENT

Constructor Summary

AccessConstructor and Description
protected
NkStyleItemData(long address, ByteBuffer container)

public
NkStyleItemData(ByteBuffer container)

Creates a NkStyleItemData instance at the current position of the specified ByteBuffer container.

Method Summary

Modifier and TypeMethod and Description
public static NkStyleItemData
calloc()

Returns a new NkStyleItemData instance allocated with memCalloc.

public static NkStyleItemData.Buffer
calloc(int
the buffer capacity
capacity
)

Returns a new NkStyleItemData.Buffer instance allocated with memCalloc.

public static NkStyleItemData
calloc(MemoryStack
the stack from which to allocate
stack
)

Returns a new NkStyleItemData instance allocated on the specified MemoryStack and initializes all its bits to zero.

public static NkStyleItemData.Buffer
calloc(int
the buffer capacity
capacity
,
MemoryStack
the stack from which to allocate
stack
)

Returns a new NkStyleItemData.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.

public static NkStyleItemData
callocStack()

Deprecated
Deprecated for removal in 3.4.0.
public static NkStyleItemData
callocStack(MemoryStack stack)

Deprecated
Deprecated for removal in 3.4.0.
public static NkStyleItemData.Buffer
callocStack(int capacity)

Deprecated
Deprecated for removal in 3.4.0.
public static NkStyleItemData.Buffer
callocStack(int capacity, MemoryStack stack)

Deprecated
Deprecated for removal in 3.4.0.
public NkColor

Returns:

a NkColor view of the color field.
color
()

public NkStyleItemData
color(NkColor value)

Copies the specified NkColor to the color field.

public NkStyleItemData
color(Consumer<NkColor> consumer)

Passes the color field to the specified Consumer.

protected NkStyleItemData
create(long
the struct memory address
address
,
ByteBuffer
an optional container buffer, to be referenced strongly by the struct instance.
container
)

Implements abstract org.lwjgl.system.Struct.create.

Similar to the constructor, but returns the exact type of the Struct subclass.
public static NkStyleItemData
create()

Returns a new NkStyleItemData instance allocated with BufferUtils.

public static NkStyleItemData
create(long address)

Returns a new NkStyleItemData instance for the specified memory address.

public static NkStyleItemData.Buffer
create(int
the buffer capacity
capacity
)

Returns a new NkStyleItemData.Buffer instance allocated with BufferUtils.

public static NkStyleItemData.Buffer
create(long
the memory address
address
,
int
the buffer capacity
capacity
)

Create a NkStyleItemData.Buffer instance at the specified memory.

public static NkStyleItemData
createSafe(long address)

Like create, but returns null if address is NULL.

public static NkStyleItemData.Buffer
createSafe(long address, int capacity)

Like create, but returns null if address is NULL.

public NkImage

Returns:

a NkImage view of the image field.
image
()

public NkStyleItemData
image(NkImage value)

Copies the specified NkImage to the image field.

public NkStyleItemData
image(Consumer<NkImage> consumer)

Passes the image field to the specified Consumer.

public static NkStyleItemData
malloc()

Returns a new NkStyleItemData instance allocated with memAlloc.

public static NkStyleItemData.Buffer
malloc(int
the buffer capacity
capacity
)

Returns a new NkStyleItemData.Buffer instance allocated with memAlloc.

public static NkStyleItemData
malloc(MemoryStack
the stack from which to allocate
stack
)

Returns a new NkStyleItemData instance allocated on the specified MemoryStack.

public static NkStyleItemData.Buffer
malloc(int
the buffer capacity
capacity
,
MemoryStack
the stack from which to allocate
stack
)

Returns a new NkStyleItemData.Buffer instance allocated on the specified MemoryStack.

public static NkStyleItemData
mallocStack()

Deprecated
Deprecated for removal in 3.4.0.
public static NkStyleItemData
mallocStack(MemoryStack stack)

Deprecated
Deprecated for removal in 3.4.0.
public static NkStyleItemData.Buffer
mallocStack(int capacity)

Deprecated
Deprecated for removal in 3.4.0.
public static NkStyleItemData.Buffer
mallocStack(int capacity, MemoryStack stack)

Deprecated
Deprecated for removal in 3.4.0.
public static NkColor
ncolor(long struct)

Unsafe version of color.

public static void
ncolor(long struct, NkColor value)

Unsafe version of color.

public static NkImage
nimage(long struct)

Unsafe version of image.

public static void
nimage(long struct, NkImage value)

Unsafe version of image.

public static NkNineSlice
nslice$(long struct)

Unsafe version of slice$.

public static void
nslice$(long struct, NkNineSlice value)

Unsafe version of slice$.

public NkStyleItemData

Returns:

this struct
set
(NkStyleItemData
the source struct
src
)

Copies the specified struct data to this struct.

public int
sizeof()

Implements abstract org.lwjgl.system.Struct.sizeof.

Returns sizeof(struct).
public NkNineSlice

Returns:

a NkNineSlice view of the slice field.
slice$
()

public NkStyleItemData
slice$(NkNineSlice value)

Copies the specified NkNineSlice to the slice field.

public NkStyleItemData
slice$(Consumer<NkNineSlice> consumer)

Passes the slice field to the specified Consumer.

Inherited from org.lwjgl.system.Struct:
__array__array__array__checkContainer__checkMalloc__create__getContainer__getContainer__member__member__member__padding__padding__struct__struct__union__unionclearfreeisNullvalidate

Field Detail

ALIGNOFback to summary
public static final int ALIGNOF

The struct alignment in bytes.

COLORback to summary
public static final int COLOR

The struct member offsets.

IMAGEback to summary
public static final int IMAGE

The struct member offsets.

SIZEOFback to summary
public static final int SIZEOF

The struct size in bytes.

SLICEback to summary
public static final int SLICE

The struct member offsets.

Constructor Detail

NkStyleItemDataback to summary
protected NkStyleItemData(long address, ByteBuffer container)
NkStyleItemDataback to summary
public NkStyleItemData(ByteBuffer container)

Creates a NkStyleItemData 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 Detail

callocback to summary
public static NkStyleItemData calloc()

Returns a new NkStyleItemData instance allocated with memCalloc. The instance must be explicitly freed.

callocback to summary
public static NkStyleItemData.Buffer calloc(int capacity)

Returns a new NkStyleItemData.Buffer instance allocated with memCalloc. The instance must be explicitly freed.

Parameters
capacity:int

the buffer capacity

callocback to summary
public static NkStyleItemData calloc(MemoryStack stack)

Returns a new NkStyleItemData instance allocated on the specified MemoryStack and initializes all its bits to zero.

Parameters
stack:MemoryStack

the stack from which to allocate

callocback to summary
public static NkStyleItemData.Buffer calloc(int capacity, MemoryStack stack)

Returns a new NkStyleItemData.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.

Parameters
capacity:int

the buffer capacity

stack:MemoryStack

the stack from which to allocate

callocStackback to summary
public static NkStyleItemData callocStack()

Deprecated

Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.

Annotations
@Deprecated
callocStackback to summary
public static NkStyleItemData callocStack(MemoryStack stack)

Deprecated

Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.

Annotations
@Deprecated
callocStackback to summary
public static NkStyleItemData.Buffer callocStack(int capacity)

Deprecated

Deprecated for removal in 3.4.0. Use calloc(int, MemoryStack) instead.

Annotations
@Deprecated
callocStackback to summary
public static NkStyleItemData.Buffer callocStack(int capacity, MemoryStack stack)

Deprecated

Deprecated for removal in 3.4.0. Use calloc(int, MemoryStack) instead.

Annotations
@Deprecated
colorback to summary
public NkColor color()
Returns:NkColor

a NkColor view of the color field.

Annotations
@NativeType:struct nk_color
colorback to summary
public NkStyleItemData color(NkColor value)

Copies the specified NkColor to the color field.

colorback to summary
public NkStyleItemData color(Consumer<NkColor> consumer)

Passes the color field to the specified Consumer.

createback to summary
protected NkStyleItemData create(long address, ByteBuffer container)

Implements abstract org.lwjgl.system.Struct.create.

Doc from org.lwjgl.system.Struct.create.

Similar to the constructor, but returns the exact type of the Struct subclass.

Effectively, every Struct instance is a factory for more instances of the same type. This is used by StructBuffer.

Parameters
address:long

the struct memory address

container:ByteBuffer

an optional container buffer, to be referenced strongly by the struct instance.

Annotations
@Override
createback to summary
public static NkStyleItemData create()

Returns a new NkStyleItemData instance allocated with BufferUtils.

createback to summary
public static NkStyleItemData create(long address)

Returns a new NkStyleItemData instance for the specified memory address.

createback to summary
public static NkStyleItemData.Buffer create(int capacity)

Returns a new NkStyleItemData.Buffer instance allocated with BufferUtils.

Parameters
capacity:int

the buffer capacity

createback to summary
public static NkStyleItemData.Buffer create(long address, int capacity)

Create a NkStyleItemData.Buffer instance at the specified memory.

Parameters
address:long

the memory address

capacity:int

the buffer capacity

createSafeback to summary
public static NkStyleItemData createSafe(long address)

Like create, but returns null if address is NULL.

Annotations
@Nullable
createSafeback to summary
public static NkStyleItemData.Buffer createSafe(long address, int capacity)

Like create, but returns null if address is NULL.

Annotations
@Nullable
imageback to summary
public NkImage image()
Returns:NkImage

a NkImage view of the image field.

Annotations
@NativeType:struct nk_image
imageback to summary
public NkStyleItemData image(NkImage value)

Copies the specified NkImage to the image field.

imageback to summary
public NkStyleItemData image(Consumer<NkImage> consumer)

Passes the image field to the specified Consumer.

mallocback to summary
public static NkStyleItemData malloc()

Returns a new NkStyleItemData instance allocated with memAlloc. The instance must be explicitly freed.

mallocback to summary
public static NkStyleItemData.Buffer malloc(int capacity)

Returns a new NkStyleItemData.Buffer instance allocated with memAlloc. The instance must be explicitly freed.

Parameters
capacity:int

the buffer capacity

mallocback to summary
public static NkStyleItemData malloc(MemoryStack stack)

Returns a new NkStyleItemData instance allocated on the specified MemoryStack.

Parameters
stack:MemoryStack

the stack from which to allocate

mallocback to summary
public static NkStyleItemData.Buffer malloc(int capacity, MemoryStack stack)

Returns a new NkStyleItemData.Buffer instance allocated on the specified MemoryStack.

Parameters
capacity:int

the buffer capacity

stack:MemoryStack

the stack from which to allocate

mallocStackback to summary
public static NkStyleItemData mallocStack()

Deprecated

Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.

Annotations
@Deprecated
mallocStackback to summary
public static NkStyleItemData mallocStack(MemoryStack stack)

Deprecated

Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.

Annotations
@Deprecated
mallocStackback to summary
public static NkStyleItemData.Buffer mallocStack(int capacity)

Deprecated

Deprecated for removal in 3.4.0. Use malloc(int, MemoryStack) instead.

Annotations
@Deprecated
mallocStackback to summary
public static NkStyleItemData.Buffer mallocStack(int capacity, MemoryStack stack)

Deprecated

Deprecated for removal in 3.4.0. Use malloc(int, MemoryStack) instead.

Annotations
@Deprecated
ncolorback to summary
public static NkColor ncolor(long struct)

Unsafe version of color.

ncolorback to summary
public static void ncolor(long struct, NkColor value)

Unsafe version of color.

nimageback to summary
public static NkImage nimage(long struct)

Unsafe version of image.

nimageback to summary
public static void nimage(long struct, NkImage value)

Unsafe version of image.

nslice$back to summary
public static NkNineSlice nslice$(long struct)

Unsafe version of slice$.

nslice$back to summary
public static void nslice$(long struct, NkNineSlice value)

Unsafe version of slice$.

setback to summary
public NkStyleItemData set(NkStyleItemData src)

Copies the specified struct data to this struct.

Parameters
src:NkStyleItemData

the source struct

Returns:NkStyleItemData

this struct

sizeofback to summary
public int sizeof()

Implements abstract org.lwjgl.system.Struct.sizeof.

Doc from org.lwjgl.system.Struct.sizeof.

Returns sizeof(struct).

Annotations
@Override
slice$back to summary
public NkNineSlice slice$()
Returns:NkNineSlice

a NkNineSlice view of the slice field.

Annotations
@NativeType:struct nk_nine_slice
slice$back to summary
public NkStyleItemData slice$(NkNineSlice value)

Copies the specified NkNineSlice to the slice field.

slice$back to summary
public NkStyleItemData slice$(Consumer<NkNineSlice> consumer)

Passes the slice field to the specified Consumer.

org.lwjgl.nuklear back to summary

public Class NkStyleItemData.Buffer

extends StructBuffer<NkStyleItemData, NkStyleItemData.Buffer>
implements NativeResource
Class Inheritance
All Implemented Interfaces
org.lwjgl.system.NativeResource, java.lang.AutoCloseable

An array of NkStyleItemData structs.

Field Summary

Modifier and TypeField and Description
private static final NkStyleItemData

Constructor Summary

AccessConstructor and Description
public
Buffer(ByteBuffer container)

Creates a new NkStyleItemData.Buffer instance backed by the specified container.

public
Buffer(long address, int cap)

pack-priv
Buffer(long address, ByteBuffer container, int mark, int pos, int lim, int cap)

Method Summary

Modifier and TypeMethod and Description
public NkColor

Returns:

a NkColor view of the color field.
color
()

public NkStyleItemData.Buffer
color(NkColor value)

Copies the specified NkColor to the color field.

public NkStyleItemData.Buffer
color(Consumer<NkColor> consumer)

Passes the color field to the specified Consumer.

protected NkStyleItemData
public NkImage

Returns:

a NkImage view of the image field.
image
()

public NkStyleItemData.Buffer
image(NkImage value)

Copies the specified NkImage to the image field.

public NkStyleItemData.Buffer
image(Consumer<NkImage> consumer)

Passes the image field to the specified Consumer.

protected NkStyleItemData.Buffer
public NkNineSlice

Returns:

a NkNineSlice view of the slice field.
slice$
()

public NkStyleItemData.Buffer
slice$(NkNineSlice value)

Copies the specified NkNineSlice to the slice field.

public NkStyleItemData.Buffer
slice$(Consumer<NkNineSlice> consumer)

Passes the slice field to the specified Consumer.

Inherited from org.lwjgl.system.StructBuffer:
applyapplyforEachgetgetgetgetiteratorparallelStreamputputsizeofspliteratorstream

Field Detail

ELEMENT_FACTORYback to summary
private static final NkStyleItemData ELEMENT_FACTORY

Constructor Detail

Bufferback to summary
public Buffer(ByteBuffer container)

Creates a new NkStyleItemData.Buffer instance backed by the specified container.

Changes to the container's content will be visible to the struct buffer instance and vice versa. The two buffers' position, limit, and mark values will be independent. The new buffer's position will be zero, its capacity and its limit will be the number of bytes remaining in this buffer divided by NkStyleItemData#SIZEOF, and its mark will be undefined.

The created buffer instance holds a strong reference to the container object.

Bufferback to summary
public Buffer(long address, int cap)
Bufferback to summary
pack-priv Buffer(long address, ByteBuffer container, int mark, int pos, int lim, int cap)

Method Detail

colorback to summary
public NkColor color()
Returns:NkColor

a NkColor view of the color field.

Annotations
@NativeType:struct nk_color
colorback to summary
public NkStyleItemData.Buffer color(NkColor value)

Copies the specified NkColor to the color field.

colorback to summary
public NkStyleItemData.Buffer color(Consumer<NkColor> consumer)

Passes the color field to the specified Consumer.

getElementFactoryback to summary
protected NkStyleItemData getElementFactory()

Implements abstract org.lwjgl.system.StructBuffer.getElementFactory.

Annotations
@Override
imageback to summary
public NkImage image()
Returns:NkImage

a NkImage view of the image field.

Annotations
@NativeType:struct nk_image
imageback to summary
public NkStyleItemData.Buffer image(NkImage value)

Copies the specified NkImage to the image field.

imageback to summary
public NkStyleItemData.Buffer image(Consumer<NkImage> consumer)

Passes the image field to the specified Consumer.

selfback to summary
protected NkStyleItemData.Buffer self()

Implements abstract org.lwjgl.system.CustomBuffer.self.

Annotations
@Override
slice$back to summary
public NkNineSlice slice$()
Returns:NkNineSlice

a NkNineSlice view of the slice field.

Annotations
@NativeType:struct nk_nine_slice
slice$back to summary
public NkStyleItemData.Buffer slice$(NkNineSlice value)

Copies the specified NkNineSlice to the slice field.

slice$back to summary
public NkStyleItemData.Buffer slice$(Consumer<NkNineSlice> consumer)

Passes the slice field to the specified Consumer.