diff options
| -rw-r--r-- | src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx | 2 | ||||
| -rw-r--r-- | src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx b/src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx index dc5bbaca3..6033ed2a4 100644 --- a/src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx +++ b/src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx @@ -1477,7 +1477,9 @@ void Fl_Cairo_Graphics_Driver::restore_clip() { clip_->y = rect.y; clip_->w = rect.width; clip_->h = rect.height; + cairo_set_antialias(cairo_, CAIRO_ANTIALIAS_NONE); cairo_clip(cairo_); + cairo_set_antialias(cairo_, CAIRO_ANTIALIAS_DEFAULT ); } else if (clip_) { clip_->w = -1; } diff --git a/src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx b/src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx index 290cb0873..912f9675c 100644 --- a/src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx +++ b/src/drivers/Wayland/Fl_Wayland_Graphics_Driver.cxx @@ -149,8 +149,8 @@ static void copy_region(struct wld_window *window, cairo_region_t *r) { cairo_region_get_rectangle(r, i, &rect); int left = rect.x * f; int top = rect.y * f; - int width = rect.width * f; - int height = rect.height * f; + int width = ceil((rect.x + rect.width)*f) - left; + int height = ceil((rect.y + rect.height)*f) - top; int offset = top * buffer->draw_buffer.stride + 4 * left; int W4 = 4 * width; for (int l = 0; l < height; l++) { |
