Top Description Inners Fields Constructors Methods
org.lwjgl.system.windows

public Class MONITORINFOEX

extends Struct<MONITORINFOEX>
implements NativeResource
Class Inheritance
All Implemented Interfaces
org.lwjgl.system.NativeResource, java.lang.AutoCloseable
Imports
javax.annotation.*, java.nio.*, org.lwjgl.*, org.lwjgl.system.*

Contains information about a display monitor.

Layout


struct MONITORINFOEX {
    DWORD cbSize;
    RECT rcMonitor;
    RECT rcWork;
    DWORD dwFlags;
    TCHAR szDevice[32];
}

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
MONITORINFOEX.Buffer

An array of MONITORINFOEX structs.

Field Summary

Modifier and TypeField and Description
public static final int
ALIGNOF

The struct alignment in bytes.

public static final int
CBSIZE

The struct member offsets.

public static final int
DWFLAGS

The struct member offsets.

public static final int
RCMONITOR

The struct member offsets.

public static final int
RCWORK

The struct member offsets.

public static final int
SIZEOF

The struct size in bytes.

public static final int
SZDEVICE

The struct member offsets.

Inherited from org.lwjgl.system.Struct:
containerDEFAULT_ALIGN_ASDEFAULT_PACK_ALIGNMENT

Constructor Summary

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

public
MONITORINFOEX(ByteBuffer container)

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

Method Summary

Modifier and TypeMethod and Description
public static MONITORINFOEX
calloc()

Returns a new MONITORINFOEX instance allocated with memCalloc.

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

Returns a new MONITORINFOEX.Buffer instance allocated with memCalloc.

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

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

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

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

public static MONITORINFOEX
callocStack()

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

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

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

Deprecated
Deprecated for removal in 3.4.0.
public int
cbSize()

the size, in bytes, of the structure.

public MONITORINFOEX
cbSize(int value)

Sets the specified value to the cbSize field.

protected MONITORINFOEX
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 MONITORINFOEX
create()

Returns a new MONITORINFOEX instance allocated with BufferUtils.

public static MONITORINFOEX
create(long address)

Returns a new MONITORINFOEX instance for the specified memory address.

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

Returns a new MONITORINFOEX.Buffer instance allocated with BufferUtils.

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

Create a MONITORINFOEX.Buffer instance at the specified memory.

public static MONITORINFOEX
createSafe(long address)

Like create, but returns null if address is NULL.

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

Like create, but returns null if address is NULL.

public int
dwFlags()

the attributes of the display monitor.

public static MONITORINFOEX
malloc()

Returns a new MONITORINFOEX instance allocated with memAlloc.

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

Returns a new MONITORINFOEX.Buffer instance allocated with memAlloc.

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

Returns a new MONITORINFOEX instance allocated on the specified MemoryStack.

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

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

public static MONITORINFOEX
mallocStack()

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

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

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

Deprecated
Deprecated for removal in 3.4.0.
public static int
ncbSize(long struct)

Unsafe version of cbSize.

public static void
ncbSize(long struct, int value)

Unsafe version of cbSize.

public static int
ndwFlags(long struct)

Unsafe version of dwFlags.

public static RECT
nrcMonitor(long struct)

Unsafe version of rcMonitor.

public static RECT
nrcWork(long struct)

Unsafe version of rcWork.

public static ByteBuffer
nszDevice(long struct)

Unsafe version of szDevice.

public static String
nszDeviceString(long struct)

Unsafe version of szDeviceString.

public RECT
rcMonitor()

a RECT structure that specifies the display monitor rectangle, expressed in virtual-screen coordinates.

public RECT
rcWork()

a RECT structure that specifies the work area rectangle of the display monitor that can be used by applications, expressed in virtual-screen coordinates.

public MONITORINFOEX

Returns:

