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

public Class User32

extends Object
Class Inheritance
Imports
javax.annotation.*, java.nio.*, org.lwjgl.system.*

Native bindings to WinUser.h and user32.dll.

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
User32.Functions

Contains the function pointers loaded from the user32 SharedLibrary.

Field Summary

Modifier and TypeField and Description
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
CS_BYTEALIGNCLIENT

Class styles

public static final int
CS_BYTEALIGNWINDOW

Class styles

public static final int
CS_CLASSDC

Class styles

public static final int
CS_DBLCLKS

Class styles

public static final int
CS_DROPSHADOW

Class styles

public static final int
CS_GLOBALCLASS

Class styles

public static final int
CS_HREDRAW

Class styles

public static final int
CS_IME

Class styles

public static final int
CS_NOCLOSE

Class styles

public static final int
CS_OWNDC

Class styles

public static final int
CS_PARENTDC

Class styles

public static final int
CS_SAVEBITS

Class styles

public static final int
CS_VREDRAW

Class styles

public static final int
CW_USEDEFAULT

May be used in CreateWindowEx for the x, y, width, height parameters.

public static final int
DBT_APPYBEGIN

WM_DEVICECHANGE message wParam params.

public static final int
DBT_APPYEND

WM_DEVICECHANGE message wParam params.

public static final int
public static final int
DBT_CONFIGCHANGED

WM_DEVICECHANGE message wParam params.

public static final int
DBT_DEVNODES_CHANGED

WM_DEVICECHANGE message wParam params.

public static final int
DBT_MONITORCHANGE

WM_DEVICECHANGE message wParam params.

public static final int
DBT_QUERYCHANGECONFIG

WM_DEVICECHANGE message wParam params.

public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final long
public static final long
DPI_AWARENESS_CONTEXT_PER_MONITOR_AWARE_V2

Also known as Per Monitor v2.

public static final long
public static final long
public static final int
DPI_AWARENESS_INVALID

Identifies the dots per inch (dpi) setting for a thread, process, or window.

public static final int
DPI_AWARENESS_PER_MONITOR_AWARE

Identifies the dots per inch (dpi) setting for a thread, process, or window.

public static final int
DPI_AWARENESS_SYSTEM_AWARE

Identifies the dots per inch (dpi) setting for a thread, process, or window.

public static final int
DPI_AWARENESS_UNAWARE

Identifies the dots per inch (dpi) setting for a thread, process, or window.

public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
GCL_CBCLSEXTRA

Class field offsets for GetClassLongPtr.

public static final int
GCL_CBWNDEXTRA

Class field offsets for GetClassLongPtr.

public static final int
GCL_HBRBACKGROUND

Class field offsets for GetClassLongPtr.

public static final int
GCL_HCURSOR

Class field offsets for GetClassLongPtr.

public static final int
GCL_HICON

Class field offsets for GetClassLongPtr.

public static final int
GCL_HICONSM

Class field offsets for GetClassLongPtr.

public static final int
GCL_HMODULE

Class field offsets for GetClassLongPtr.

public static final int
GCL_MENUNAME

Class field offsets for GetClassLongPtr.

public static final int
GCL_STYLE

Class field offsets for GetClassLongPtr.

public static final int
GCL_WNDPROC

Class field offsets for GetClassLongPtr.

public static final int
GCW_ATOM

Class field offsets for GetClassLongPtr.

public static final int
GWL_EXSTYLE

Window field offsets for GetWindowLongPtr.

public static final int
GWL_HINSTANCE

Window field offsets for GetWindowLongPtr.

public static final int
GWL_HWNDPARENT

Window field offsets for GetWindowLongPtr.

public static final int
GWL_ID

Window field offsets for GetWindowLongPtr.

public static final int
GWL_STYLE

Window field offsets for GetWindowLongPtr.

public static final int
GWL_USERDATA

Window field offsets for GetWindowLongPtr.

public static final int
GWL_WNDPROC

Window field offsets for GetWindowLongPtr.

public static final int
HTBORDER

Mouse position codes.

public static final int
HTBOTTOM

Mouse position codes.

public static final int
HTBOTTOMLEFT

Mouse position codes.

public static final int
HTBOTTOMRIGHT

Mouse position codes.

public static final int
HTCAPTION

Mouse position codes.

public static final int
HTCLIENT

Mouse position codes.

public static final int
HTCLOSE

Mouse position codes.

public static final int
HTERROR

Mouse position codes.

public static final int
HTGROWBOX

Mouse position codes.

public static final int
HTHELP

Mouse position codes.

public static final int
HTHSCROLL

Mouse position codes.

public static final int
HTLEFT

Mouse position codes.

public static final int
HTMAXBUTTON

Mouse position codes.

public static final int
HTMENU

Mouse position codes.

public static final int
HTMINBUTTON

Mouse position codes.

public static final int
HTNOWHERE

Mouse position codes.

public static final int
HTOBJECT

Mouse position codes.

public static final int
HTREDUCE

Mouse position codes.

public static final int
HTRIGHT

Mouse position codes.

public static final int
HTSIZE

Mouse position codes.

public static final int
HTSIZEFIRST

Mouse position codes.

public static final int
HTSIZELAST

Mouse position codes.

public static final int
HTSYSMENU

Mouse position codes.

public static final int
HTTOP

Mouse position codes.

public static final int
HTTOPLEFT

Mouse position codes.

public static final int
HTTOPRIGHT

Mouse position codes.

public static final int
HTTRANSPARENT

Mouse position codes.

public static final int
HTVSCROLL

Mouse position codes.

public static final int
HTZOOM

Mouse position codes.

public static final long
HWND_BOTTOM

Virtual window handles used by the SetWindowPos insertAfter argument.

public static final long
HWND_BROADCAST

Virtual window handle used by PostMessage that matches all top-level windows in the system, including disabled or invisible unowned windows, overlapped windows, and pop-up windows.

public static final long
HWND_NOTOPMOST

Virtual window handles used by the SetWindowPos insertAfter argument.

public static final long
HWND_TOP

Virtual window handles used by the SetWindowPos insertAfter argument.

public static final long
HWND_TOPMOST

Virtual window handles used by the SetWindowPos insertAfter argument.

public static final int
IDC_APPSTARTING

Standard Cursor IDs.

public static final int
IDC_ARROW

Standard Cursor IDs.

public static final int
IDC_CROSS

Standard Cursor IDs.

public static final int
IDC_HAND

Standard Cursor IDs.

public static final int
IDC_HELP

Standard Cursor IDs.

public static final int
IDC_IBEAM

Standard Cursor IDs.

public static final int
IDC_ICON

Standard Cursor IDs.

public static final int
IDC_NO

Standard Cursor IDs.

public static final int
IDC_SIZE

Standard Cursor IDs.

public static final int
IDC_SIZEALL

Standard Cursor IDs.

public static final int
IDC_SIZENESW

Standard Cursor IDs.

public static final int
IDC_SIZENS

Standard Cursor IDs.

public static final int
IDC_SIZENWSE

Standard Cursor IDs.

public static final int
IDC_SIZEWE

Standard Cursor IDs.

public static final int
IDC_UPARROW

Standard Cursor IDs.

public static final int
IDC_WAIT

Standard Cursor IDs.

public static final int
IDI_APPLICATION

Standard Icon IDs.

public static final int
IDI_ASTERISK

Standard Icon IDs.

public static final int
IDI_ERROR

Standard Icon IDs.

public static final int
IDI_EXCLAMATION

Standard Icon IDs.

public static final int
IDI_HAND

Standard Icon IDs.

public static final int
IDI_INFORMATION

Standard Icon IDs.

public static final int
IDI_QUESTION

Standard Icon IDs.

public static final int
IDI_SHIELD

Standard Icon IDs.

public static final int
IDI_WARNING

Standard Icon IDs.

public static final int
IDI_WINLOGO

Standard Icon IDs.

public static final int
INPUT_HARDWARE

The type of input event.

public static final int
INPUT_KEYBOARD

The type of input event.

public static final int
INPUT_MOUSE

The type of input event.

public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
MK_CONTROL

Key state masks for mouse messages.

public static final int
MK_LBUTTON

Key state masks for mouse messages.

public static final int
MK_MBUTTON

Key state masks for mouse messages.

public static final int
MK_RBUTTON

Key state masks for mouse messages.

public static final int
MK_SHIFT

Key state masks for mouse messages.

public static final int
MK_XBUTTON1

Key state masks for mouse messages.

public static final int
MK_XBUTTON2

Key state masks for mouse messages.

public static final int
MN_GETHMENU

Windows messages.

public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
PM_NOREMOVE

Remove message flags for PeekMessage.

public static final int
PM_NOYIELD

Remove message flags for PeekMessage.

public static final int
PM_QS_INPUT

Remove message flags for PeekMessage.

public static final int
PM_QS_PAINT

Remove message flags for PeekMessage.

public static final int
PM_QS_POSTMESSAGE

Remove message flags for PeekMessage.

public static final int
PM_QS_SENDMESSAGE

Remove message flags for PeekMessage.

public static final int
PM_REMOVE

Remove message flags for PeekMessage.

public static final int
QS_ALLEVENTS

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_ALLINPUT

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_ALLPOSTMESSAGE

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_HOTKEY

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_INPUT

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_KEY

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_MOUSE

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_MOUSEBUTTON

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_MOUSEMOVE

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_PAINT

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_POSTMESSAGE

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_RAWINPUT

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_SENDMESSAGE

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
QS_TIMER

Queue status flags for GetQueueStatus and MsgWaitForMultipleObjects

public static final int
SC_ARRANGE

System menu command values.

public static final int
SC_CLOSE

System menu command values.

public static final int
SC_CONTEXTHELP

System menu command values.

public static final int
SC_DEFAULT

System menu command values.

public static final int
SC_HOTKEY

System menu command values.

public static final int
SC_HSCROLL

System menu command values.

public static final int
SC_KEYMENU

System menu command values.

public static final int
SC_MAXIMIZE

System menu command values.

public static final int
SC_MINIMIZE

System menu command values.

public static final int
SC_MONITORPOWER

System menu command values.

public static final int
SC_MOUSEMENU

System menu command values.

public static final int
SC_MOVE

System menu command values.

public static final int
SC_NEXTWINDOW

System menu command values.

