Class that represents a Win32 window. More...
#include <kanzi/core.ui/platform/windowing_ng/win32/win32_window.hpp>
Public Member Functions | |
| bool | bringToFront () noexcept |
| Brings a window to the front of every other window in the z-order. | |
| bool | clientToScreen (LPPOINT point) const |
| Converts the client-area coordinates to screen coordinates for a window. | |
| bool | destroyWindow () |
| Destroys the window and all its associated data by sending destroy request to the window procedure. | |
| KZ_NO_DISCARD unsigned int | findWindowZOrder () const noexcept |
| Finds the z ordering for the active window related to all other windows currently visible. | |
| KZ_NO_DISCARD RECT | getClientRect () const noexcept |
| Gets the client extents of the window. | |
| KZ_NO_DISCARD HDC | getDC () const noexcept |
| Gets the associated device context handle of a window. | |
| KZ_NO_DISCARD Win32WindowHandle | getNativeHandle () const noexcept |
| Gets the native window handle. | |
| KZ_NO_DISCARD LONG_PTR | getWindowLongPtr (int index) const |
| Gets the attribute value of a window. | |
| KZ_NO_DISCARD WINDOWPLACEMENT | getWindowPlacement () const noexcept |
| Gets the previous placement of the window. | |
| KZ_NO_DISCARD RECT | getWindowRect () const noexcept |
| Gets the entire extents of the window. | |
| KZ_NO_DISCARD string | getWindowText () const |
| Gets the title of the window. | |
| void | killTimer (UINT_PTR id) noexcept |
| Destroys the set timer. | |
| HMONITOR | monitorFromWindow (unsigned long flags) noexcept |
| Gets the display monitor with the largest area of intersection with a window. | |
| bool | moveWindow (int x, int y, int width, int height, bool repaint) noexcept |
| Moves a window to a new position and sets the window size. | |
| bool | releaseDC (Win32DeviceContext &deviceContext) noexcept |
| Releases the device context handle of a window. | |
| bool | screenToClient (LPPOINT point) const |
| Converts the screen coordinates to client-area coordinates for a window. | |
| UINT_PTR | setTimer (UINT_PTR id, unsigned int timeout, TIMERPROC timerProc) noexcept |
| Sets a timer for a window. | |
| bool | setTouchWindowProperty () noexcept |
| Sets the default touch property for a window. | |
| LONG_PTR | setWindowLongPtr (int index, LONG_PTR value) noexcept |
| Sets the attribute value of a window. | |
| bool | setWindowPlacement (WINDOWPLACEMENT windowPlacement) |
| Sets the current placement of the window. | |
| bool | setWindowPosition (Win32WindowHandle insertAfter, int x, int y, int width, int height, unsigned int windowFlags) noexcept |
| Sets the new position of a window. | |
| bool | setWindowText (const char *title) |
| Sets the title of the window. | |
| bool | showWindow (int cmd) noexcept |
| Shows the window. | |
| bool | tryRegisterTouchWindow (const Win32DynamicLibrary &user32Lib) noexcept |
| Tries to dynamically register the touch input for a window. | |
| void | updateWindow () |
| Forces the updating of a window by sending the paint request to the window procedure. | |
| Win32Window (int x, int y, int width, int height, WindowStyle style, const char *className) | |
| Constructor. | |
| Win32Window (int x, int y, int width, int height, WindowStyle style, const Win32WindowClass &windowClass) | |
| Constructor. | |
| Win32Window (Win32WindowHandle nativeHandle) | |
| Constructor. | |
| Win32Window (windowing::Region windowRegion, WindowStyle style, const Win32WindowClass &windowClass) | |
| Constructor. | |
Class that represents a Win32 window.
|
explicit |
Constructor.
| windowRegion | Window extent. |
| style | The style of the window. |
| windowClass | The class to which the window belongs. |
|
explicit |
Constructor.
| x | The horizontal position of the top-left corner of the window in screen coordinates. |
| y | The vertical position of the top-left corner of the window in screen coordinates. |
| width | The horizontal extent of the window in screen coordinates. |
| height | The vertical extent of the window in screen coordinates. |
| style | The style of the window. |
| windowClass | The class name of the window. |
|
explicit |
Constructor.
| x | The horizontal position of the top-left corner of the window in screen coordinates. |
| y | The vertical position of the top-left corner of the window in screen coordinates. |
| width | The horizontal extent of the window in screen coordinates. |
| height | The vertical extent of the window in screen coordinates. |
| style | The style of the window. |
| className | The native class name of the window. |
|
explicit |
Constructor.
| nativeHandle | The window handle. |
Sets the title of the window.
| title | The title to set. |
| KZ_NO_DISCARD string kanzi::win32::Win32Window::getWindowText | ( | ) | const |
Gets the title of the window.
|
noexcept |
Moves a window to a new position and sets the window size.
| x | The horizontal position of the top-left corner of the window in screen coordinates. |
| y | The vertical position of the top-left corner of the window in screen coordinates. |
| width | The horizontal extent of the window in screen coordinates. |
| height | The vertical extent of the window in screen coordinates. |
| repaint | Predicate to do repainting of the window after moving. |
|
noexcept |
Sets the new position of a window.
| insertAfter | The window to insert the window after in z-order. |
| x | The horizontal position of the top-left corner of the window in screen coordinates. |
| y | The vertical position of the top-left corner of the window in screen coordinates. |
| width | The horizontal extent of the window in screen coordinates. |
| height | The vertical extent of the window in screen coordinates. |
| windowFlags | Flags for setting the new window position. |
|
noexcept |
Gets the client extents of the window.
|
noexcept |
Gets the entire extents of the window.
| bool kanzi::win32::Win32Window::setWindowPlacement | ( | WINDOWPLACEMENT | windowPlacement | ) |
Sets the current placement of the window.
|
noexcept |
Gets the previous placement of the window.
Shows the window.
| cmd | How to show the window. |
|
noexcept |
Brings a window to the front of every other window in the z-order.
| void kanzi::win32::Win32Window::updateWindow | ( | ) |
Forces the updating of a window by sending the paint request to the window procedure.
If the update region is empty, does not send a message.
| bool kanzi::win32::Win32Window::destroyWindow | ( | ) |
Destroys the window and all its associated data by sending destroy request to the window procedure.
Converts the screen coordinates to client-area coordinates for a window.
| point | The coordinates to convert. |
Converts the client-area coordinates to screen coordinates for a window.
| point | The coordinates to convert. |
|
noexcept |
Gets the associated device context handle of a window.
|
noexcept |
Releases the device context handle of a window.
| deviceContext | The device context to released. |
Sets the attribute value of a window.
| index | The type of attribute to set. |
| value | The attribute value to set. |
| KZ_NO_DISCARD LONG_PTR kanzi::win32::Win32Window::getWindowLongPtr | ( | int | index | ) | const |
Gets the attribute value of a window.
| index | The type of attribute to get. |
|
noexcept |
Sets a timer for a window.
| id | Timer ID to be set. |
| timeout | Time-out value in milliseconds. Clamped by the system-specific minimum and maximum timer values. |
| timerProc | Function to notify when the timer elapses. If null, sends the timer message to the application message queue. |
Destroys the set timer.
| id | Timer ID to destroy. |
Gets the display monitor with the largest area of intersection with a window.
| flags | Flags to use if the window does not intersect with any display monitor. |
|
noexcept |
Tries to dynamically register the touch input for a window.
| user32Lib | The library with which to register the window. |
|
noexcept |
Sets the default touch property for a window.
|
noexcept |
Finds the z ordering for the active window related to all other windows currently visible.
|
inlinenoexcept |
Gets the native window handle.