mirror of
https://github.com/dashpay/dash.git
synced 2024-12-26 04:22:55 +01:00
merge bitcoin#16153: Add antialiasing to traffic graph widget
This commit is contained in:
parent
a9997c778e
commit
6f98a32403
@ -125,6 +125,7 @@ void TrafficGraphWidget::paintEvent(QPaintEvent *)
|
|||||||
const TrafficGraphData::SampleQueue& queue = trafficGraphData.getCurrentRangeQueueWithAverageBandwidth();
|
const TrafficGraphData::SampleQueue& queue = trafficGraphData.getCurrentRangeQueueWithAverageBandwidth();
|
||||||
|
|
||||||
if(!queue.empty()) {
|
if(!queue.empty()) {
|
||||||
|
painter.setRenderHint(QPainter::Antialiasing);
|
||||||
QPainterPath pIn;
|
QPainterPath pIn;
|
||||||
QColor lucentGreen = green;
|
QColor lucentGreen = green;
|
||||||
lucentGreen.setAlpha(128);
|
lucentGreen.setAlpha(128);
|
||||||
@ -142,6 +143,7 @@ void TrafficGraphWidget::paintEvent(QPaintEvent *)
|
|||||||
painter.fillPath(pOut, lucentRed);
|
painter.fillPath(pOut, lucentRed);
|
||||||
painter.setPen(red);
|
painter.setPen(red);
|
||||||
painter.drawPath(pOut);
|
painter.drawPath(pOut);
|
||||||
|
painter.setRenderHint(QPainter::Antialiasing, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
// draw text
|
// draw text
|
||||||
|
Loading…
Reference in New Issue
Block a user