@@ -10,9 +10,12 QChartWidget::QChartWidget(QWidget *parent) : | |||
|
10 | 10 | QGraphicsView(parent) |
|
11 | 11 | { |
|
12 | 12 | setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding); |
|
13 | m_scene = new QGraphicsScene(); | |
|
14 | setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff); | |
|
15 | setScene(m_scene); | |
|
13 | m_scene = new QGraphicsScene(); | |
|
14 | m_view = new QGraphicsView(parent); | |
|
15 | m_view->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff); | |
|
16 | m_view->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOff); | |
|
17 | m_view->setScene(m_scene); | |
|
18 | ||
|
16 | 19 | m_chart = new QChart(); |
|
17 | 20 | m_scene->addItem(m_chart); |
|
18 | 21 | show(); |
General Comments 0
You need to be logged in to leave comments.
Login now