From 425e32bd9d27aa0977fb8b8a21fe89ae7a1d56fc Mon Sep 17 00:00:00 2001 From: pixhawk Date: Tue, 8 Jun 2010 07:47:54 +0200 Subject: [PATCH] Working on text in HSI display --- src/ui/HSIDisplay.cc | 8 +++++++- src/ui/HSIDisplay.h | 1 + 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/ui/HSIDisplay.cc b/src/ui/HSIDisplay.cc index eb4ba2d1c..f9de37cc9 100644 --- a/src/ui/HSIDisplay.cc +++ b/src/ui/HSIDisplay.cc @@ -40,7 +40,8 @@ This file is part of the PIXHAWK project HSIDisplay::HSIDisplay(QWidget *parent) : HDDisplay(NULL, parent), - gpsSatellites() + gpsSatellites(), + satellitesUsed(0) { } @@ -174,6 +175,11 @@ void HSIDisplay::drawGPS() const float margin = 0.2f; // 20% margin of total width on each side float radius = (vwidth - vwidth * 2.0f * margin) / 2.0f; + // Draw satellite labels + // QString label; + // label.sprintf("%05.1f", value); + // paintText(label, color, 4.5f, xRef-7.5f, yRef-2.0f, painter); + for (int i = 0; i < gpsSatellites.size(); i++) { GPSSatellite* sat = gpsSatellites.at(i); diff --git a/src/ui/HSIDisplay.h b/src/ui/HSIDisplay.h index 838013dae..5a728fe4e 100644 --- a/src/ui/HSIDisplay.h +++ b/src/ui/HSIDisplay.h @@ -97,6 +97,7 @@ protected: }; QVector gpsSatellites; + unsigned int satellitesUsed; private: }; -- 2.22.0