- clearvoid clear(Color color) 
- Clear the entire target with a single color. 
- closevoid close() 
- Close the window and destroy all the attached resources. 
- createvoid create(VideoMode mode, string title, Style style, const(ContextSettings) settings) 
- Create (or recreate) the window. 
- createvoid create(VideoMode mode, wstring title, Style style, const(ContextSettings) settings) 
- Create (or recreate) the window. 
- createvoid create(VideoMode mode, dstring title, Style style, const(ContextSettings) settings) 
- Create (or recreate) the window. 
- createvoid create(WindowHandle handle, const(ContextSettings) settings) 
- Create (or recreate) the window from an existing control. 
- displayvoid display() 
- Display on screen what has been rendered to the window so far. 
- drawvoid draw(Drawable drawable, RenderStates states) 
- Draw a drawable object to the render target. 
- drawvoid draw(const(Vertex)[] vertices, PrimitiveType type, RenderStates states) 
- Draw primitives defined by an array of vertices. 
- getDefaultViewconst(View) getDefaultView() 
- Get the default view of the render target. 
- getMousePositionVector2i getMousePosition() 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- getSettingsContextSettings getSettings() 
- Get the settings of the OpenGL context of the window. 
- getSizeVector2u getSize() 
- Return the size of the rendering region of the target. 
- getSystemHandleWindowHandle getSystemHandle() 
- Get the OS-specific handle of the window. 
- getViewportIntRect getViewport(const(View) view) 
- Get the viewport of a view, applied to this render target. 
- isOpenbool isOpen() 
- Tell whether or not the window is open. 
- mapCoordsToPixelVector2i mapCoordsToPixel(Vector2f point) 
- Convert a point from target coordinates to world coordinates, using the current view. 
- mapCoordsToPixelVector2i mapCoordsToPixel(Vector2f point, const(View) view) 
- Convert a point from world coordinates to target coordinates. 
- mapPixelToCoordsVector2f mapPixelToCoords(Vector2i point) 
- Convert a point fom target coordinates to world coordinates, using the current view. 
- mapPixelToCoordsVector2f mapPixelToCoords(Vector2i point, const(View) view) 
- Convert a point from target coordinates to world coordinates. 
- pollEventbool pollEvent(Event event) 
- Pop the event on top of the event queue, if any, and return it. 
- popGLStatesvoid popGLStates() 
- Restore the previously saved OpenGL render states and matrices. 
- pushGLStatesvoid pushGLStates() 
- Save the current OpenGL render states and matrices. 
- resetGLStatesvoid resetGLStates() 
- Reset the internal OpenGL states so that the target is ready for drawing. 
- setActivebool setActive(bool active) 
- Get the viewport of a view, applied to this render target. 
- setFramerateLimitvoid setFramerateLimit(uint limit) 
- Limit the framerate to a maximum fixed frequency. 
- setIconvoid setIcon(uint width, uint height, const(ubyte[]) pixels) 
- Change the window's icon. 
- setJoystickThreshholdvoid setJoystickThreshhold(float threshhold) 
- Change the joystick threshold. 
- setKeyRepeatEnabledvoid setKeyRepeatEnabled(bool enabled) 
- Enable or disable automatic key-repeat. 
- setMouseCursorVisiblevoid setMouseCursorVisible(bool visible) 
- Show or hide the mouse cursor. 
- setMousePositionvoid setMousePosition(Vector2i pos) 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- setTitlevoid setTitle(string newTitle) 
- Change the title of the window 
- setTitlevoid setTitle(wstring newTitle) 
- Change the title of the window 
- setTitlevoid setTitle(dstring newTitle) 
- Change the title of the window 
- setVerticalSyncEnabledvoid setVerticalSyncEnabled(bool enabled) 
- Enable or disable vertical synchronization. 
- setVisiblevoid setVisible(bool visible) 
- waitEventbool waitEvent(Event event) 
- Wait for an event and return it. 
- Styleenum Style 
- Undocumented in source. 
- sfPtrsfWindow* sfPtr; 
- Undocumented in source. 
- deleteWindowPtrvoid deleteWindowPtr() 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- ~this~this() 
- Undocumented in source. 
- positionVector2i position [@property setter] 
- Get's or set's the window's position. 
- positionVector2i position [@property getter] 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- sizeVector2u size [@property setter] 
- Get's or set's the window's size. 
- sizeVector2u size [@property getter] 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- setActivebool setActive(bool active) 
- Activate or deactivate the window as the current target for OpenGL rendering. 
- setFramerateLimitvoid setFramerateLimit(uint limit) 
- Limit the framerate to a maximum fixed frequency. 
- setIconvoid setIcon(uint width, uint height, const(ubyte[]) pixels) 
- Change the window's icon. 
- setJoystickThreshholdvoid setJoystickThreshhold(float threshhold) 
- Change the joystick threshold. 
- setKeyRepeatEnabledvoid setKeyRepeatEnabled(bool enabled) 
- Enable or disable automatic key-repeat. 
- setMouseCursorVisiblevoid setMouseCursorVisible(bool visible) 
- Show or hide the mouse cursor. 
- setTitlevoid setTitle(string newTitle) 
- Change the title of the window. 
- setTitlevoid setTitle(wstring newTitle) 
- Change the title of the window. 
- setTitlevoid setTitle(dstring newTitle) 
- Change the title of the window. 
- setVisiblevoid setVisible(bool visible) 
- setVerticalSyncEnabledvoid setVerticalSyncEnabled(bool enabled) 
- Enable or disable vertical synchronization. 
- getSettingsContextSettings getSettings() 
- Get the settings of the OpenGL context of the window. 
- getSystemHandleWindowHandle getSystemHandle() 
- Get the OS-specific handle of the window. 
- closevoid close() 
- Close the window and destroy all the attached resources. 
- createvoid create(VideoMode mode, string title, Style style, const(ContextSettings) settings) 
- Create (or recreate) the window. 
- createvoid create(VideoMode mode, wstring title, Style style, const(ContextSettings) settings) 
- Create (or recreate) the window. 
- createvoid create(VideoMode mode, dstring title, Style style, const(ContextSettings) settings) 
- Create (or recreate) the window. 
- createvoid create(WindowHandle handle, const(ContextSettings) settings) 
- Create (or recreate) the window from an existing control. 
- displayvoid display() 
- Display on screen what has been rendered to the window so far. 
- isOpenbool isOpen() 
- Tell whether or not the window is open. 
- pollEventbool pollEvent(Event event) 
- Pop the event on top of the event queue, if any, and return it. 
- waitEventbool waitEvent(Event event) 
- Wait for an event and return it. 
- getMousePositionVector2i getMousePosition() 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- mouse_getPositionVector2i mouse_getPosition() 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- setMousePositionvoid setMousePosition(Vector2i pos) 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- mouse_SetPositionvoid mouse_SetPosition(Vector2i pos) 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- getWindowPointervoid* getWindowPointer(Window window) 
- Undocumented in source. Be warned that the author may not have intended to support it. 
- viewconst(View) view [@property setter] 
- Change the current active view. 
- viewconst(View) view [@property getter] 
- Undocumented in source. 
- getDefaultViewconst(View) getDefaultView() 
- Get the default view of the render target. 
- getSizeVector2u getSize() 
- Return the size of the rendering region of the target. 
- getViewportIntRect getViewport(const(View) view) 
- Get the viewport of a view, applied to this render target. 
- clearvoid clear(Color color) 
- Clear the entire target with a single color. 
- drawvoid draw(Drawable drawable, RenderStates states) 
- Draw a drawable object to the render target. 
- drawvoid draw(const(Vertex)[] vertices, PrimitiveType type, RenderStates states) 
- Draw primitives defined by an array of vertices. 
- mapPixelToCoordsVector2f mapPixelToCoords(Vector2i point) 
- Convert a point fom target coordinates to world coordinates, using the current view. 
- mapPixelToCoordsVector2f mapPixelToCoords(Vector2i point, const(View) view) 
- Convert a point from target coordinates to world coordinates. 
- mapCoordsToPixelVector2i mapCoordsToPixel(Vector2f point) 
- Convert a point from target coordinates to world coordinates, using the current view. 
- mapCoordsToPixelVector2i mapCoordsToPixel(Vector2f point, const(View) view) 
- Convert a point from world coordinates to target coordinates. 
- popGLStatesvoid popGLStates() 
- Restore the previously saved OpenGL render states and matrices. 
- pushGLStatesvoid pushGLStates() 
- Save the current OpenGL render states and matrices. 
- resetGLStatesvoid resetGLStates() 
- Reset the internal OpenGL states so that the target is ready for drawing. 
Window that can serve as a target for 2D drawing.
RenderWindow is the main class of the Graphics package.
It defines an OS window that can be painted using the other classes of the graphics module.
RenderWindow is derived from Window, thus it inherits all its features: events, window management, OpenGL rendering, etc. See the documentation of Window for a more complete description of all these features, as well as code examples.
On top of that, RenderWindow adds more features related to 2D drawing with the graphics module (see its base class RenderTarget for more details).
Like Window, RenderWindow is still able to render direct OpenGL stuff. It is even possible to mix together OpenGL calls and regular SFML drawing commands.