]> git.rkrishnan.org Git - pihpsdr.git/commitdiff
vfo fix a bug in rendering the dot vs step size
authorRamakrishnan Muthukrishnan <ram@rkrishnan.org>
Sun, 20 Nov 2022 13:31:41 +0000 (19:01 +0530)
committerRamakrishnan Muthukrishnan <ram@rkrishnan.org>
Sun, 20 Nov 2022 13:31:41 +0000 (19:01 +0530)
vfo.c

diff --git a/vfo.c b/vfo.c
index 47d3bec361f692b9f0ecddfa4a125387757223df..bda80a4687de5d98808f239f5bef6a88ab10a4fc 100644 (file)
--- a/vfo.c
+++ b/vfo.c
@@ -1040,11 +1040,13 @@ void vfo_update() {
         cairo_show_text(cr, vfo_texts[0]);
         // show the step digit and the rest in grey
         // cairo_set_font_size(cr, 50);
-        cairo_set_source_rgb(cr, 0.0, 1.0, 1.0); // 0.75, 0.75, 0.75);
-        cairo_show_text(cr, ".");
-       cairo_set_source_rgb(cr, 0.75, 1.0, 1.0); // 0.75, 0.75);
+       cairo_set_source_rgb(cr, 1.0, 1.0, 1.0); // 0.75, 0.75);
         cairo_show_text(cr, vfo_texts[1]);
-       cairo_set_source_rgb(cr, 0.75, 1.0, 1.0); // 0.75, 0.75);
+        if (strlen(vfo_texts[2]) != 0) {
+            cairo_set_source_rgb(cr, 0.0, 1.0, 1.0); // 0.75, 0.75, 0.75);
+            cairo_show_text(cr, ".");
+        }
+        cairo_set_source_rgb(cr, 0.75, 1.0, 1.0); // 0.75, 0.75);
         cairo_show_text(cr, vfo_texts[2]);
 
         cairo_select_font_face(cr, "Cantarell",