summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMichal Klocek <michal.klocek@digia.com>2012-07-04 16:00:09 +0300
committerMichal Klocek <michal.klocek@digia.com>2012-07-04 16:00:42 +0300
commit8b084e770b030f2570db75bd4bc0597f4d9abc04 (patch)
treecfd76a1f9bc28ddd774fd1a9216f7dab195cf8a2 /src
parent35c35dbacb1e89643ad686291181f8833510d336 (diff)
Adds plotArea()
* fixes dynamic spline example
Diffstat (limited to 'src')
-rw-r--r--src/chartpresenter.cpp2
-rw-r--r--src/qchart.cpp5
-rw-r--r--src/qchart.h1
3 files changed, 7 insertions, 1 deletions
diff --git a/src/chartpresenter.cpp b/src/chartpresenter.cpp
index 7546087d..97b76f86 100644
--- a/src/chartpresenter.cpp
+++ b/src/chartpresenter.cpp
@@ -451,7 +451,7 @@ void ChartPresenter::setMarginsMinimum(const QRectF& margins)
QRectF ChartPresenter::margins() const
{
- return QRectF();//m_layout->margins();
+ return m_layout->margins();
}
QLegend* ChartPresenter::legend()
diff --git a/src/qchart.cpp b/src/qchart.cpp
index af9b1769..563db002 100644
--- a/src/qchart.cpp
+++ b/src/qchart.cpp
@@ -379,6 +379,11 @@ QRectF QChart::margins() const
return d_ptr->m_presenter->margins();
}
+QRectF QChart::plotArea() const
+{
+ return d_ptr->m_presenter->geometry();
+}
+
/*!
Sets animation \a options for the chart
*/
diff --git a/src/qchart.h b/src/qchart.h
index 0b89a235..62e936df 100644
--- a/src/qchart.h
+++ b/src/qchart.h
@@ -117,6 +117,7 @@ public:
void setMarginsMinimum(const QRectF& margins);
QRectF margins() const;
+ QRectF plotArea() const;
Q_SIGNALS:
void marginsChanged(QRectF newMargins);