The following code example demonstrate the use of screen class.
#include <xtd/xtd>
int main() {
form1.
size({area.
size().width() / 2, area.size().
height() / 2});
form1.
text(
"screen 1/4");
form2.
location({area.location().x() + area.size().
width() / 2, area.location().
y()});
form2.
size({area.size().width() / 2, area.size().
height() / 2});
form2.
text(
"screen 2/4");
form3.
location({area.location().x(), area.location().
y() + area.size().
height() / 2});
form3.
size({area.size().width() / 2, area.size().
height() / 2});
form3.
text(
"screen 3/4");
form4.
location({area.location().x() + area.size().
width() / 2, area.location().
y() + area.size().
height() / 2});
form4.
size({area.size().width() / 2, area.size().
height() / 2});
form4.
text(
"screen 4/4");
application::run(form1);
}
int32_t y() const
Gets the y-coordinate of this point.
Definition point.h:205
Stores a set of four integers that represent the location and size of a rectangle.
Definition rectangle.h:25
int32_t width() const
Gets the horizontal component of this Size class.
Definition size.h:67
int32_t height() const
Gets he vertical component of this Size Class.
Definition size.h:57