From 902ae26b80cd53d7a2dfe6081f5ca7a62bdc3f17 Mon Sep 17 00:00:00 2001 From: XANTRONIX Industrial Date: Mon, 31 Mar 2025 15:30:48 -0400 Subject: [PATCH] Fix capitalization on map annotations --- bin/xmet-spc-render-file | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/bin/xmet-spc-render-file b/bin/xmet-spc-render-file index 9292215..d906c6a 100755 --- a/bin/xmet-spc-render-file +++ b/bin/xmet-spc-render-file @@ -58,7 +58,9 @@ def render_probabilistic(conus: SPCOutlookMap, if args.dark: cr.set_source_rgb(1, 1, 1) - conus.draw_annotation(cr, f"Day {outlook.day} Probabilistic {hazard.lower().capitalize()} Risk") + hazard = ' '.join(map(lambda p: p.lower().capitalize(), hazard.split(' '))) + + conus.draw_annotation(cr, f"Day {outlook.day} Probabilistic {hazard} Risk") argparser = argparse.ArgumentParser(description='Render graphical SPC outlooks from text file') argparser.add_argument('db', help='Spatialite database file')