##// END OF EJS Templates
renamed setRange to setCategoryRange in category axis.
sauimone -
r1576:89c5fcadff3e
parent child
Show More
@@ -74,6 +74,7 QVector<qreal> ChartCategoriesAxisX::calculateLayout() const
74 QVector<qreal> points;
74 QVector<qreal> points;
75 points.resize(m_ticksCount);
75 points.resize(m_ticksCount);
76
76
77 // TODO: shift logic
77 const qreal deltaX = m_rect.width()/(m_ticksCount-1);
78 const qreal deltaX = m_rect.width()/(m_ticksCount-1);
78 for (int i = 0; i < m_ticksCount; ++i) {
79 for (int i = 0; i < m_ticksCount; ++i) {
79 int x = i * deltaX + m_rect.left();
80 int x = i * deltaX + m_rect.left();
@@ -162,7 +162,7 QString QCategoriesAxis::maxCategory() const
162 /*!
162 /*!
163 Sets range from \a minCategory to \a maxCategory
163 Sets range from \a minCategory to \a maxCategory
164 */
164 */
165 void QCategoriesAxis::setRange(const QString& minCategory, const QString& maxCategory)
165 void QCategoriesAxis::setCategoryRange(const QString& minCategory, const QString& maxCategory)
166 {
166 {
167 Q_D(QCategoriesAxis);
167 Q_D(QCategoriesAxis);
168 d->setRangeCategory(minCategory,maxCategory);
168 d->setRangeCategory(minCategory,maxCategory);
@@ -57,7 +57,7 public:
57 QString minCategory() const;
57 QString minCategory() const;
58 void setMaxCategory(const QString& maxCategory);
58 void setMaxCategory(const QString& maxCategory);
59 QString maxCategory() const;
59 QString maxCategory() const;
60 void setRange(const QString& minCategory, const QString& maxCategory);
60 void setCategoryRange(const QString& minCategory, const QString& maxCategory);
61
61
62 Q_SIGNALS:
62 Q_SIGNALS:
63 void categoriesChanged();
63 void categoriesChanged();
General Comments 0
You need to be logged in to leave comments. Login now