Loading...
Searching...
No Matches
WindowBase.h
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.
84CSFML_WINDOW_API sfWindowBase* sfWindowBase_create(sfVideoMode mode, const char* title, uint32_t style, sfWindowState state);
103CSFML_WINDOW_API sfWindowBase* sfWindowBase_createUnicode(sfVideoMode mode, const sfChar32* title, uint32_t style, sfWindowState state);
192CSFML_WINDOW_API bool sfWindowBase_waitEvent(sfWindowBase* windowBase, sfTime timeout, sfEvent* event);
255CSFML_WINDOW_API void sfWindowBase_setUnicodeTitle(sfWindowBase* windowBase, const sfChar32* title);
268CSFML_WINDOW_API void sfWindowBase_setIcon(sfWindowBase* windowBase, sfVector2u size, const uint8_t* pixels);
286CSFML_WINDOW_API void sfWindowBase_setMouseCursorVisible(sfWindowBase* windowBase, bool visible);
302CSFML_WINDOW_API void sfWindowBase_setMouseCursorGrabbed(sfWindowBase* windowBase, bool grabbed);
322CSFML_WINDOW_API void sfWindowBase_setMouseCursor(sfWindowBase* windowBase, const sfCursor* cursor);
349CSFML_WINDOW_API void sfWindowBase_setJoystickThreshold(sfWindowBase* windowBase, float threshold);
sfVector2i sfWindowBase_getPosition(const sfWindowBase *windowBase)
Get the position of a window.
void sfWindowBase_setUnicodeTitle(sfWindowBase *windowBase, const sfChar32 *title)
Change the title of a window (with a UTF-32 string)
bool sfWindowBase_hasFocus(const sfWindowBase *windowBase)
Check whether the window has the input focus.
bool sfWindowBase_createVulkanSurface(sfWindowBase *windowBase, const VkInstance *instance, VkSurfaceKHR *surface, const VkAllocationCallbacks *allocator)
Create a Vulkan rendering surface.
void sfWindowBase_setSize(sfWindowBase *windowBase, sfVector2u size)
Change the size of the rendering region of a window.
void sfWindowBase_close(sfWindowBase *windowBase)
Close a window and destroy all the attached resources.
void sfWindowBase_setVisible(sfWindowBase *windowBase, bool visible)
Show or hide a window.
sfWindowBase * sfWindowBase_create(sfVideoMode mode, const char *title, uint32_t style, sfWindowState state)
Construct a new window.
sfVector2u sfWindowBase_getSize(const sfWindowBase *windowBase)
Get the size of the rendering region of a window.
bool sfWindowBase_pollEvent(sfWindowBase *windowBase, sfEvent *event)
Pop the event on top of event queue, if any, and return it.
sfWindowBase * sfWindowBase_createUnicode(sfVideoMode mode, const sfChar32 *title, uint32_t style, sfWindowState state)
Construct a new window (with a UTF-32 title)
bool sfWindowBase_waitEvent(sfWindowBase *windowBase, sfTime timeout, sfEvent *event)
Wait for an event and return it.
@ sfNone
No border / title bar (this flag and all others are mutually exclusive)
Definition WindowBase.h:47
void sfWindowBase_setKeyRepeatEnabled(sfWindowBase *windowBase, bool enabled)
Enable or disable automatic key-repeat.
void sfWindowBase_setIcon(sfWindowBase *windowBase, sfVector2u size, const uint8_t *pixels)
Change a window's icon.
sfWindowBase * sfWindowBase_createFromHandle(sfWindowHandle handle)
Construct a window from an existing control.
sfWindowHandle sfWindowBase_getNativeHandle(const sfWindowBase *windowBase)
Get the OS-specific handle of the window.
void sfWindowBase_setPosition(sfWindowBase *windowBase, sfVector2i position)
Change the position of a window on screen.
void sfWindowBase_setTitle(sfWindowBase *windowBase, const char *title)
Change the title of a window.
void sfWindowBase_requestFocus(sfWindowBase *windowBase)
Request the current window to be made the active foreground window.
void sfWindowBase_setJoystickThreshold(sfWindowBase *windowBase, float threshold)
Change the joystick threshold.
void sfWindowBase_setMouseCursor(sfWindowBase *windowBase, const sfCursor *cursor)
Set the displayed cursor to a native system cursor.
void sfWindowBase_setMouseCursorVisible(sfWindowBase *windowBase, bool visible)
Show or hide the mouse cursor.
void sfWindowBase_setMouseCursorGrabbed(sfWindowBase *windowBase, bool grabbed)
Grab or release the mouse cursor.
bool sfWindowBase_isOpen(const sfWindowBase *windowBase)
Tell whether or not a window is opened.
sfVideoMode defines a video mode (width, height, bpp, frequency) and provides functions for getting m...
Definition VideoMode.h:44