From eb526e6dbd964095e0117c876719b47f9c00ae26 Mon Sep 17 00:00:00 2001 From: not-avail Date: Thu, 21 Jun 2018 13:17:26 -0700 Subject: [PATCH] Adjust the canvas borders in the demo so that they are not drawn over during a canvas restore --- examples/demo.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/demo.rs b/examples/demo.rs index 3046375..030e85d 100644 --- a/examples/demo.rs +++ b/examples/demo.rs @@ -529,13 +529,13 @@ fn main() { app.add_element( "canvasRegion", UIElementWrapper { - y: CANVAS_REGION.top as usize, + y: (CANVAS_REGION.top - 2) as usize, x: CANVAS_REGION.left as usize, refresh: UIConstraintRefresh::RefreshAndWait, onclick: None, inner: UIElement::Region { - height: CANVAS_REGION.height as usize, - width: CANVAS_REGION.width as usize, + height: (CANVAS_REGION.height + 3) as usize, + width: (CANVAS_REGION.width + 1) as usize, border_px: 2, border_color: color::BLACK, },