public static final int
SC_PREVWINDOW

System menu command values.

public static final int
SC_RESTORE

System menu command values.

public static final int
SC_SCREENSAVE

System menu command values.

public static final int
SC_SEPARATOR

System menu command values.

public static final int
SC_SIZE

System menu command values.

public static final int
SC_TASKLIST

System menu command values.

public static final int
SC_VSCROLL

System menu command values.

public static final int
SIZE_MAXHIDE

WM_SIZE message wParam values.

public static final int
SIZE_MAXIMIZED

WM_SIZE message wParam values.

public static final int
SIZE_MAXSHOW

WM_SIZE message wParam values.

public static final int
SIZE_MINIMIZED

WM_SIZE message wParam values.

public static final int
SIZE_RESTORED

WM_SIZE message wParam values.

public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
SW_MAX

ShowWindow commands.

public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
public static final int
SWP_ASYNCWINDOWPOS

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_DEFERERASE

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_DRAWFRAME

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_FRAMECHANGED

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_HIDEWINDOW

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_NOACTIVATE

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_NOCOPYBITS

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_NOMOVE

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_NOOWNERZORDER

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_NOREDRAW

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_NOREPOSITION

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_NOSENDCHANGING

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_NOSIZE

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_NOZORDER

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
SWP_SHOWWINDOW

Window sizing and positiong flags used by the SetWindowPos flags argument.

public static final int
TOUCHEVENTF_DOWN

