| Nui
    | 
This class encapsulates the webview. More...
#include <window.hpp>
| Classes | |
| struct | Implementation | 
| struct | LinuxImplementation | 
| struct | MacOsImplementation | 
| struct | WindowsImplementation | 
| Public Member Functions | |
| Window () | |
| Construct a new Window object. | |
| Window (WindowOptions const &options) | |
| Construct a new Window object. | |
| Window (bool debug) | |
| Construct a new Window object. | |
| Window (std::string const &title, bool debug=false) | |
| Construct a new Window object. | |
| Window (char const *title, bool debug=false) | |
| Construct a new Window object. | |
| ~Window () | |
| Window (const Window &)=delete | |
| Window & | operator= (const Window &)=delete | 
| Window (Window &&) | |
| Window & | operator= (Window &&) | 
| void | setTitle (std::string const &title) | 
| Set the Title of the window. | |
| void | setSize (int width, int height, WebViewHint hint=WebViewHint::WEBVIEW_HINT_NONE) | 
| Sets the size of the window. | |
| void | setPosition (int x, int y, bool useFrameOrigin=true) | 
| Sets the position of the window. | |
| void | centerOnPrimaryDisplay () | 
| Center the window on the primary display. | |
| void | navigate (const std::string &url) | 
| Navigate to url. | |
| void | navigate (char const *url) | 
| Navigate to url. | |
| void | terminate () | 
| Close the window and exit run. | |
| void | openDevTools () | 
| Open the dev tools. | |
| void | runInJavascriptThread (std::function< void()> &&func) | 
| Static Public Attributes | |
| static constexpr std::string_view | windowsServeAuthority = "app.example" | 
This class encapsulates the webview.
| Nui::Window::Window | ( | ) | 
Construct a new Window object.
| 
 | explicit | 
Construct a new Window object.
| options | Additional options. | 
| 
 | explicit | 
Construct a new Window object.
| debug | If true, the dev tools may be opened. | 
| options | Additional options. | 
| 
 | explicit | 
Construct a new Window object.
| title | The title of the window. | 
| debug | If true, the dev tools may be opened. | 
| options | Additional options. | 
| 
 | explicit | 
Construct a new Window object.
| title | The title of the window. | 
| debug | If true, the dev tools may be opened. | 
| options | Additional options. | 
| 
 | default | 
| 
 | delete | 
| 
 | default | 
| void Nui::Window::centerOnPrimaryDisplay | ( | ) | 
Center the window on the primary display.
Requires size to be set first.
| void Nui::Window::navigate | ( | char const * | url | ) | 
Navigate to url.
| url | 
| void Nui::Window::navigate | ( | const std::string & | url | ) | 
Navigate to url.
| url | 
| void Nui::Window::openDevTools | ( | ) | 
Open the dev tools.
| void Nui::Window::runInJavascriptThread | ( | std::function< void()> && | func | ) | 
| void Nui::Window::setPosition | ( | int | x, | 
| int | y, | ||
| bool | useFrameOrigin = true | ||
| ) | 
Sets the position of the window.
| x | xCoordinate | 
| y | yCoordinate | 
| (MacOS | only) use setFrameOrigin instead of setFrameTopLeftPoint (see apple doc) | 
| void Nui::Window::setSize | ( | int | width, | 
| int | height, | ||
| WebViewHint | hint = WebViewHint::WEBVIEW_HINT_NONE | ||
| ) | 
Sets the size of the window.
| width | |
| height | |
| hint | 
| void Nui::Window::setTitle | ( | std::string const & | title | ) | 
Set the Title of the window.
| title | 
| void Nui::Window::terminate | ( | ) | 
Close the window and exit run.
| 
 | staticconstexpr |