MCPcopy Create free account
hub / github.com/KDE/labplot / setScalePixmap

Method setScalePixmap

src/frontend/widgets/DatapickerImageWidget.cpp:52–59  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

50}
51
52void HistogramView::setScalePixmap(const QString& file) {
53 // scene rect is 1000*100 where upper 1000*80 is for histogram graph
54 // and lower 1000*20 is for histogram scale
55 auto* pixmap = new QGraphicsPixmapItem(QPixmap(file).scaled(1000, 20, Qt::IgnoreAspectRatio), nullptr);
56 pixmap->setZValue(-1);
57 pixmap->setPos(0, 90);
58 m_scene->addItem(pixmap);
59}
60
61void HistogramView::setSpan(int l, int h) {
62 l = l * 1000 / m_range;

Callers 1

DatapickerImageWidgetMethod · 0.80

Calls 2

QPixmapClass · 0.50
setZValueMethod · 0.45

Tested by

no test coverage detected