From 1f85e9c7fe8723995561adf4c84772f0af52cb6d Mon Sep 17 00:00:00 2001 From: Aneesh Dogra Date: Sat, 22 Dec 2012 15:34:53 +0000 Subject: Fix constellations overlapping and clear the combobox before filling. --- diff --git a/ConstellationsFlashCards.py b/ConstellationsFlashCards.py index fc55dbc..66c87e6 100644 --- a/ConstellationsFlashCards.py +++ b/ConstellationsFlashCards.py @@ -355,9 +355,7 @@ class ChartDisplay(Gtk.DrawingArea): self.diameter + 4, self.diameter + 4) self.ctx.fill() - # Plot sky square - color_rgb = Color(self.colors[1]).get_rgba()[:-1] # we don't need alpha self.ctx.set_source_rgb(*color_rgb) self.ctx.rectangle(self.xoffset + self.margin - 2, @@ -612,6 +610,7 @@ class ChartDisplay(Gtk.DrawingArea): def fill_names_combobox(self): + cbq1.remove_all() # Create a list of five names, initialized to "" names = ["", "", "", "", ""] @@ -654,11 +653,12 @@ class ChartDisplay(Gtk.DrawingArea): # Clear the drawing surface color_rgb = Color(self.colors[2]).get_rgba()[:-1] # we don't need alpha + self.ctx = self.get_window().cairo_create() self.ctx.set_source_rgb(*color_rgb) self.ctx.rectangle(self.xoffset + self.margin - 2, - self.yoffset + self.margin - 2, - self.screensize[0], - self.screensize[1]) + self.yoffset + self.margin - 2, + self.screensize[0], + self.screensize[1]) self.ctx.fill() -- cgit v0.9.1