From 32a41b1abe1a4aab0892c9c2051be6ba5b379f1e Mon Sep 17 00:00:00 2001 From: Christoph Berg Date: Mon, 11 May 2020 22:17:58 +0200 Subject: New upstream version 2.2.0~rc1+repack --- widgets/fastplot.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'widgets/fastplot.cpp') diff --git a/widgets/fastplot.cpp b/widgets/fastplot.cpp index a388f0ac..b60f811d 100644 --- a/widgets/fastplot.cpp +++ b/widgets/fastplot.cpp @@ -58,7 +58,7 @@ void FPlotter::drawScale() //drawScale() QRect rect0; QPainter painter0(&m_ScalePixmap); - painter0.initFrom(this); + painter0.setBackground (palette ().brush (backgroundRole ())); //create Font to use for scales QFont Font("Arial"); @@ -155,7 +155,7 @@ void FPlotter::draw() //draw() int ih=m_UTCdisk/10000; int im=m_UTCdisk/100 % 100; int is=m_UTCdisk % 100; - m_t.sprintf("%2.2d:%2.2d:%2.2d",ih,im,is); + m_t = m_t.asprintf("%2.2d:%2.2d:%2.2d",ih,im,is); } int k0=m_jh0; @@ -168,7 +168,7 @@ void FPlotter::draw() //draw() int ih=m_UTCdisk/10000; int im=m_UTCdisk/100 % 100; int is=m_UTCdisk % 100; - m_t.sprintf("%2.2d:%2.2d:%2.2d",ih,im,is); + m_t = m_t.asprintf("%2.2d:%2.2d:%2.2d",ih,im,is); } else { m_t=QDateTime::currentDateTimeUtc().toString("hh:mm:ss"); } @@ -243,7 +243,7 @@ void FPlotter::mouseMoveEvent(QMouseEvent *event) // int y=event->y(); float t=x/m_pixPerSecond; QString t1; - t1.sprintf("%5.2f",t); + t1 = t1.asprintf("%5.2f",t); QRectF rect0(78,85,40,13); //### Should use font metrics ### painter.fillRect(rect0,Qt::black); painter.setPen(Qt::yellow); -- cgit v1.2.3