Make sure armui value is initialized before use
Signed-off-by: Maxwell Henderson <mxwhenderson@gmail.com>
Change-Id: I6a77d3b0083024494d83420561a67a0cbe868b48
diff --git a/y2023/control_loops/python/graph_edit.py b/y2023/control_loops/python/graph_edit.py
index bbc7a1b..99b09af 100644
--- a/y2023/control_loops/python/graph_edit.py
+++ b/y2023/control_loops/python/graph_edit.py
@@ -244,6 +244,7 @@
self.set_size_request(ARM_AREA_WIDTH, ARM_AREA_HEIGHT)
self.center = (0, 0)
self.shape = (ARM_AREA_WIDTH, ARM_AREA_HEIGHT)
+ self.window_shape = (ARM_AREA_WIDTH, ARM_AREA_HEIGHT)
self.theta_version = False
self.init_extents()
@@ -326,9 +327,6 @@
def on_draw(self, widget, event):
cr = self.get_window().cairo_create()
- self.window_shape = (self.get_window().get_geometry().width,
- self.get_window().get_geometry().height)
-
cr.save()
cr.set_font_size(20)
cr.translate(self.window_shape[0] / 2, self.window_shape[1] / 2)