AdjustWindowRect function user32
Calculates the required size of the window rectangle, based on the desired client-rectangle size.
The window rectangle can then be passed to the CreateWindow function to create a window whose client area is the desired size.
To learn more, see learn.microsoft.com/windows/win32/api/winuser/nf-winuser-adjustwindowrect.
Implementation
Win32Result<bool> AdjustWindowRect(
Pointer<RECT> lpRect,
WINDOW_STYLE dwStyle,
bool bMenu,
) {
final result_ = AdjustWindowRect_Wrapper(
lpRect,
dwStyle,
bMenu ? TRUE : FALSE,
);
return .new(value: result_.value.i32 != FALSE, error: result_.error);
}