this struct
set
(MONITORINFOEX
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 ByteBuffer
szDevice()

a string that specifies the device name of the monitor being used

public String
szDeviceString()

a string that specifies the device name of the monitor being used

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.

CBSIZEback to summary
public static final int CBSIZE

The struct member offsets.

DWFLAGSback to summary
public static final int DWFLAGS

The struct member offsets.

RCMONITORback to summary
public static final int RCMONITOR

The struct member offsets.

RCWORKback to summary
public static final int RCWORK

The struct member offsets.

SIZEOFback to summary
public static final int SIZEOF

The struct size in bytes.

SZDEVICEback to summary
public static final int SZDEVICE

The struct member offsets.

Constructor Detail

MONITORINFOEXback to summary
protected MONITORINFOEX(long address, ByteBuffer container)
MONITORINFOEXback to summary
public MONITORINFOEX(ByteBuffer container)

Creates a MONITORINFOEX 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 MONITORINFOEX calloc()

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

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

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

Parameters
capacity:int

the buffer capacity

callocback to summary
public static MONITORINFOEX calloc(MemoryStack stack)

Returns a new MONITORINFOEX 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 MONITORINFOEX.Buffer calloc(int capacity, MemoryStack stack)

Returns a new MONITORINFOEX.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 MONITORINFOEX callocStack()

Deprecated

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

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

Deprecated

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

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

Deprecated

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

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

Deprecated

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

Annotations
@Deprecated
cbSizeback to summary
public int cbSize()

the size, in bytes, of the structure.

Set this member to SIZEOF before calling the User32#GetMonitorInfo function. Doing so lets the function determine the type of structure you are passing to it.

Annotations
@NativeType:DWORD
cbSizeback to summary
public MONITORINFOEX cbSize(int value)

Sets the specified value to the cbSize field.

createback to summary
protected MONITORINFOEX 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 MONITORINFOEX create()

Returns a new MONITORINFOEX instance allocated with BufferUtils.

createback to summary
public static MONITORINFOEX create(long address)

Returns a new MONITORINFOEX instance for the specified memory address.

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

Returns a new MONITORINFOEX.Buffer instance allocated with BufferUtils.

Parameters
capacity:int

the buffer capacity

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

Create a MONITORINFOEX.Buffer instance at the specified memory.

Parameters
address:long

the memory address

capacity:int

the buffer capacity

createSafeback to summary
public static MONITORINFOEX createSafe(long address)

Like create, but returns null if address is NULL.

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

Like create, but returns null if address is NULL.

Annotations
@Nullable
dwFlagsback to summary
public int dwFlags()

the attributes of the display monitor. May be:
User32#MONITORINFOF_PRIMARY

Annotations
@NativeType:DWORD
mallocback to summary
public static MONITORINFOEX malloc()

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

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

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

Parameters
capacity:int

the buffer capacity

mallocback to summary
public static MONITORINFOEX malloc(MemoryStack stack)

Returns a new MONITORINFOEX instance allocated on the specified MemoryStack.

Parameters
stack:MemoryStack

the stack from which to allocate

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

Returns a new MONITORINFOEX.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 MONITORINFOEX mallocStack()

Deprecated

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

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

Deprecated

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

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

Deprecated

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

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

Deprecated

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

Annotations
@Deprecated
ncbSizeback to summary
public static int ncbSize(long struct)

Unsafe version of cbSize.

ncbSizeback to summary
public static void ncbSize(long struct, int value)

Unsafe version of cbSize.

ndwFlagsback to summary
public static int ndwFlags(long struct)

Unsafe version of dwFlags.

nrcMonitorback to summary
public static RECT nrcMonitor(long struct)

Unsafe version of rcMonitor.

nrcWorkback to summary
public static RECT nrcWork(long struct)

Unsafe version of rcWork.

nszDeviceback to summary
public static ByteBuffer nszDevice(long struct)

Unsafe version of szDevice.

nszDeviceStringback to summary
public static String nszDeviceString(long struct)

Unsafe version of szDeviceString.

rcMonitorback to summary
public RECT rcMonitor()

a RECT structure that specifies the display monitor rectangle, expressed in virtual-screen coordinates. Note that if the monitor is not the primary display monitor, some of the rectangle's coordinates may be negative values.

rcWorkback to summary
public RECT rcWork()

a RECT structure that specifies the work area rectangle of the display monitor that can be used by applications, expressed in virtual-screen coordinates. Windows uses this rectangle to maximize an application on the monitor. The rest of the area in rcMonitor contains system windows such as the task bar and side bars. Note that if the monitor is not the primary display monitor, some of the rectangle's coordinates may be negative values.

setback to summary
public MONITORINFOEX set(MONITORINFOEX src)

Copies the specified struct data to this struct.

Parameters
src:MONITORINFOEX

the source struct

Returns:MONITORINFOEX

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
szDeviceback to summary
public ByteBuffer szDevice()

a string that specifies the device name of the monitor being used

Annotations
@NativeType:TCHAR[32]
szDeviceStringback to summary
public String szDeviceString()

a string that specifies the device name of the monitor being used

Annotations
@NativeType:TCHAR[32]
org.lwjgl.system.windows back to summary

public Class MONITORINFOEX.Buffer

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

An array of MONITORINFOEX structs.

Field Summary

Modifier and TypeField and Description
private static final MONITORINFOEX

Constructor Summary

AccessConstructor and Description
public
Buffer(ByteBuffer container)

Creates a new MONITORINFOEX.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 int

Returns:

the value of the MONITORINFOEX#cbSize field.
cbSize
()

public MONITORINFOEX.Buffer
cbSize(int value)

Sets the specified value to the MONITORINFOEX#cbSize field.

public int

Returns:

the value of the MONITORINFOEX#dwFlags field.
dwFlags
()

protected MONITORINFOEX
public RECT

Returns:

a RECT view of the MONITORINFOEX#rcMonitor field.
rcMonitor
()

public RECT

Returns:

a RECT view of the MONITORINFOEX#rcWork field.
rcWork
()

protected MONITORINFOEX.Buffer
public ByteBuffer

Returns:

a ByteBuffer view of the MONITORINFOEX#szDevice field.
szDevice
()

public String

Returns:

the null-terminated string stored in the MONITORINFOEX#szDevice field.
szDeviceString
()

Inherited from org.lwjgl.system.StructBuffer:
applyapplyforEachgetgetgetgetiteratorparallelStreamputputsizeofspliteratorstream

Field Detail

ELEMENT_FACTORYback to summary
private static final MONITORINFOEX ELEMENT_FACTORY

Constructor Detail

Bufferback to summary
public Buffer(ByteBuffer container)

Creates a new MONITORINFOEX.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 MONITORINFOEX#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

cbSizeback to summary
public int cbSize()
Returns:int

the value of the MONITORINFOEX#cbSize field.

Annotations
@NativeType:DWORD
cbSizeback to summary
public MONITORINFOEX.Buffer cbSize(int value)

Sets the specified value to the MONITORINFOEX#cbSize field.

dwFlagsback to summary
public int dwFlags()
Returns:int

the value of the MONITORINFOEX#dwFlags field.

Annotations
@NativeType:DWORD
getElementFactoryback to summary
protected MONITORINFOEX getElementFactory()

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

Annotations
@Override
rcMonitorback to summary
public RECT rcMonitor()
Returns:RECT

a RECT view of the MONITORINFOEX#rcMonitor field.

rcWorkback to summary
public RECT rcWork()
Returns:RECT

a RECT view of the MONITORINFOEX#rcWork field.

selfback to summary
protected MONITORINFOEX.Buffer self()

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

Annotations
@Override
szDeviceback to summary
public ByteBuffer szDevice()
Returns:ByteBuffer

a ByteBuffer view of the MONITORINFOEX#szDevice field.

Annotations
@NativeType:TCHAR[32]
szDeviceStringback to summary
public String szDeviceString()
Returns:String

the null-terminated string stored in the MONITORINFOEX#szDevice field.

Annotations
@NativeType:TCHAR[32]