Loading...
Searching...
No Matches
WindowBase.hpp
Go to the documentation of this file.
7// In no event will the authors be held liable for any damages arising from the use of this software.
90 WindowBase(VideoMode mode, const String& title, std::uint32_t style = Style::Default, State state = State::Windowed);
Utility string class that automatically handles conversions between types and encodings.
Definition String.hpp:89
void setMouseCursorGrabbed(bool grabbed)
Grab or release the mouse cursor.
void setMouseCursor(const Cursor &cursor)
Set the displayed cursor to a native system cursor.
void setIcon(Vector2u size, const std::uint8_t *pixels)
Change the window's icon.
bool createVulkanSurface(const VkInstance &instance, VkSurfaceKHR &surface, const VkAllocationCallbacks *allocator=nullptr)
Create a Vulkan rendering surface.
void requestFocus()
Request the current window to be made the active foreground window.
WindowBase(VideoMode mode, const String &title, State state)
Construct a new window.
std::optional< Event > pollEvent()
Pop the next event from the front of the FIFO event queue, if any, and return it.
virtual void create(VideoMode mode, const String &title, std::uint32_t style=Style::Default, State state=State::Windowed)
Create (or recreate) the window.
void setMaximumSize(const std::optional< Vector2u > &maximumSize)
Set the maximum window rendering region size.
void setPosition(Vector2i position)
Change the position of the window on screen.
void setMinimumSize(const std::optional< Vector2u > &minimumSize)
Set the minimum window rendering region size.
WindowBase(WindowHandle handle)
Construct the window from an existing control.
std::optional< Event > waitEvent(Time timeout=Time::Zero)
Wait for an event and return it.
void setSize(Vector2u size)
Change the size of the rendering region of the window.
void setJoystickThreshold(float threshold)
Change the joystick threshold.
WindowBase(VideoMode mode, const String &title, std::uint32_t style=Style::Default, State state=State::Windowed)
Construct a new window.
WindowHandle getNativeHandle() const
Get the OS-specific handle of the window.
void setMouseCursorVisible(bool visible)
Show or hide the mouse cursor.
void setKeyRepeatEnabled(bool enabled)
Enable or disable automatic key-repeat.
"platform-specific" WindowHandle
Low-level window handle type, specific to each platform.
Definition WindowHandle.hpp:68
Definition WindowEnums.hpp:31
Definition AudioResource.hpp:36
@ Zero
If the stencil test passes, the value in the stencil buffer is set to zero.
Definition StencilMode.hpp:63