From 5d3d0f2166695687aa319cc56919c971adc82843 Mon Sep 17 00:00:00 2001 From: Denvi Date: Mon, 5 Sep 2016 16:42:29 +0500 Subject: [PATCH] #211 "Origin lines do not cross the origin at startup" fix (cherry picked from commit f7f41b5) --- VisPyCanvas.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/VisPyCanvas.py b/VisPyCanvas.py index 6fe8ff3..8d42bb1 100644 --- a/VisPyCanvas.py +++ b/VisPyCanvas.py @@ -37,15 +37,16 @@ class VisPyCanvas(scene.SceneCanvas): view = grid.add_view(row=1, col=1, border_color='black', bgcolor='white') view.camera = Camera(aspect=1) + # Following function was removed from 'prepare_draw()' of 'Grid' class by patch, + # it is necessary to call manually + grid._update_child_widget_dim() + grid1 = scene.GridLines(parent=view.scene, color='gray') grid1.set_gl_state(depth_test=False) xaxis.link_view(view) yaxis.link_view(view) - # shapes = scene.Line(parent=view.scene) - # view.add(shapes) - self.grid = grid1 self.view = view self.freeze()