1
0
Fork 0
forked from wry/wry

xwayland: set output for override redirect windows

This commit is contained in:
Julian Orth 2024-09-11 23:58:42 +02:00
parent 0dc1929bbd
commit 7ff7edaa8f
7 changed files with 13 additions and 15 deletions

View file

@ -236,4 +236,11 @@ impl Rect {
pub fn size(&self) -> (i32, i32) {
(self.width(), self.height())
}
pub fn center(&self) -> (i32, i32) {
(
self.raw.x1 + self.width() / 2,
self.raw.y1 + self.height() / 2,
)
}
}