diff --git a/sway/desktop/output.c b/sway/desktop/output.c index 6d4f53423..ab8fd7e85 100644 --- a/sway/desktop/output.c +++ b/sway/desktop/output.c @@ -99,8 +99,8 @@ static bool get_surface_box(struct surface_iterator_data *data, int sw = surface->current.width; int sh = surface->current.height; - double _sx = sx + surface->sx; - double _sy = sy + surface->sy; + double _sx = sx; + double _sy = sy; rotate_child_position(&_sx, &_sy, sw, sh, data->width, data->height, data->rotation); diff --git a/sway/desktop/render.c b/sway/desktop/render.c index a105ffbac..608f3ee92 100644 --- a/sway/desktop/render.c +++ b/sway/desktop/render.c @@ -162,8 +162,8 @@ static void render_surface_iterator(struct sway_output *output, struct sway_view struct wlr_box dst_box = *_box; struct sway_container *container = data->container; if (container != NULL) { - dst_box.width = fmin(dst_box.width, container->current.content_width - surface->sx); - dst_box.height = fmin(dst_box.height, container->current.content_height - surface->sy); + dst_box.width = fmin(dst_box.width, container->current.content_width); + dst_box.height = fmin(dst_box.height, container->current.content_height); } scale_box(&dst_box, wlr_output->scale);