Touch input flag values (TOUCHINPUT#dwFlags).

public static final int
TOUCHEVENTF_INRANGE

Touch input flag values (TOUCHINPUT#dwFlags).

public static final int
TOUCHEVENTF_MOVE

Touch input flag values (TOUCHINPUT#dwFlags).

public static final int
TOUCHEVENTF_NOCOALESCE

Touch input flag values (TOUCHINPUT#dwFlags).

public static final int
TOUCHEVENTF_PALM

Touch input flag values (TOUCHINPUT#dwFlags).

public static final int
TOUCHEVENTF_PEN

Touch input flag values (TOUCHINPUT#dwFlags).

public static final int
TOUCHEVENTF_PRIMARY

Touch input flag values (TOUCHINPUT#dwFlags).

public static final int
TOUCHEVENTF_UP

Touch input flag values (TOUCHINPUT#dwFlags).

public static final int
public static final int
TOUCHINPUTMASKF_EXTRAINFO

Touch input mask values (TOUCHINPUT#dwMask).

public static final int
public static final int
public static final int
public static final int
UNICODE_NOCHAR

Windows messages.

private static final SharedLibrary
public static final int
VK_ACCEPT

Virtual Keys.

public static final int
VK_ADD

Virtual Keys.

public static final int
VK_APPS

Virtual Keys.

public static final int
VK_ATTN

Virtual Keys.

public static final int
VK_BACK

Virtual Keys.

public static final int
VK_BROWSER_BACK

Virtual Keys.

public static final int
VK_BROWSER_FAVORITES

Virtual Keys.

public static final int
VK_BROWSER_FORWARD

Virtual Keys.

public static final int
VK_BROWSER_HOME

Virtual Keys.

public static final int
VK_BROWSER_REFRESH

Virtual Keys.

public static final int
VK_BROWSER_SEARCH

Virtual Keys.

public static final int
VK_BROWSER_STOP

Virtual Keys.

public static final int
VK_CANCEL

Virtual Keys.

public static final int
VK_CAPITAL

Virtual Keys.

public static final int
VK_CLEAR

Virtual Keys.

public static final int
VK_CONTROL

Virtual Keys.

public static final int
VK_CONVERT

Virtual Keys.

public static final int
VK_CRSEL

Virtual Keys.

public static final int
VK_DECIMAL

Virtual Keys.

public static final int
VK_DELETE

Virtual Keys.

public static final int
VK_DIVIDE

Virtual Keys.

public static final int
VK_DOWN

Virtual Keys.

public static final int
VK_END

Virtual Keys.

public static final int
VK_EREOF

Virtual Keys.

public static final int
VK_ESCAPE

Virtual Keys.

public static final int
VK_EXECUTE

Virtual Keys.

public static final int
VK_EXSEL

Virtual Keys.

public static final int
VK_F1

Virtual Keys.

public static final int
VK_F10

Virtual Keys.

public static final int
VK_F11

Virtual Keys.

public static final int
VK_F12

Virtual Keys.

public static final int
VK_F13

Virtual Keys.

public static final int
VK_F14

Virtual Keys.

public static final int
VK_F15

Virtual Keys.

public static final int
VK_F16

Virtual Keys.

public static final int
VK_F17

Virtual Keys.

public static final int
VK_F18

Virtual Keys.

public static final int
VK_F19

Virtual Keys.

public static final int
VK_F2

Virtual Keys.

public static final int
VK_F20

Virtual Keys.

public static final int
VK_F21

Virtual Keys.

public static final int
VK_F22

Virtual Keys.

public static final int
VK_F23

Virtual Keys.

public static final int
VK_F24

Virtual Keys.

public static final int
VK_F3

Virtual Keys.

public static final int
VK_F4

Virtual Keys.

public static final int
VK_F5

Virtual Keys.

public static final int
VK_F6

Virtual Keys.

public static final int
VK_F7

Virtual Keys.

public static final int
VK_F8

Virtual Keys.

public static final int
VK_F9

Virtual Keys.

public static final int
VK_FINAL

Virtual Keys.

public static final int
VK_HANGEUL

Virtual Keys.

public static final int
VK_HANGUL

Virtual Keys.

public static final int
VK_HANJA

Virtual Keys.

public static final int
VK_HELP

Virtual Keys.

public static final int
VK_HOME

Virtual Keys.

public static final int
VK_ICO_00

Virtual Keys.

public static final int
VK_ICO_CLEAR

Virtual Keys.

public static final int
VK_ICO_HELP

Virtual Keys.

public static final int
VK_INSERT

Virtual Keys.

public static final int
VK_JUNJA

Virtual Keys.

public static final int
VK_KANA

Virtual Keys.

public static final int
VK_KANJI

Virtual Keys.

public static final int
VK_LAUNCH_APP1

Virtual Keys.

public static final int
VK_LAUNCH_APP2

Virtual Keys.

public static final int
VK_LAUNCH_MAIL

Virtual Keys.

public static final int
public static final int
VK_LBUTTON

Virtual Keys.

public static final int
VK_LCONTROL

Virtual Keys.

public static final int
VK_LEFT

Virtual Keys.

public static final int
VK_LMENU

Virtual Keys.

public static final int
VK_LSHIFT

Virtual Keys.

public static final int
VK_LWIN

Virtual Keys.

public static final int
VK_MBUTTON

Virtual Keys.

public static final int
VK_MEDIA_NEXT_TRACK

Virtual Keys.

public static final int
VK_MEDIA_PLAY_PAUSE

Virtual Keys.

public static final int
VK_MEDIA_PREV_TRACK

Virtual Keys.

public static final int
VK_MEDIA_STOP

Virtual Keys.

public static final int
VK_MENU

Virtual Keys.

public static final int
VK_MODECHANGE

Virtual Keys.

public static final int
VK_MULTIPLY

Virtual Keys.

public static final int
VK_NEXT

Virtual Keys.

public static final int
VK_NONAME

Virtual Keys.

public static final int
VK_NONCONVERT

Virtual Keys.

public static final int
VK_NUMLOCK

Virtual Keys.

public static final int
VK_NUMPAD0

Virtual Keys.

public static final int
VK_NUMPAD1

Virtual Keys.

public static final int
VK_NUMPAD2

Virtual Keys.

public static final int
VK_NUMPAD3

Virtual Keys.

public static final int
VK_NUMPAD4

Virtual Keys.

public static final int
VK_NUMPAD5

Virtual Keys.

public static final int
VK_NUMPAD6

Virtual Keys.

public static final int
VK_NUMPAD7

Virtual Keys.

public static final int
VK_NUMPAD8

Virtual Keys.

public static final int
VK_NUMPAD9

Virtual Keys.

public static final int
VK_OEM_1

Virtual Keys.

public static final int
VK_OEM_102

Virtual Keys.

public static final int
VK_OEM_2

Virtual Keys.

public static final int
VK_OEM_3

Virtual Keys.

public static final int
VK_OEM_4

Virtual Keys.

public static final int
VK_OEM_5

Virtual Keys.

public static final int
VK_OEM_6

Virtual Keys.

public static final int
VK_OEM_7

Virtual Keys.

public static final int
VK_OEM_8

Virtual Keys.

public static final int
VK_OEM_ATTN

Virtual Keys.

public static final int
VK_OEM_AUTO

Virtual Keys.

public static final int
VK_OEM_AX

Virtual Keys.

public static final int
VK_OEM_BACKTAB

Virtual Keys.

public static final int
VK_OEM_CLEAR

Virtual Keys.

public static final int
VK_OEM_COMMA

Virtual Keys.

public static final int
VK_OEM_COPY

Virtual Keys.

public static final int
VK_OEM_CUSEL

Virtual Keys.

public static final int
VK_OEM_ENLW

Virtual Keys.

public static final int
VK_OEM_FINISH

Virtual Keys.

public static final int
VK_OEM_FJ_JISHO

Virtual Keys.

public static final int
VK_OEM_FJ_LOYA

Virtual Keys.

public static final int
VK_OEM_FJ_MASSHOU

Virtual Keys.

public static final int
VK_OEM_FJ_ROYA

Virtual Keys.

public static final int
VK_OEM_FJ_TOUROKU

Virtual Keys.

public static final int
VK_OEM_JUMP

Virtual Keys.

public static final int
VK_OEM_MINUS

Virtual Keys.

public static final int
VK_OEM_NEC_EQUAL

Virtual Keys.

public static final int
VK_OEM_PA1

Virtual Keys.

public static final int
VK_OEM_PA2

Virtual Keys.

public static final int
VK_OEM_PA3

Virtual Keys.

public static final int
VK_OEM_PERIOD

Virtual Keys.

public static final int
VK_OEM_PLUS

Virtual Keys.

public static final int
VK_OEM_RESET

Virtual Keys.

public static final int
VK_OEM_WSCTRL

Virtual Keys.

public static final int
VK_PA1

Virtual Keys.

public static final int
VK_PACKET

Virtual Keys.

public static final int
VK_PAUSE

Virtual Keys.

public static final int
VK_PLAY

Virtual Keys.

public static final int
VK_PRINT

Virtual Keys.

public static final int
VK_PRIOR

Virtual Keys.

public static final int
VK_PROCESSKEY

Virtual Keys.

public static final int
VK_RBUTTON

Virtual Keys.

public static final int
VK_RCONTROL

Virtual Keys.

public static final int
VK_RETURN

Virtual Keys.

public static final int
VK_RIGHT

Virtual Keys.

public static final int
VK_RMENU

Virtual Keys.

public static final int
VK_RSHIFT

Virtual Keys.

public static final int
VK_RWIN

Virtual Keys.

public static final int
VK_SCROLL

Virtual Keys.

public static final int
VK_SELECT

Virtual Keys.

public static final int
VK_SEPARATOR

Virtual Keys.

public static final int
VK_SHIFT

Virtual Keys.

public static final int
VK_SLEEP

Virtual Keys.

public static final int
VK_SNAPSHOT

Virtual Keys.

public static final int
VK_SPACE

Virtual Keys.

public static final int
VK_SUBTRACT

Virtual Keys.

public static final int
VK_TAB

Virtual Keys.

public static final int
VK_UP

Virtual Keys.

public static final int
VK_VOLUME_DOWN

Virtual Keys.

public static final int
VK_VOLUME_MUTE

Virtual Keys.

public static final int
VK_VOLUME_UP

Virtual Keys.

public static final int
VK_XBUTTON1

Virtual Keys.

public static final int
VK_XBUTTON2

Virtual Keys.

public static final int
VK_ZOOM

Virtual Keys.

public static final int
WA_ACTIVE

WM_ACTIVATE message wParam values.

public static final int
WA_CLICKACTIVE

WM_ACTIVATE message wParam values.

public static final int
WA_INACTIVE

WM_ACTIVATE message wParam values.

public static final int
WHEEL_DELTA

Value for rolling one detent.

public static final int
WM_ACTIVATE

Windows messages.

public static final int
WM_ACTIVATEAPP

Windows messages.

public static final int
WM_AFXFIRST

Windows messages.

public static final int
WM_AFXLAST

Windows messages.

public static final int
WM_APP

Windows messages.

public static final int
WM_APPCOMMAND

Windows messages.

public static final int
WM_ASKCBFORMATNAME

Windows messages.

public static final int
WM_CANCELJOURNAL

Windows messages.

public static final int
WM_CANCELMODE

Windows messages.

public static final int
WM_CAPTURECHANGED

Windows messages.

public static final int
WM_CHANGECBCHAIN

Windows messages.

public static final int
WM_CHANGEUISTATE

Windows messages.

public static final int
WM_CHAR

Windows messages.

public static final int
WM_CHARTOITEM

Windows messages.

public static final int
WM_CHILDACTIVATE

Windows messages.

public static final int
WM_CLEAR

Windows messages.

public static final int
WM_CLIPBOARDUPDATE

Windows messages.

public static final int
WM_CLOSE

Windows messages.

public static final int
WM_COMMAND

Windows messages.

public static final int
WM_COMMNOTIFY

Windows messages.

public static final int
WM_COMPACTING

Windows messages.

public static final int
WM_COMPAREITEM

Windows messages.

public static final int
WM_CONTEXTMENU

Windows messages.

public static final int
WM_COPY

Windows messages.

public static final int
WM_COPYDATA

Windows messages.

public static final int
WM_CREATE

Windows messages.

public static final int
WM_CTLCOLORBTN

Windows messages.

public static final int
WM_CTLCOLORDLG

Windows messages.

public static final int
WM_CTLCOLOREDIT

Windows messages.

public static final int
WM_CTLCOLORLISTBOX

Windows messages.

public static final int
WM_CTLCOLORMSGBOX

Windows messages.

public static final int
WM_CTLCOLORSCROLLBAR

Windows messages.

public static final int
WM_CTLCOLORSTATIC

Windows messages.

public static final int
WM_CUT

Windows messages.

public static final int
WM_DEADCHAR

Windows messages.

public static final int
WM_DELETEITEM

Windows messages.

public static final int
WM_DESTROY

Windows messages.

public static final int
WM_DESTROYCLIPBOARD

Windows messages.

public static final int
WM_DEVICECHANGE

Windows messages.

public static final int
WM_DEVMODECHANGE

Windows messages.

public static final int
WM_DISPLAYCHANGE

Windows messages.

public static final int
WM_DRAWCLIPBOARD

Windows messages.

public static final int
WM_DRAWITEM

Windows messages.

public static final int
WM_DROPFILES

Windows messages.

public static final int
public static final int
WM_DWMCOMPOSITIONCHANGED

Windows messages.

public static final int
WM_DWMNCRENDERINGCHANGED

Windows messages.

public static final int
public static final int
WM_DWMSENDICONICTHUMBNAIL

Windows messages.

public static final int
WM_DWMWINDOWMAXIMIZEDCHANGE

Windows messages.

public static final int
WM_ENABLE

Windows messages.

public static final int
WM_ENDSESSION

Windows messages.

public static final int
WM_ENTERIDLE

Windows messages.

public static final int
WM_ENTERMENULOOP

Windows messages.

public static final int
WM_ENTERSIZEMOVE

Windows messages.

public static final int
WM_ERASEBKGND

Windows messages.

public static final int
WM_EXITMENULOOP

Windows messages.

public static final int
WM_EXITSIZEMOVE

Windows messages.

public static final int
WM_FONTCHANGE

Windows messages.

public static final int
WM_GESTURE

Windows messages.

public static final int
WM_GESTURENOTIFY

Windows messages.

public static final int
WM_GETDLGCODE

Windows messages.

public static final int
WM_GETFONT

Windows messages.

public static final int
WM_GETHOTKEY

Windows messages.

public static final int
WM_GETICON

Windows messages.

public static final int
WM_GETMINMAXINFO

Windows messages.

public static final int
WM_GETOBJECT

Windows messages.

public static final int
WM_GETTEXT

Windows messages.

public static final int
WM_GETTEXTLENGTH

Windows messages.

public static final int
WM_GETTITLEBARINFOEX

Windows messages.

public static final int
WM_HANDHELDFIRST

Windows messages.

public static final int
WM_HANDHELDLAST

Windows messages.

public static final int
WM_HELP

Windows messages.

public static final int
WM_HOTKEY

Windows messages.

public static final int
WM_HSCROLL

Windows messages.

public static final int
WM_HSCROLLCLIPBOARD

Windows messages.

public static final int
WM_ICONERASEBKGND

Windows messages.

public static final int
WM_IME_CHAR

Windows messages.

public static final int
WM_IME_COMPOSITION

Windows messages.

public static final int
WM_IME_COMPOSITIONFULL

Windows messages.

public static final int
WM_IME_CONTROL

Windows messages.

public static final int
WM_IME_ENDCOMPOSITION

Windows messages.

public static final int
WM_IME_KEYDOWN

Windows messages.

public static final int
WM_IME_KEYLAST

Windows messages.

public static final int
WM_IME_KEYUP

Windows messages.

public static final int
WM_IME_NOTIFY

Windows messages.

public static final int
WM_IME_REQUEST

Windows messages.

public static final int
WM_IME_SELECT

Windows messages.

public static final int
WM_IME_SETCONTEXT

Windows messages.

public static final int
WM_IME_STARTCOMPOSITION

Windows messages.

public static final int
WM_INITDIALOG

Windows messages.

public static final int
WM_INITMENU

Windows messages.

public static final int
WM_INITMENUPOPUP

Windows messages.

public static final int
WM_INPUT

Windows messages.

public static final int
WM_INPUT_DEVICE_CHANGE

Windows messages.

public static final int
WM_INPUTLANGCHANGE

Windows messages.

public static final int
WM_INPUTLANGCHANGEREQUEST

Windows messages.

public static final int
WM_KEYDOWN

Windows messages.

public static final int
WM_KEYFIRST

Windows messages.

public static final int
WM_KEYUP

Windows messages.

public static final int
WM_KILLFOCUS

Windows messages.

public static final int
WM_LBUTTONDBLCLK

Windows messages.

public static final int
WM_LBUTTONDOWN

Windows messages.

public static final int
WM_LBUTTONUP

Windows messages.

public static final int
WM_MBUTTONDBLCLK

Windows messages.

public static final int
WM_MBUTTONDOWN

Windows messages.

public static final int
WM_MBUTTONUP

Windows messages.

public static final int
WM_MDIACTIVATE

Windows messages.

public static final int
WM_MDICASCADE

Windows messages.

public static final int
WM_MDICREATE

Windows messages.

public static final int
WM_MDIDESTROY

Windows messages.

public static final int
WM_MDIGETACTIVE

Windows messages.

public static final int
WM_MDIICONARRANGE

Windows messages.

public static final int
WM_MDIMAXIMIZE

Windows messages.

public static final int
WM_MDINEXT

Windows messages.

public static final int
WM_MDIREFRESHMENU

Windows messages.

public static final int
WM_MDIRESTORE

Windows messages.

public static final int
WM_MDISETMENU

Windows messages.

public static final int
WM_MDITILE

Windows messages.

public static final int
WM_MEASUREITEM

Windows messages.

public static final int
WM_MENUCHAR

Windows messages.

public static final int
WM_MENUCOMMAND

Windows messages.

public static final int
WM_MENUDRAG

Windows messages.

public static final int
WM_MENUGETOBJECT

Windows messages.

public static final int
WM_MENURBUTTONUP

Windows messages.

public static final int
WM_MENUSELECT

Windows messages.

public static final int
WM_MOUSEACTIVATE

Windows messages.

public static final int
WM_MOUSEFIRST

Windows messages.

public static final int
WM_MOUSEHOVER

Windows messages.

public static final int
WM_MOUSEHWHEEL

Windows messages.

public static final int
WM_MOUSELEAVE

Windows messages.

public static final int
WM_MOUSEMOVE

Windows messages.

public static final int
WM_MOUSEWHEEL

Windows messages.

public static final int
WM_MOVE

Windows messages.

public static final int
WM_MOVING

Windows messages.

public static final int
WM_NCACTIVATE

Windows messages.

public static final int
WM_NCCALCSIZE

Windows messages.

public static final int
WM_NCCREATE

Windows messages.

public static final int
WM_NCDESTROY

Windows messages.

public static final int
WM_NCHITTEST

Windows messages.

public static final int
WM_NCLBUTTONDBLCLK

Windows messages.

public static final int
WM_NCLBUTTONDOWN

Windows messages.

public static final int
WM_NCLBUTTONUP

Windows messages.

public static final int
WM_NCMBUTTONDBLCLK

Windows messages.

public static final int
WM_NCMBUTTONDOWN

Windows messages.

public static final int
WM_NCMBUTTONUP

Windows messages.

public static final int
WM_NCMOUSEHOVER

Windows messages.

public static final int
WM_NCMOUSELEAVE

Windows messages.

public static final int
WM_NCMOUSEMOVE

Windows messages.

public static final int
WM_NCPAINT

Windows messages.

public static final int
WM_NCRBUTTONDBLCLK

Windows messages.

public static final int
WM_NCRBUTTONDOWN

Windows messages.

public static final int
WM_NCRBUTTONUP

Windows messages.

public static final int
WM_NCXBUTTONDBLCLK

Windows messages.

public static final int
WM_NCXBUTTONDOWN

Windows messages.

public static final int
WM_NCXBUTTONUP

Windows messages.

public static final int
WM_NEXTDLGCTL

Windows messages.

public static final int
WM_NEXTMENU

Windows messages.

public static final int
WM_NOTIFY

Windows messages.

public static final int
WM_NOTIFYFORMAT

Windows messages.

public static final int
WM_NULL

Windows messages.

public static final int
WM_PAINT

Windows messages.

public static final int
WM_PAINTCLIPBOARD

Windows messages.

public static final int
WM_PAINTICON

Windows messages.

public static final int
WM_PALETTECHANGED

Windows messages.

public static final int
WM_PALETTEISCHANGING

Windows messages.

public static final int
WM_PARENTNOTIFY

Windows messages.

public static final int
WM_PASTE

Windows messages.

public static final int
WM_PENWINFIRST

Windows messages.

public static final int
WM_PENWINLAST

Windows messages.

public static final int
WM_POWER

Windows messages.

public static final int
WM_POWERBROADCAST

Windows messages.

public static final int
WM_PRINT

Windows messages.

public static final int
WM_PRINTCLIENT

Windows messages.

public static final int
WM_QUERYDRAGICON

Windows messages.

public static final int
WM_QUERYENDSESSION

Windows messages.

public static final int
WM_QUERYNEWPALETTE

Windows messages.

public static final int
WM_QUERYOPEN

Windows messages.

public static final int
WM_QUERYUISTATE

Windows messages.

public static final int
WM_QUEUESYNC

Windows messages.

public static final int
WM_QUIT

Windows messages.

public static final int
WM_RBUTTONDBLCLK

Windows messages.

public static final int
WM_RBUTTONDOWN

Windows messages.

public static final int
WM_RBUTTONUP

Windows messages.

public static final int
WM_RENDERALLFORMATS

Windows messages.

public static final int
WM_RENDERFORMAT

Windows messages.

public static final int
WM_SETCURSOR

Windows messages.

public static final int
WM_SETFOCUS

Windows messages.

public static final int
WM_SETFONT

Windows messages.

public static final int
WM_SETHOTKEY

Windows messages.

public static final int
WM_SETICON

Windows messages.

public static final int
WM_SETREDRAW

Windows messages.

public static final int
WM_SETTEXT

Windows messages.

public static final int
WM_SETTINGCHANGE

Windows messages.

public static final int
WM_SHOWWINDOW

Windows messages.

public static final int
WM_SIZE

Windows messages.

public static final int
WM_SIZECLIPBOARD

Windows messages.

public static final int
WM_SIZING

Windows messages.

public static final int
WM_SPOOLERSTATUS

Windows messages.

public static final int
WM_STYLECHANGED

Windows messages.

public static final int
WM_STYLECHANGING

Windows messages.

public static final int
WM_SYNCPAINT

Windows messages.

public static final int
WM_SYSCHAR

Windows messages.

public static final int
WM_SYSCOLORCHANGE

Windows messages.

public static final int
WM_SYSCOMMAND

Windows messages.

public static final int
WM_SYSDEADCHAR

Windows messages.

public static final int
WM_SYSKEYDOWN

Windows messages.

public static final int
WM_SYSKEYUP

Windows messages.

public static final int
WM_TABLET_FIRST

Windows messages.

public static final int
WM_TABLET_LAST

Windows messages.

public static final int
WM_TCARD

Windows messages.

public static final int
WM_THEMECHANGED

Windows messages.

public static final int
WM_TIMECHANGE

Windows messages.

public static final int
WM_TIMER

Windows messages.

public static final int
WM_TOUCH

Windows messages.

public static final int
WM_UNDO

Windows messages.

public static final int
WM_UNICHAR

Windows messages.

public static final int
WM_UNINITMENUPOPUP

Windows messages.

public static final int
WM_UPDATEUISTATE

Windows messages.

public static final int
WM_USER

Windows messages.

public static final int
WM_USERCHANGED

Windows messages.

public static final int
WM_VKEYTOITEM

Windows messages.

public static final int
WM_VSCROLL

Windows messages.

public static final int
WM_VSCROLLCLIPBOARD

Windows messages.

public static final int
WM_WINDOWPOSCHANGED

Windows messages.

public static final int
WM_WINDOWPOSCHANGING

Windows messages.

public static final int
WM_WININICHANGE

Windows messages.

public static final int
WM_WTSSESSION_CHANGE

Windows messages.

public static final int
WM_XBUTTONDBLCLK

Windows messages.

public static final int
WM_XBUTTONDOWN

Windows messages.

public static final int
WM_XBUTTONUP

Windows messages.

public static final int
public static final int
public static final int
public static final int
WS_BORDER

Window Styles

public static final int
WS_CAPTION

Window Styles

public static final int
WS_CHILD

Window Styles

public static final int
WS_CHILDWINDOW

Window Styles

public static final int
WS_CLIPCHILDREN

Window Styles

public static final int
WS_CLIPSIBLINGS

Window Styles

public static final int
WS_DISABLED

Window Styles

public static final int
WS_DLGFRAME

Window Styles

public static final int
WS_EX_ACCEPTFILES

Extended Window Styles

public static final int
WS_EX_APPWINDOW

Extended Window Styles

public static final int
WS_EX_CLIENTEDGE

Extended Window Styles

public static final int
WS_EX_COMPOSITED

Extended Window Styles

public static final int
WS_EX_CONTEXTHELP

Extended Window Styles

public static final int
WS_EX_CONTROLPARENT

Extended Window Styles

public static final int
WS_EX_DLGMODALFRAME

Extended Window Styles

public static final int
WS_EX_LAYERED

Extended Window Styles

public static final int
WS_EX_LAYOUTRTL

Extended Window Styles

public static final int
WS_EX_LEFT

Extended Window Styles

public static final int
WS_EX_LEFTSCROLLBAR

Extended Window Styles

public static final int
WS_EX_LTRREADING

Extended Window Styles

public static final int
WS_EX_MDICHILD

Extended Window Styles

public static final int
WS_EX_NOACTIVATE

Extended Window Styles

public static final int
WS_EX_NOINHERITLAYOUT

Extended Window Styles

public static final int
WS_EX_NOPARENTNOTIFY

Extended Window Styles

public static final int
WS_EX_OVERLAPPEDWINDOW

Extended Window Styles

public static final int
WS_EX_PALETTEWINDOW

Extended Window Styles

public static final int
WS_EX_RIGHT

Extended Window Styles

public static final int
WS_EX_RIGHTSCROLLBAR

Extended Window Styles

public static final int
WS_EX_RTLREADING

Extended Window Styles

public static final int
WS_EX_STATICEDGE

Extended Window Styles

public static final int
WS_EX_TOOLWINDOW

Extended Window Styles

public static final int
WS_EX_TOPMOST

Extended Window Styles

public static final int
WS_EX_TRANSPARENT

Extended Window Styles

public static final int
WS_EX_WINDOWEDGE

Extended Window Styles

public static final int
WS_GROUP

Window Styles

public static final int
WS_HSCROLL

Window Styles

public static final int
WS_ICONIC

Window Styles

public static final int
WS_MAXIMIZE

Window Styles

public static final int
WS_MAXIMIZEBOX

Window Styles

public static final int
WS_MINIMIZE

Window Styles

public static final int
WS_MINIMIZEBOX

Window Styles

public static final int
WS_OVERLAPPED

Window Styles

public static final int
WS_OVERLAPPEDWINDOW

Window Styles

public static final int
WS_POPUP

Window Styles

public static final int
WS_POPUPWINDOW

Window Styles

public static final int
WS_SIZEBOX

Window Styles

public static final int
WS_SYSMENU

Window Styles

public static final int
WS_TABSTOP

Window Styles

public static final int
WS_THICKFRAME

Window Styles

public static final int
WS_TILED

Window Styles

public static final int
WS_TILEDWINDOW

Window Styles

public static final int
WS_VISIBLE

Window Styles

public static final int
WS_VSCROLL

Window Styles

public static final int
XBUTTON1

XButton values.

public static final int
XBUTTON2

XButton values.

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public static boolean
AdjustWindowRectEx(RECT
a pointer to a RECT structure that contains the coordinates of the top-left and bottom-right corners of the desired client area. When the function returns, the structure contains the coordinates of the top-left and bottom-right corners of the window to accommodate the desired client area.
lpRect
,
int
the window style of the window whose required size is to be calculated. Note that you cannot specify the WS_OVERLAPPED style.
dwStyle
,
boolean
indicates whether the window has a menu
bMenu
,
int
the extended window style of the window whose required size is to be calculated
dwExStyle
)

Calculates the required size of the window rectangle, based on the desired size of the client rectangle.

public static boolean
BringWindowToTop(long
a handle to the window to bring to the top of the Z order
hWnd
)

Brings the specified window to the top of the Z order.

public static long
CallWindowProc(WindowProcI
the previous window procedure.

If this value is obtained by calling the GetWindowLongPtr function with the nIndex parameter set to GWL_WNDPROC or DWL_DLGPROC, it is actually either the address of a window or dialog box procedure, or a special internal value meaningful only to CallWindowProc.

lpPrevWndFunc
,
long
a handle to the window procedure to receive the message
hWnd
,
int
the message
Msg
,
long
additional message information. The content of this parameter depends on the value of the Msg parameter.
wParam
,
long
additional message information. The content of this parameter depends on the value of the Msg parameter.
lParam
)

Passes message information to the specified window procedure.

public static int
ChangeDisplaySettingsEx(ByteBuffer
a pointer to a null-terminated string that specifies the display device whose graphics mode will change. Only display device names as returned by EnumDisplayDevices are valid.

The lpszDeviceName parameter can be NULL. A NULL value specifies the default display device. The default device can be determined by calling EnumDisplayDevices and checking for the GDI32#DISPLAY_DEVICE_PRIMARY_DEVICE flag.

lpszDeviceName
,
DEVMODE
a pointer to a DEVMODE structure that describes the new graphics mode. If lpDevMode is NULL, all the values currently in the registry will be used for the display setting. Passing NULL for the lpDevMode parameter and 0 for the dwFlags parameter is the easiest way to return to the default mode after a dynamic mode change.

The dmSize member must be initialized to the size, in bytes, of the DEVMODE structure. The dmDriverExtra member must be initialized to indicate the number of bytes of private driver data following the DEVMODE structure.

lpDevMode
,
long
reserved; must be NULL
hwnd
,
int dwflags, long
if flags is CDS_VIDEOPARAMETERS, lParam is a pointer to a VIDEOPARAMETERS structure. Otherwise lParam must be NULL.
lParam
)

Changes the settings of the specified display device to the specified graphics mode.

public static int
ChangeDisplaySettingsEx(CharSequence
a pointer to a null-terminated string that specifies the display device whose graphics mode will change. Only display device names as returned by EnumDisplayDevices are valid.

The lpszDeviceName parameter can be NULL. A NULL value specifies the default display device. The default device can be determined by calling EnumDisplayDevices and checking for the GDI32#DISPLAY_DEVICE_PRIMARY_DEVICE flag.

lpszDeviceName
,
DEVMODE
a pointer to a DEVMODE structure that describes the new graphics mode. If lpDevMode is NULL, all the values currently in the registry will be used for the display setting. Passing NULL for the lpDevMode parameter and 0 for the dwFlags parameter is the easiest way to return to the default mode after a dynamic mode change.

The dmSize member must be initialized to the size, in bytes, of the DEVMODE structure. The dmDriverExtra member must be initialized to indicate the number of bytes of private driver data following the DEVMODE structure.

lpDevMode
,
long
reserved; must be NULL
hwnd
,
int dwflags, long
if flags is CDS_VIDEOPARAMETERS, lParam is a pointer to a VIDEOPARAMETERS structure. Otherwise lParam must be NULL.
lParam
)

Changes the settings of the specified display device to the specified graphics mode.

public static boolean
ClientToScreen(long
a handle to the window whose client area is used for the conversion
hWnd
,
POINT
a pointer to a POINT structure that contains the client coordinates to be converted. The new screen coordinates are copied into this structure if the function succeeds.
lpPoint
)

Converts the client-area coordinates of a specified point to screen coordinates.

public static boolean
ClipCursor(RECT
a pointer to the structure that contains the screen coordinates of the upper-left and lower-right corners of the confining rectangle. If this parameter is NULL, the cursor is free to move anywhere on the screen.
rect
)

Confines the cursor to a rectangular area on the screen.

public static boolean
CloseTouchInputHandle(long
the touch input handle received in the LPARAM of a touch message. The function fails with ERROR_INVALID_HANDLE if this handle is not valid. Note that the handle is not valid after it has been used in a successful call to CloseTouchInputHandle or after it has been passed to DefWindowProc, PostMessage, SendMessage or one of their variants.
hTouchInput
)

Closes a touch input handle, frees process memory associated with it, and invalidates the handle.

public static long
CreateWindowEx(int
the extended window style of the window being created
dwExStyle
,
ByteBuffer
a null-terminated string or a class atom created by a previous call to the RegisterClassEx(WNDCLASSEX) function.
lpClassName
,
ByteBuffer
the window name. If the window style specifies a title bar, the window title pointed to by lpWindowName is displayed in the title bar.
lpWindowName
,
int
the style of the window being created
dwStyle
,
int
the initial horizontal position of the window
x
,
int
the initial vertical position of the window
y
,
int
the width, in device units, of the window
nWidth
,
int
the height, in device units, of the window
nHeight
,
long
a handle to the parent or owner window of the window being created. To create a child window or an owned window, supply a valid window handle.
hWndParent
,
long
a handle to a menu, or specifies a child-window identifier, depending on the window style
hMenu
,
long
a handle to the instance of the module to be associated with the window
hInstance
,
long
a value to be passed to the window through the CREATESTRUCT structure (createParams member) pointed to by the lParam param of the WM_CREATE message.
lpParam
)

Creates an overlapped, pop-up, or child window with an extended window style; otherwise, this function is identical to the CreateWindow function.

public static long
CreateWindowEx(int
the extended window style of the window being created
dwExStyle
,
CharSequence
a null-terminated string or a class atom created by a previous call to the RegisterClassEx(WNDCLASSEX) function.
lpClassName
,
CharSequence
the window name. If the window style specifies a title bar, the window title pointed to by lpWindowName is displayed in the title bar.
lpWindowName
,
int
the style of the window being created
dwStyle
,
int
the initial horizontal position of the window
x
,
int
the initial vertical position of the window
y
,
int
the width, in device units, of the window
nWidth
,
int
the height, in device units, of the window
nHeight
,
long
a handle to the parent or owner window of the window being created. To create a child window or an owned window, supply a valid window handle.
hWndParent
,
long
a handle to a menu, or specifies a child-window identifier, depending on the window style
hMenu
,
long
a handle to the instance of the module to be associated with the window
hInstance
,
long
a value to be passed to the window through the CREATESTRUCT structure (createParams member) pointed to by the lParam param of the WM_CREATE message.
lpParam
)

Creates an overlapped, pop-up, or child window with an extended window style; otherwise, this function is identical to the CreateWindow function.

public static long
DefWindowProc(long
a handle to the window that received the message
hWnd
,
int
the message
Msg
,
long
additional message information. The content of this parameter depends on the value of the Msg parameter.
wParam
,
long
additional message information. The content of this parameter depends on the value of the Msg parameter.
lParam
)

Calls the default window procedure to provide default processing for any window messages that an application does not process.

public static boolean
DestroyWindow(long
a handle to the window to be destroyed
hWnd
)

Destroys the specified window.

public static long
DispatchMessage(MSG
a pointer to a structure that contains the message.
lpmsg
)

Dispatches a message to a window procedure.

public static boolean
EnumDisplayDevices(ByteBuffer
the device name. If NULL, function returns information for the display adapter(s) on the machine, based on devNum.
lpDevice
,
int
an index value that specifies the display device of interest.

The operating system identifies each display device in the current session with an index value. The index values are consecutive integers, starting at 0. If the current session has three display devices, for example, they are specified by the index values 0, 1, and 2.

iDevNum
,
DISPLAY_DEVICE
a pointer to a DISPLAY_DEVICE structure that receives information about the display device specified by iDevNum.

Before calling EnumDisplayDevices, you must initialize the cb member of DISPLAY_DEVICE to the size, in bytes, of DISPLAY_DEVICE.

lpDisplayDevice
,
int
set this flag to EDD_GET_DEVICE_INTERFACE_NAME to retrieve the device interface name for GUID_DEVINTERFACE_MONITOR, which is registered by the operating system on a per monitor basis. The value is placed in the DeviceID member of the DISPLAY_DEVICE structure returned in lpDisplayDevice. The resulting device interface name can be used with SetupAPI functions and serves as a link between GDI monitor devices and SetupAPI monitor devices.
dwFlags
)

Obtains information about the display devices in the current session.

public static boolean
EnumDisplayDevices(CharSequence
the device name. If NULL, function returns information for the display adapter(s) on the machine, based on devNum.
lpDevice
,
int
an index value that specifies the display device of interest.

The operating system identifies each display device in the current session with an index value. The index values are consecutive integers, starting at 0. If the current session has three display devices, for example, they are specified by the index values 0, 1, and 2.

iDevNum
,
DISPLAY_DEVICE
a pointer to a DISPLAY_DEVICE structure that receives information about the display device specified by iDevNum.

Before calling EnumDisplayDevices, you must initialize the cb member of DISPLAY_DEVICE to the size, in bytes, of DISPLAY_DEVICE.

lpDisplayDevice
,
int
set this flag to EDD_GET_DEVICE_INTERFACE_NAME to retrieve the device interface name for GUID_DEVINTERFACE_MONITOR, which is registered by the operating system on a per monitor basis. The value is placed in the DeviceID member of the DISPLAY_DEVICE structure returned in lpDisplayDevice. The resulting device interface name can be used with SetupAPI functions and serves as a link between GDI monitor devices and SetupAPI monitor devices.
dwFlags
)

Obtains information about the display devices in the current session.

public static boolean
EnumDisplaySettingsEx(ByteBuffer
a pointer to a null-terminated string that specifies the display device about which graphics mode the function will obtain information.

This parameter is either NULL or a DISPLAY_DEVICE#DeviceName returned from EnumDisplayDevices. A NULL value specifies the current display device on the computer that the calling thread is running on.

lpszDeviceName
,
int
indicates the type of information to be retrieved.

Graphics mode indexes start at zero. To obtain information for all of a display device's graphics modes, make a series of calls to EnumDisplaySettingsEx, as follows: Set iModeNum to zero for the first call, and increment iModeNum by one for each subsequent call. Continue calling the function until the return value is zero.

When you call EnumDisplaySettingsEx with iModeNum set to zero, the operating system initializes and caches information about the display device. When you call EnumDisplaySettingsEx with iModeNum set to a nonzero value, the function returns the information that was cached the last time the function was called with iModeNum set to zero.

This value can be a graphics mode index or one of:

ENUM_CURRENT_SETTINGSENUM_REGISTRY_SETTINGS
iModeNum
,
DEVMODE
a pointer to a DEVMODE structure into which the function stores information about the specified graphics mode. Before calling EnumDisplaySettingsEx, set the dmSize member to DEVMODE#SIZEOF, and set the dmDriverExtra member to indicate the size, in bytes, of the additional space available to receive private driver data.

The EnumDisplaySettingsEx function will populate the dmFields member of the lpDevMode and one or more other members of the DEVMODE structure. To determine which members were set by the call to EnumDisplaySettingsEx, inspect the dmFields bitmask.

lpDevMode
,
int
this parameter can be one of:
EDS_RAWMODEEDS_ROTATEDMODE
dwFlags
)

Retrieves information about one of the graphics modes for a display device.

public static boolean
EnumDisplaySettingsEx(CharSequence
a pointer to a null-terminated string that specifies the display device about which graphics mode the function will obtain information.

This parameter is either NULL or a DISPLAY_DEVICE#DeviceName returned from EnumDisplayDevices. A NULL value specifies the current display device on the computer that the calling thread is running on.

lpszDeviceName
,
int
indicates the type of information to be retrieved.

Graphics mode indexes start at zero. To obtain information for all of a display device's graphics modes, make a series of calls to EnumDisplaySettingsEx, as follows: Set iModeNum to zero for the first call, and increment iModeNum by one for each subsequent call. Continue calling the function until the return value is zero.

When you call EnumDisplaySettingsEx with iModeNum set to zero, the operating system initializes and caches information about the display device. When you call EnumDisplaySettingsEx with iModeNum set to a nonzero value, the function returns the information that was cached the last time the function was called with iModeNum set to zero.

This value can be a graphics mode index or one of:

ENUM_CURRENT_SETTINGSENUM_REGISTRY_SETTINGS
iModeNum
,
DEVMODE
a pointer to a DEVMODE structure into which the function stores information about the specified graphics mode. Before calling EnumDisplaySettingsEx, set the dmSize member to DEVMODE#SIZEOF, and set the dmDriverExtra member to indicate the size, in bytes, of the additional space available to receive private driver data.

The EnumDisplaySettingsEx function will populate the dmFields member of the lpDevMode and one or more other members of the DEVMODE structure. To determine which members were set by the call to EnumDisplaySettingsEx, inspect the dmFields bitmask.

lpDevMode
,
int
this parameter can be one of:
EDS_RAWMODEEDS_ROTATEDMODE
dwFlags
)

Retrieves information about one of the graphics modes for a display device.

public static short

Returns:

if the function succeeds, the return value specifies whether the key was pressed since the last call to GetAsyncKeyState, and whether the key is currently up or down. If the most significant bit is set, the key is down, and if the least significant bit is set, the key was pressed after the previous call to GetAsyncKeyState. However, you should not rely on this last behavior; for more information, see the Remarks.

The return value is zero for the following cases:

  • The current desktop is not the active desktop
  • The foreground thread belongs to another process and the desktop does not allow the hook or the journal record.
GetAsyncKeyState
(int
the virtual-key code. You can use left- and right-distinguishing constants to specify certain keys.
vKey
)

Determines whether a key is up or down at the time the function is called, and whether the key was pressed after a previous call to GetAsyncKeyState.

public static int

Returns:

the DPI_AWARENESS. If the provided value is null or invalid, this method will return DPI_AWARENESS_INVALID.
GetAwarenessFromDpiAwarenessContext
(long
the DPI_AWARENESS_CONTEXT you want to examine
value
)

Retrieves the DPI_AWARENESS value from a DPI_AWARENESS_CONTEXT.

public static long
GetClassLongPtr(long
a handle to the window and, indirectly, the class to which the window belongs
hWnd
,
int
the value to be retrieved. To retrieve a value from the extra class memory, specify the positive, zero-based byte offset of the value to be retrieved. Valid values are in the range zero through the number of bytes of extra class memory, minus eight; for example, if you specified 24 or more bytes of extra class memory, a value of 16 would be an index to the third integer. To retrieve any other value from the WNDCLASSEX structure, specify one of:
GCL_MENUNAMEGCL_HBRBACKGROUNDGCL_HCURSORGCL_HICONGCL_HMODULEGCL_CBWNDEXTRA
GCL_CBCLSEXTRAGCL_WNDPROCGCL_STYLEGCW_ATOMGCL_HICONSM
nIndex
)

Retrieves the specified value from the WNDCLASSEX structure associated with the specified window.

public static boolean
GetCursorPos(POINT
a pointer to a POINT structure that receives the screen coordinates of the cursor
point
)

Retrieves the position of the mouse cursor, in screen coordinates.

public static long
GetDC(long
a handle to the window whose DC is to be retrieved. If this value is NULL, GetDC retrieves the DC for the entire screen.
hWnd
)

Retrieves a handle to a device context (DC) for the client area of a specified window or for the entire screen.

public static int

Returns:

the system DPI value
GetDpiForSystem
()

Returns the system DPI.

public static int

Returns:

the DPI for the window which depends on the DPI_AWARENESS of the window. An invalid hwnd value will result in a return value of 0.
GetDpiForWindow
(long
the window you want to get information about
hwnd
)

Returns the dots per inch (dpi) value for the associated window.

public static SharedLibrary
getLibrary()

Returns the user32 SharedLibrary.

public static boolean
GetMessage(MSG
a pointer to an MSG structure that receives message information from the thread's message queue
lpMsg
,
long
a handle to the window whose messages are to be retrieved. The window must belong to the current thread.

If hWnd is NULL, GetMessage retrieves messages for any window that belongs to the current thread, and any messages on the current thread's message queue whose hwnd value is NULL (see the MSG structure). Therefore if hWnd is NULL, both window messages and thread messages are processed.

If hWnd is -1, GetMessage retrieves only messages on the current thread's message queue whose hwnd value is NULL, that is, thread messages as posted by PostMessage (when the hWnd parameter is NULL) or PostThreadMessage.

hWnd
,
int
the integer value of the lowest message value to be retrieved
wMsgFilterMin
,
int
the integer value of the highest message value to be retrieved
wMsgFilterMax
)

Retrieves a message from the calling thread's message queue.

public static long

Returns:

the extra information. The meaning of the extra information is device specific.
GetMessageExtraInfo
()

Retrieves the extra message information for the current thread.

public static boolean
GetMonitorInfo(long
a handle to the display monitor of interest
hMonitor
,
MONITORINFOEX
a pointer to a MONITORINFOEX structure that receives information about the specified display monitor.

You must set the cbSize member of the structure to MONITORINFOEX#SIZEOF before calling the GetMonitorInfo function. Doing so lets the function determine the type of structure you are passing to it.

lpmi
)

Retrieves information about a display monitor.

public static int
public static long

Returns:

the current DPI_AWARENESS_CONTEXT for the thread.
GetThreadDpiAwarenessContext
()

Gets the DPI_AWARENESS_CONTEXT for the current thread.

public static boolean
GetTouchInputInfo(long
the touch input handle received in the LPARAM of a touch message. The function fails with ERROR_INVALID_HANDLE if this handle is not valid. Note that the handle is not valid after it has been used in a successful call to CloseTouchInputHandle or after it has been passed to DefWindowProc, PostMessage, SendMessage or one of their variants.
hTouchInput
,
TOUCHINPUT.Buffer
a pointer to an array of TOUCHINPUT structures to receive information about the touch points associated with the specified touch input handle
pInputs
,
int
the size, in bytes, of a single TOUCHINPUT structure. If cbSize is not the size of a single TOUCHINPUT structure, the function fails with ERROR_INVALID_PARAMETER.
cbSize
)

Retrieves detailed information about touch inputs associated with a particular touch input handle.

public static long

Returns:

the DPI_AWARENESS_CONTEXT for the provided window. If the window is not valid, the return value is NULL.
GetWindowDpiAwarenessContext
(long
the window to query
hwnd
)

Returns the DPI_AWARENESS_CONTEXT associated with a window.

public static long
GetWindowLongPtr(long
a handle to the window and, indirectly, the class to which the window belongs
hWnd
,
int
the zero-based offset to the value to be set. Valid values are in the range zero through the number of bytes of extra window memory, minus the size of an integer. To set any other value, specify one of:
GWL_WNDPROCGWL_HINSTANCEGWL_HWNDPARENTGWL_STYLEGWL_EXSTYLEGWL_USERDATAGWL_ID
nIndex
)

Retrieves information about the specified window.

public static boolean
GetWindowPlacement(long
a handle to the window
hWnd
,
WINDOWPLACEMENT
a pointer to the WINDOWPLACEMENT structure that receives the show state and position information.

Before calling GetWindowPlacement, set the length member to WINDOWPLACEMENT#SIZEOF. GetWindowPlacement fails if lpwndpl->length is not set correctly.

lpwndpl
)

Retrieves the show state and the restored, minimized, and maximized positions of the specified window.

public static boolean
GetWindowRect(long
a handle to the window
hWnd
,
RECT
a pointer to a RECT structure that receives the screen coordinates of the upper-left and lower-right corners of the window
lpRect
)

Retrieves the dimensions of the bounding rectangle of the specified window.

public static boolean
IsIconic(long
a handle to the window to be tested
hWnd
)

Determines whether the specified window is minimized (iconic).

public static boolean
IsTouchWindow(long
the handle of the window. The function fails with ERROR_ACCESS_DENIED if the calling thread is not on the same desktop as the specified window.
hWnd
,
IntBuffer
an optional address of the ULONG variable to receive the modifier flags for the specified window's touch capability.
pulFlags
)

Checks whether a specified window is touch-capable and, optionally, retrieves the modifier flags set for the window's touch capability.

public static boolean
IsTouchWindow(long hWnd, int[] pulFlags)

Array version of: IsTouchWindow

public static boolean

Returns:

WinBase#TRUE if the provided context is supported, otherwise WinBase#FALSE
IsValidDpiAwarenessContext
(long
the context that you want to determine if it is supported
value
)

Determines if a specified DPI_AWARENESS_CONTEXT is valid and supported by the current system.

public static boolean
IsWindowVisible(long
a handle to the window to be tested
hWnd
)

Determines the visibility state of the specified window.

public static boolean
IsZoomed(long
a handle to the window to be tested
hWnd
)

Determines whether a window is maximized.

public static long
LoadCursor(long
a handle to an instance of the module whose executable file contains the cursor to be loaded.
instance
,
ByteBuffer cursorName)

Loads the specified cursor resource from the executable (.EXE) file associated with an application instance.

public static long
LoadCursor(long
a handle to an instance of the module whose executable file contains the cursor to be loaded.
instance
,
CharSequence cursorName)

Loads the specified cursor resource from the executable (.EXE) file associated with an application instance.

public static long
LoadIcon(long
a handle to an instance of the module whose executable file contains the icon to be loaded. This parameter must be NULL when a standard icon is being loaded.
instance
,
ByteBuffer iconName)

Loads the specified icon resource from the executable (.exe) file associated with an application instance.

public static long
LoadIcon(long
a handle to an instance of the module whose executable file contains the icon to be loaded. This parameter must be NULL when a standard icon is being loaded.
instance
,
CharSequence iconName)

Loads the specified icon resource from the executable (.exe) file associated with an application instance.

public static long
MonitorFromWindow(long
a handle to the window of interest
hWnd
,
int
determines the function's return value if the window does not intersect any display monitor. One of:
MONITOR_DEFAULTTONULLMONITOR_DEFAULTTOPRIMARYMONITOR_DEFAULTTONEAREST
dwFlags
)

Retrieves a handle to the display monitor that has the largest area of intersection with the bounding rectangle of a specified window.

public static boolean
MoveWindow(long
a handle to the window
hWnd
,
int
the new position of the left side of the window
X
,
int
the new position of the top of the window
Y
,
int
the new width of the window
nWidth
,
int
the new height of the window
nHeight
,
boolean
indicates whether the window is to be repainted. If this parameter is TRUE, the window receives a message. If the parameter is FALSE, no repainting of any kind occurs. This applies to the client area, the nonclient area (including the title bar and scroll bars), and any part of the parent window uncovered as a result of moving a child window.
bRepaint
)

Changes the position and dimensions of the specified window.

public static native int
nAdjustWindowRectEx(long lpRect, int dwStyle, int bMenu, int dwExStyle, long __functionAddress)

Unsafe version of: AdjustWindowRectEx

public static int
nAdjustWindowRectEx(long lpRect, int dwStyle, int bMenu, int dwExStyle)

Unsafe version of: AdjustWindowRectEx

public static long
nCallWindowProc(long lpPrevWndFunc, long hWnd, int Msg, long wParam, long lParam)

Unsafe version of: CallWindowProc

public static int
nChangeDisplaySettingsEx(long lpszDeviceName, long lpDevMode, long hwnd, int dwflags, long lParam)

Unsafe version of: ChangeDisplaySettingsEx

public static int
nClientToScreen(long hWnd, long lpPoint)

Unsafe version of: ClientToScreen

public static int
nClipCursor(long rect)

Unsafe version of: ClipCursor

public static native int
nCloseTouchInputHandle(long hTouchInput, long __functionAddress)

Unsafe version of: CloseTouchInputHandle

public static native long
nCreateWindowEx(int dwExStyle, long lpClassName, long lpWindowName, int dwStyle, int x, int y, int nWidth, int nHeight, long hWndParent, long hMenu, long hInstance, long lpParam, long __functionAddress)

Unsafe version of: CreateWindowEx

public static long
nCreateWindowEx(int dwExStyle, long lpClassName, long lpWindowName, int dwStyle, int x, int y, int nWidth, int nHeight, long hWndParent, long hMenu, long hInstance, long lpParam)

Unsafe version of: CreateWindowEx

public static native int
nDestroyWindow(long hWnd, long __functionAddress)

Unsafe version of: DestroyWindow

public static long
nDispatchMessage(long lpmsg)

Unsafe version of: DispatchMessage

public static int
nEnumDisplayDevices(long lpDevice, int iDevNum, long lpDisplayDevice, int dwFlags)

Unsafe version of: EnumDisplayDevices

public static int
nEnumDisplaySettingsEx(long lpszDeviceName, int iModeNum, long lpDevMode, int dwFlags)

Unsafe version of: EnumDisplaySettingsEx

public static native long
nGetClassLongPtr(long hWnd, int nIndex, long __functionAddress)

Unsafe version of: GetClassLongPtr

public static int
nGetCursorPos(long point)

Unsafe version of: GetCursorPos

public static native int
nGetMessage(long lpMsg, long hWnd, int wMsgFilterMin, int wMsgFilterMax, long __functionAddress)

Unsafe version of: GetMessage

public static int
nGetMessage(long lpMsg, long hWnd, int wMsgFilterMin, int wMsgFilterMax)

Unsafe version of: GetMessage

public static int
nGetMonitorInfo(long hMonitor, long lpmi)

Unsafe version of: GetMonitorInfo

public static native int
nGetTouchInputInfo(long hTouchInput, int
The number of structures in the pInputs array. This should ideally be at least equal to the number of touch points associated with the message as indicated in the message WPARAM. If cInputs is less than the number of touch points, the function will still succeed and populate the pInputs buffer with information about cInputs touch points.
cInputs
,
long pInputs, int cbSize, long __functionAddress)

Unsafe version of: GetTouchInputInfo

public static int
nGetTouchInputInfo(long hTouchInput, int
The number of structures in the pInputs array. This should ideally be at least equal to the number of touch points associated with the message as indicated in the message WPARAM. If cInputs is less than the number of touch points, the function will still succeed and populate the pInputs buffer with information about cInputs touch points.
cInputs
,
long pInputs, int cbSize)

Unsafe version of: GetTouchInputInfo

public static native long
nGetWindowLongPtr(long hWnd, int nIndex, long __functionAddress)

Unsafe version of: GetWindowLongPtr

public static native int
nGetWindowPlacement(long hWnd, long lpwndpl, long __functionAddress)

Unsafe version of: GetWindowPlacement

public static int
nGetWindowPlacement(long hWnd, long lpwndpl)

Unsafe version of: GetWindowPlacement

public static native int
nGetWindowRect(long hWnd, long lpRect, long __functionAddress)

Unsafe version of: GetWindowRect

public static int
nGetWindowRect(long hWnd, long lpRect)

Unsafe version of: GetWindowRect

public static int
nIsTouchWindow(long hWnd, long pulFlags)

Unsafe version of: IsTouchWindow

public static native long
nLoadCursor(long instance, long cursorName, long __functionAddress)

Unsafe version of: LoadCursor

public static long
nLoadCursor(long instance, long cursorName)

Unsafe version of: LoadCursor

public static native long
nLoadIcon(long instance, long iconName, long __functionAddress)

Unsafe version of: LoadIcon

public static long
nLoadIcon(long instance, long iconName)

Unsafe version of: LoadIcon

public static native int
nMoveWindow(long hWnd, int X, int Y, int nWidth, int nHeight, int bRepaint, long __functionAddress)

Unsafe version of: MoveWindow

public static int
nPeekMessage(long lpMsg, long hWnd, int wMsgFilterMin, int wMsgFilterMax, int wRemoveMsg)

Unsafe version of: PeekMessage

public static native int
nPostMessage(long hWnd, int Msg, long wParam, long lParam, long __functionAddress)

Unsafe version of: PostMessage

public static native short
nRegisterClassEx(long lpwcx, long __functionAddress)

Unsafe version of: RegisterClassEx

public static short
nRegisterClassEx(long lpwcx)

Unsafe version of: RegisterClassEx

public static native int
nRegisterTouchWindow(long hWnd, int ulFlags, long __functionAddress)

Unsafe version of: RegisterTouchWindow

public static int
nSendInput(int
the number of structures in the pInputs array
cInputs
,
long pInputs, int cbSize)

Unsafe version of: SendInput

public static native int
nSendMessage(long hWnd, int Msg, long wParam, long lParam, long __functionAddress)

Unsafe version of: SendMessage

public static native long
nSetClassLongPtr(long hWnd, int nIndex, long dwNewLong, long __functionAddress)

Unsafe version of: SetClassLongPtr

public static native int
nSetLayeredWindowAttributes(long hwnd, int crKey, byte bAlpha, int dwFlags, long __functionAddress)

Unsafe version of: SetLayeredWindowAttributes

public static native long
nSetWindowLongPtr(long hWnd, int nIndex, long dwNewLong, long __functionAddress)

Unsafe version of: SetWindowLongPtr

public static native int
nSetWindowPlacement(long hWnd, long lpwndpl, long __functionAddress)

Unsafe version of: SetWindowPlacement

public static int
nSetWindowPlacement(long hWnd, long lpwndpl)

Unsafe version of: SetWindowPlacement

public static native int
nSetWindowPos(long hWnd, long hWndInsertAfter, int X, int Y, int cx, int cy, int uFlags, long __functionAddress)

Unsafe version of: SetWindowPos

public static native int
nSetWindowText(long hWnd, long lpString, long __functionAddress)

Unsafe version of: SetWindowText

public static int
nSetWindowText(long hWnd, long lpString)

Unsafe version of: SetWindowText

public static int
nTranslateMessage(long lpMsg)

Unsafe version of: TranslateMessage

public static native int
nUnregisterClass(long lpClassName, long hInstance, long __functionAddress)

Unsafe version of: UnregisterClass

public static int
nUnregisterClass(long lpClassName, long hInstance)

Unsafe version of: UnregisterClass

public static native int
nUnregisterTouchWindow(long hWnd, long __functionAddress)

Unsafe version of: UnregisterTouchWindow

public static native int
nWaitMessage(long __functionAddress)

Unsafe version of: WaitMessage

public static boolean
PeekMessage(MSG
a pointer to an MSG structure that receives message information
lpMsg
,
long
a handle to the window whose messages are to be retrieved. The window must belong to the current thread.

If hWnd is NULL, GetMessage retrieves messages for any window that belongs to the current thread, and any messages on the current thread's message queue whose hwnd value is NULL (see the MSG structure). Therefore if hWnd is NULL, both window messages and thread messages are processed.

If hWnd is -1, GetMessage retrieves only messages on the current thread's message queue whose hwnd value is NULL, that is, thread messages as posted by PostMessage (when the hWnd parameter is NULL) or PostThreadMessage.

hWnd
,
int
the integer value of the lowest message value to be retrieved
wMsgFilterMin
,
int
the integer value of the highest message value to be retrieved
wMsgFilterMax
,
int
specifies how messages are to be handled. One of:
PM_NOREMOVEPM_REMOVEPM_NOYIELD
wRemoveMsg
)

Dispatches incoming sent messages, checks the thread message queue for a posted message, and retrieves the message (if any exist).

public static boolean
PostMessage(long
a handle to the window whose window procedure is to receive the message. The following values have special meanings:
  • HWND_BROADCAST - The message is posted to all top-level windows in the system, including disabled or invisible unowned windows, overlapped windows, and pop-up windows. The message is not posted to child windows.
  • NULL - The function behaves like a call to PostThreadMessage with the dwThreadId parameter set to the identifier of the current thread.
hWnd
,
int
the message to be posted
Msg
,
long
additional message-specific information
wParam
,
long
additional message-specific information
lParam
)

Places (posts) a message in the message queue associated with the thread that created the specified window and returns without waiting for the thread to process the message.

public static short
RegisterClassEx(WNDCLASSEX
a WNDCLASSEX structure. You must fill the structure with the appropriate class attributes before passing it to the function.
lpwcx
)

Registers a window class for subsequent use in calls to the CreateWindowEx function.

public static boolean
RegisterTouchWindow(long
the handle of the window being registered. The function fails with ERROR_ACCESS_DENIED if the calling thread does not own the specified window.
hWnd
,
int
a set of bit flags that specify optional modifications. This field may contain 0 or one or more of:
TWF_FINETOUCHTWF_WANTPALM
ulFlags
)

Registers a window as being touch-capable.

public static boolean
ReleaseDC(long
a handle to the window whose DC is to be released
hWnd
,
long
a handle to the DC to be released
hDC
)

Releases a device context (DC), freeing it for use by other applications.

public static int

Returns:

the number of events that it successfully inserted into the keyboard or mouse input stream. If the function returns zero, the input was already blocked by another thread. To get extended error information, call WinBase#GetLastError.

This function fails when it is blocked by UIPI. Note that neither GetLastError nor the return value will indicate the failure was caused by UIPI blocking.

SendInput
(INPUT.Buffer
an array of INPUT structures. Each structure represents an event to be inserted into the keyboard or mouse input stream.
pInputs
,
int
the size, in bytes, of an INPUT structure. If cbSize is not the size of an INPUT structure, the function fails.
cbSize
)

Synthesizes keystrokes, mouse motions, and button clicks.

public static boolean
SendMessage(long
a handle to the window whose window procedure will receive the message. If this parameter is HWND_BROADCAST, the message is sent to all top-level windows in the system, including disabled or invisible unowned windows, overlapped windows, and pop-up windows; but the message is not sent to child windows.

Message sending is subject to UIPI. The thread of a process can send messages only to message queues of threads in processes of lesser or equal integrity level.

hWnd
,
int
the message to be sent
Msg
,
long
additional message-specific information
wParam
,
long
additional message-specific information
lParam
)

Sends the specified message to a window or windows.

public static long

Returns:

if the function succeeds, the return value is the previous value of the specified offset. If this was not previously set, the return value is zero.

If the function fails, the return value is zero. To get extended error information, call WinBase#getLastError.

SetClassLongPtr
(long
a handle to the window and, indirectly, the class to which the window belongs
hWnd
,
int
the value to be replaced. To set a value in the extra class memory, specify the positive, zero-based byte offset of the value to be set. Valid values are in the range zero through the number of bytes of extra class memory, minus eight; for example, if you specified 24 or more bytes of extra class memory, a value of 16 would be an index to the third integer. To set a value other than the WNDCLASSEX structure, specify one of:
GCL_MENUNAMEGCL_HBRBACKGROUNDGCL_HCURSORGCL_HICONGCL_HMODULEGCL_CBWNDEXTRA
GCL_CBCLSEXTRAGCL_WNDPROCGCL_STYLEGCW_ATOMGCL_HICONSM
nIndex
,
long
the replacement value
dwNewLong
)

Replaces the specified value at the specified offset in the extra class memory or the WNDCLASSEX structure for the class to which the specified window belongs.

public static long

Returns:

the handle to the previous cursor, if there was one
SetCursor
(long
a handle to the cursor. The cursor must have been created by the CreateCursor function or loaded by the LoadCursor or LoadImage function. If this parameter is NULL, the cursor is removed from the screen.
hCursor
)

Sets the cursor shape.

public static boolean
SetCursorPos(int
the new x-coordinate of the cursor, in screen coordinates.
X
,
int
the new y-coordinate of the cursor, in screen coordinates.
Y
)

Moves the cursor to the specified screen coordinates.

public static boolean
SetLayeredWindowAttributes(long
a handle to the layered window. A layered window is created by specifying WS_EX_LAYERED when creating the window with the CreateWindowEx function or by setting WS_EX_LAYERED via SetWindowLongPtr after the window has been created.
hwnd
,
int
the transparency color key (0x00bbggrr) to be used when composing the layered window. All pixels painted by the window in this color will be transparent.
crKey
,
byte
the alpha value used to describe the opacity of the layered window. When bAlpha is 0, the window is completely transparent. When bAlpha is 255, the window is opaque.
bAlpha
,
int
an action to be taken. One or more of:
LWA_COLORKEYLWA_ALPHA
dwFlags
)

public static long

Returns:

The old DPI_AWARENESS_CONTEXT for the thread. If the dpiContext is invalid, the thread will not be updated and the return value will be NULL. You can use this value to restore the old DPI_AWARENESS_CONTEXT after overriding it with a predefined value.
SetThreadDpiAwarenessContext
(long
the DPI awareness value to set
dpiContext
)

Set the DPI awareness for the current thread to the provided value.

public static long

Returns:

the previous value at the given index
SetWindowLongPtr
(long
a handle to the window and, indirectly, the class to which the window belongs
hWnd
,
int
the zero-based offset to the value to be set. Valid values are in the range zero through the number of bytes of extra window memory, minus the size of an integer. To set any other value, specify one of:
GWL_WNDPROCGWL_HINSTANCEGWL_HWNDPARENTGWL_STYLEGWL_EXSTYLEGWL_USERDATAGWL_ID
nIndex
,
long
the replacement value
dwNewLong
)

Changes an attribute of the specified window.

public static boolean
SetWindowPlacement(long
a handle to the window
hWnd
,
WINDOWPLACEMENT
a pointer to the WINDOWPLACEMENT structure that specifies the new show state and window positions.

Before calling SetWindowPlacement, set the length member of the WINDOWPLACEMENT structure to WINDOWPLACEMENT#SIZEOF. SetWindowPlacement fails if the length member is not set correctly.

lpwndpl
)

Sets the show state and the restored, minimized, and maximized positions of the specified window.

public static boolean
SetWindowPos(long
a handle to the window
hWnd
,
long
a handle to the window to precede the positioned window in the Z order. This parameter must be a window handle or one of:
HWND_TOPHWND_BOTTOMHWND_TOPMOSTHWND_NOTOPMOST
hWndInsertAfter
,
int
the new position of the left side of the window, in client coordinates
X
,
int
the new position of the top of the window, in client coordinates
Y
,
int
the new width of the window, in pixels
cx
,
int
the new height of the window, in pixels
cy
,
int uFlags)

Changes the size, position, and Z order of a child, pop-up, or top-level window.

public static boolean
SetWindowText(long
a handle to the window or control whose text is to be changed
hWnd
,
ByteBuffer
the new title or control text
lpString
)

Changes the text of the specified window's title bar (if it has one).

public static boolean
SetWindowText(long
a handle to the window or control whose text is to be changed
hWnd
,
CharSequence
the new title or control text
lpString
)

Changes the text of the specified window's title bar (if it has one).

public static int

Returns:

the new display counter
ShowCursor
(boolean
If show is WinBase#TRUE, the display count is incremented by one. If show is WinBase#FALSE, the display count is decremented by one.
show
)

Displays or hides the cursor.

public static boolean
ShowWindow(long
a handle to the window
hWnd
,
int
controls how the window is to be shown. This parameter is ignored the first time an application calls ShowWindow, if the program that launched the application provides a STARTUPINFO structure. Otherwise, the first time ShowWindow is called, the value should be the value obtained by the WinMain function in its nCmdShow parameter. In subsequent calls, this parameter can be one of:
SW_HIDESW_SHOWNORMALSW_NORMALSW_SHOWMINIMIZEDSW_SHOWMAXIMIZEDSW_MAXIMIZE
SW_SHOWNOACTIVATESW_SHOWSW_MINIMIZESW_SHOWMINNOACTIVESW_SHOWNASW_RESTORE
SW_SHOWDEFAULTSW_FORCEMINIMIZESW_MAX
nCmdShow
)

Sets the specified window's show state.

public static boolean
TranslateMessage(MSG
an MSG structure that contains message information retrieved from the calling thread's message queue by using the GetMessage or PeekMessage function.
lpMsg
)

Translates virtual-key messages into character messages.

public static boolean
UnregisterClass(ByteBuffer
a null-terminated string or a class atom. If lpClassName is a string, it specifies the window class name. This class name must have been registered by a previous call to the RegisterClassEx function. System classes, such as dialog box controls, cannot be unregistered. If this parameter is an atom, it must be a class atom created by a previous call to the RegisterClassEx function. The atom must be in the low-order word of lpClassName; the high-order word must be zero.
lpClassName
,
long
a handle to the instance of the module that created the class
hInstance
)

Unregisters a window class, freeing the memory required for the class.

public static boolean
UnregisterClass(CharSequence
a null-terminated string or a class atom. If lpClassName is a string, it specifies the window class name. This class name must have been registered by a previous call to the RegisterClassEx function. System classes, such as dialog box controls, cannot be unregistered. If this parameter is an atom, it must be a class atom created by a previous call to the RegisterClassEx function. The atom must be in the low-order word of lpClassName; the high-order word must be zero.
lpClassName
,
long
a handle to the instance of the module that created the class
hInstance
)

Unregisters a window class, freeing the memory required for the class.

public static boolean
UnregisterTouchWindow(long
the handle of the window. The function fails with ERROR_ACCESS_DENIED if the calling thread does not own the specified window.
hWnd
)

Registers a window as no longer being touch-capable.

public static boolean
UpdateWindow(long
handle to the window to be updated
hWnd
)

Updates the client area of the specified window by sending a WM_PAINT message to the window if the window's update region is not empty.

public static boolean
WaitMessage()

Yields control to other threads when a thread has no other messages in its message queue.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait