view: honor automatic placement when adjusting floating geometry

The view_adjust_floating_geometry function is called when un-maximizing
a window or changing the output layout to ensure that views are well
placed. Rather than always centering these views should they fall
offscren, use the automatic placement strategy if so configured.
This commit is contained in:
Andrew J. Hesford 2023-12-30 11:19:27 -05:00
parent 7f357a388b
commit b5bc72d66e
4 changed files with 32 additions and 19 deletions

View file

@ -3,8 +3,9 @@
#define LABWC_PLACEMENT_H
#include <stdbool.h>
#include <wlr/util/box.h>
#include "view.h"
bool placement_find_best(struct view *view, int *x, int *y);
bool placement_find_best(struct view *view, struct wlr_box *geometry);
#endif /* LABWC_PLACEMENT_H */