Sync repository
[mardrone] / mardrone / gauges / gaugehorizon.h
index 74a9102..66d3251 100644 (file)
@@ -8,6 +8,8 @@ class GaugeHorizon : public Gauge
     Q_PROPERTY(QColor horizonGroundColor READ getHorizonGroundColor WRITE setHorizonGroundColor)
     Q_PROPERTY(QColor horizonSkyColor READ getHorizonSkyColor WRITE setHorizonSkyColor)
     Q_PROPERTY(QColor horizonLineColor READ getHorizonLineColor WRITE setHorizonLineColor)
+    Q_PROPERTY(int   yPosition READ yPosition WRITE setYPosition)
+
 public:
     explicit GaugeHorizon(QGraphicsItem *parent = 0);
     void paint(QPainter *painter,const QStyleOptionGraphicsItem *option,
@@ -19,10 +21,12 @@ public:
     QColor getHorizonLineColor() {return m_horizonLineColor;};
     void setHorizonGroundColor(QColor val_) { m_horizonGroundColor=val_;};
     QColor getHorizonGroundColor() {return m_horizonGroundColor;};
+    void setYPosition(int y) { m_ypos=y;} int yPosition(){ return m_ypos;};
 private:
     QColor m_horizonLineColor;
     QColor m_horizonSkyColor;
     QColor m_horizonGroundColor;
+    int m_ypos;
     QVector<QLine>  fixo;
     QPolygon plane,planel,planer;
     QPolygon zeroTriangle;