mirror of
https://github.com/f4exb/sdrangel.git
synced 2025-05-24 03:02:29 -04:00
Fix Mac compilation error
This commit is contained in:
parent
f7ed662238
commit
e247fbb4fa
@ -15,6 +15,8 @@
|
|||||||
// along with this program. If not, see <http://www.gnu.org/licenses/>. //
|
// along with this program. If not, see <http://www.gnu.org/licenses/>. //
|
||||||
///////////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
#include <cmath>
|
||||||
|
|
||||||
#include <QPainter>
|
#include <QPainter>
|
||||||
|
|
||||||
#include "coursedeviationindicator.h"
|
#include "coursedeviationindicator.h"
|
||||||
@ -46,6 +48,8 @@ void CourseDeviationIndicator::setGlideSlopeDDM(float ddm)
|
|||||||
|
|
||||||
void CourseDeviationIndicator::paintEvent(QPaintEvent *event)
|
void CourseDeviationIndicator::paintEvent(QPaintEvent *event)
|
||||||
{
|
{
|
||||||
|
(void) event;
|
||||||
|
|
||||||
QPainter painter(this);
|
QPainter painter(this);
|
||||||
|
|
||||||
QRect r = rect();
|
QRect r = rect();
|
||||||
@ -168,7 +172,6 @@ void CourseDeviationIndicator::paintEvent(QPaintEvent *event)
|
|||||||
{
|
{
|
||||||
QFontMetrics fm(painter.font());
|
QFontMetrics fm(painter.font());
|
||||||
QString text = "G/S";
|
QString text = "G/S";
|
||||||
int tw = fm.horizontalAdvance(text);
|
|
||||||
int th = fm.ascent() / 2;
|
int th = fm.ascent() / 2;
|
||||||
painter.setPen(QColor(0, 255, 0));
|
painter.setPen(QColor(0, 255, 0));
|
||||||
painter.drawText(midW + bgw + 2, midH + th, text);
|
painter.drawText(midW + bgw + 2, midH + th, text);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user