From 8c22589b85f85199081f7f5ba7b83670b97a32d9 Mon Sep 17 00:00:00 2001 From: miro Date: Sat, 16 Nov 2024 18:29:47 +0000 Subject: [PATCH 1/2] fix: gui images image path for GUI is wrong --- __init__.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/__init__.py b/__init__.py index d5237ad..7ef96d9 100644 --- a/__init__.py +++ b/__init__.py @@ -38,10 +38,6 @@ def __init__(self, *args, **kwargs): self.settings["center_location"] = False if "iss_size" not in self.settings: self.settings["iss_size"] = 0.5 - if "iss_icon" not in self.settings: - self.settings["iss_icon"] = f"{self.root_dir}/ui/iss3.png" - if "iss_bg" not in self.settings: - self.settings["iss_bg"] = f"{self.root_dir}/ui/iss.png" if "dpi" not in self.settings: self.settings["dpi"] = 500 @@ -128,7 +124,7 @@ def generate_map(self, lat, lon): m.bluemarble() x, y = m(lon, lat) - iss = plt.imread(self.settings["iss_icon"]) + iss = plt.imread(self.settings.get("iss_icon", f"{self.root_dir}/ui/iss3.png")) im = OffsetImage(iss, zoom=self.settings["iss_size"]) ab = AnnotationBbox(im, (x, y), xycoords='data', frameon=False) @@ -145,7 +141,7 @@ def generate_map(self, lat, lon): @intent_handler("about.intent") def handle_about_iss_intent(self, message): utterance = self.dialog_renderer.render("about", {}) - self.gui.show_image(self.settings["iss_bg"], + self.gui.show_image(self.settings.get("iss_bg", "iss.png"), override_idle=True, fill='PreserveAspectFit', caption=utterance) From 1f2f846d929fafef406dbaec6391b67a7cd34c4e Mon Sep 17 00:00:00 2001 From: miro Date: Sat, 16 Nov 2024 18:30:31 +0000 Subject: [PATCH 2/2] fix: gui images image path for GUI is wrong --- __init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/__init__.py b/__init__.py index 7ef96d9..3bbedb7 100644 --- a/__init__.py +++ b/__init__.py @@ -124,7 +124,7 @@ def generate_map(self, lat, lon): m.bluemarble() x, y = m(lon, lat) - iss = plt.imread(self.settings.get("iss_icon", f"{self.root_dir}/ui/iss3.png")) + iss = plt.imread(self.settings.get("iss_icon", f"{self.root_dir}/gui/all/iss3.png")) im = OffsetImage(iss, zoom=self.settings["iss_size"]) ab = AnnotationBbox(im, (x, y), xycoords='data', frameon=False)