libnick 2025.7.3
A cross-platform base for native Nickvision applications.
Loading...
Searching...
No Matches
windowgeometry.h
Go to the documentation of this file.
1
22
23#ifndef WINDOWGEOMETRY_H
24#define WINDOWGEOMETRY_H
25
26#include <boost/json.hpp>
27
28namespace Nickvision::App
29{
34 {
35 public:
46 WindowGeometry(long width, long height, bool isMaximized);
55 WindowGeometry(long width, long height, bool isMaximized, long x, long y);
60 WindowGeometry(boost::json::object json);
65 long getWidth() const;
70 void setWidth(long width);
75 long getHeight() const;
80 void setHeight(long height);
85 bool isMaximized() const;
95 long getX() const;
100 void setX(long x);
105 long getY() const;
110 void setY(long y);
115 boost::json::object toJson() const;
116
117 private:
118 long m_width;
119 long m_height;
120 bool m_isMaximized;
121 long m_x;
122 long m_y;
123 };
124}
125
126#endif //WINDOWGEOMETRY_H
WindowGeometry(long width, long height, bool isMaximized, long x, long y)
Construct a WindowGeometry.
boost::json::object toJson() const
Converts the WindowGeometry to a json object.
long getY() const
Gets the y position of the window.
void setIsMaximized(bool isMaximized)
Sets whether or not the window is maximized.
void setWidth(long width)
Sets the width of the window.
WindowGeometry(boost::json::object json)
Constructs a WindowGeometry.
WindowGeometry()
Construct a WindowGeometry.
WindowGeometry(long width, long height, bool isMaximized)
Construct a WindowGeometry.
void setHeight(long height)
Sets the height of the window.
void setY(long y)
Sets the y position of the window.
long getWidth() const
Gets the width of the window.
bool isMaximized() const
Gets whether or not the window is maximized.
long getHeight() const
Gets the height of the window.
long getX() const
Gets the x position of the window.
void setX(long x)
Sets the x position of the window.
Definition appinfo.h:32