summaryrefslogtreecommitdiffstats
path: root/include/sway/tree/view.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/sway/tree/view.h')
-rw-r--r--include/sway/tree/view.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/sway/tree/view.h b/include/sway/tree/view.h
index a4ad9971..21127ab1 100644
--- a/include/sway/tree/view.h
+++ b/include/sway/tree/view.h
@@ -41,9 +41,16 @@ struct sway_view {
41 41
42 struct sway_container *swayc; // NULL for unmapped views 42 struct sway_container *swayc; // NULL for unmapped views
43 struct wlr_surface *surface; // NULL for unmapped views 43 struct wlr_surface *surface; // NULL for unmapped views
44
45 // Geometry of the view itself (excludes borders)
46 double x, y;
44 int width, height; 47 int width, height;
48
45 bool is_fullscreen; 49 bool is_fullscreen;
46 50
51 enum sway_container_border border;
52 int border_thickness;
53
47 union { 54 union {
48 struct wlr_xdg_surface_v6 *wlr_xdg_surface_v6; 55 struct wlr_xdg_surface_v6 *wlr_xdg_surface_v6;
49 struct wlr_xwayland_surface *wlr_xwayland_surface; 56 struct wlr_xwayland_surface *wlr_xwayland_surface;
@@ -160,6 +167,12 @@ const char *view_get_instance(struct sway_view *view);
160void view_configure(struct sway_view *view, double ox, double oy, int width, 167void view_configure(struct sway_view *view, double ox, double oy, int width,
161 int height); 168 int height);
162 169
170/**
171 * Configure the view's position and size based on the swayc's position and
172 * size, taking borders into consideration.
173 */
174void view_autoconfigure(struct sway_view *view);
175
163void view_set_activated(struct sway_view *view, bool activated); 176void view_set_activated(struct sway_view *view, bool activated);
164 177
165void view_set_fullscreen_raw(struct sway_view *view, bool fullscreen); 178void view_set_fullscreen_raw(struct sway_view *view, bool fullscreen);