Skip to content

Commit

Permalink
Add API for sf::WindowBase
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisThrasher committed Nov 2, 2023
1 parent 759f78d commit 05732ce
Show file tree
Hide file tree
Showing 6 changed files with 700 additions and 31 deletions.
1 change: 1 addition & 0 deletions include/SFML/Window/Types.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
typedef struct sfContext sfContext;
typedef struct sfCursor sfCursor;
typedef struct sfWindow sfWindow;
typedef struct sfWindowBase sfWindowBase;


#endif // SFML_WINDOW_TYPES_H
32 changes: 1 addition & 31 deletions include/SFML/Window/Window.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,26 +31,12 @@
#include <SFML/Window/Export.h>
#include <SFML/Window/Event.h>
#include <SFML/Window/VideoMode.h>
#include <SFML/Window/WindowBase.h>
#include <SFML/Window/WindowHandle.h>
#include <SFML/Window/Types.h>
#include <SFML/System/Vector2.h>


////////////////////////////////////////////////////////////
/// \brief Enumeration of window creation styles
///
////////////////////////////////////////////////////////////
typedef enum
{
sfNone = 0, ///< No border / title bar (this flag and all others are mutually exclusive)
sfTitlebar = 1 << 0, ///< Title bar + fixed border
sfResize = 1 << 1, ///< Titlebar + resizable border + maximize button
sfClose = 1 << 2, ///< Titlebar + close button
sfFullscreen = 1 << 3, ///< Fullscreen mode (this flag and all others are mutually exclusive)
sfDefaultStyle = sfTitlebar | sfResize | sfClose ///< Default window style
} sfWindowStyle;


////////////////////////////////////////////////////////////
/// \brief Enumeration of the context attribute flags
///
Expand All @@ -63,22 +49,6 @@ typedef enum
} sfContextAttribute;


////////////////////////////////////////////////////////////
/// \brief Structure defining the window's creation settings
///
////////////////////////////////////////////////////////////
typedef struct
{
unsigned int depthBits; ///< Bits of the depth buffer
unsigned int stencilBits; ///< Bits of the stencil buffer
unsigned int antialiasingLevel; ///< Level of antialiasing
unsigned int majorVersion; ///< Major number of the context version to create
unsigned int minorVersion; ///< Minor number of the context version to create
sfUint32 attributeFlags; ///< The attribute flags to create the context with
sfBool sRgbCapable; ///< Whether the context framebuffer is sRGB capable
} sfContextSettings;


////////////////////////////////////////////////////////////
/// \brief Construct a new window
///
Expand Down
Loading

0 comments on commit 05732ce

Please sign in to comment.