##// END OF EJS Templates
Merge remote-tracking branch 'origin/5.6' into 5.7...
Merge remote-tracking branch 'origin/5.6' into 5.7 Conflicts: src/charts/charts.pro src/charts/qchartglobal.h src/chartsqml2/chartsqml2.pro tests/auto/chartdataset/tst_chartdataset.cpp tests/auto/domain/tst_domain.cpp Change-Id: I9bfc63f6e93f9a3b86e53aca218dd3a48bb2ffc1

File last commit:

r2878:97bb01ce5d85 merge
r2898:03a6177a3223 merge master
Show More
qlegend.h
125 lines | 4.2 KiB | text/x-c | CLexer
Miikka Heikkinen
Updated license...
r2854 /****************************************************************************
Jani Honkonen
Add license headers
r794 **
Miikka Heikkinen
Updated license...
r2854 ** Copyright (C) 2016 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
Jani Honkonen
Add license headers
r794 **
Miikka Heikkinen
Updated license...
r2854 ** This file is part of the Qt Charts module of the Qt Toolkit.
Jani Honkonen
Add license headers
r794 **
Miikka Heikkinen
Updated license...
r2854 ** $QT_BEGIN_LICENSE:GPL$
Titta Heikkala
Updated license headers...
r2845 ** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The Qt Company. For licensing terms
Miikka Heikkinen
Updated license...
r2854 ** and conditions see https://www.qt.io/terms-conditions. For further
** information use the contact form at https://www.qt.io/contact-us.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
** General Public License version 3 or (at your option) any later version
** approved by the KDE Free Qt Foundation. The licenses are as published by
** the Free Software Foundation and appearing in the file LICENSE.GPL3
** included in the packaging of this file. Please review the following
** information to ensure the GNU General Public License requirements will
** be met: https://www.gnu.org/licenses/gpl-3.0.html.
Jani Honkonen
Add license headers
r794 **
Titta Heikkala
Updated license headers...
r2845 ** $QT_END_LICENSE$
**
Miikka Heikkinen
Updated license...
r2854 ****************************************************************************/
Jani Honkonen
Add license headers
r794
sauimone
framework for legend
r524 #ifndef QLEGEND_H
#define QLEGEND_H
Titta Heikkala
Fix include syntax...
r2714 #include <QtCharts/QChartGlobal>
#include <QtWidgets/QGraphicsWidget>
#include <QtGui/QPen>
#include <QtGui/QBrush>
sauimone
framework for legend
r524
Titta Heikkala
Qt Charts project file structure change...
r2712 QT_CHARTS_BEGIN_NAMESPACE
sauimone
framework for legend
r524
Michal Klocek
Fix attempt to wrong graphics items hadnling
r790 class QChart;
Michal Klocek
Adds qlegend pimpl...
r950 class QLegendPrivate;
sauimone
first prototry of QLegendMarker API
r2160 class QLegendMarker;
sauimone
refactoring
r2167 class QAbstractSeries;
sauimone
framework for legend
r524
Titta Heikkala
Qt Charts project file structure change...
r2712 class QT_CHARTS_EXPORT QLegend : public QGraphicsWidget
sauimone
framework for legend
r524 {
Q_OBJECT
Tero Ahola
color and borderColor properties to XY charts; removed unnecessary signals
r1481 Q_PROPERTY(Qt::Alignment alignment READ alignment WRITE setAlignment)
Tero Ahola
Adding legend properties
r1452 Q_PROPERTY(bool backgroundVisible READ isBackgroundVisible WRITE setBackgroundVisible NOTIFY backgroundVisibleChanged)
Q_PROPERTY(QColor color READ color WRITE setColor NOTIFY colorChanged)
Q_PROPERTY(QColor borderColor READ borderColor WRITE setBorderColor NOTIFY borderColorChanged)
sauimone
legend font fix
r1522 Q_PROPERTY(QFont font READ font WRITE setFont NOTIFY fontChanged)
sauimone
legend theme fix
r1527 Q_PROPERTY(QColor labelColor READ labelColor WRITE setLabelColor NOTIFY labelColorChanged)
Titta Heikkala
Add possibility to set markers in legend in reverse order...
r2676 Q_PROPERTY(bool reverseMarkers READ reverseMarkers WRITE setReverseMarkers NOTIFY reverseMarkersChanged)
Andy Shaw
Add support for showing tooltips when the legend text is truncated...
r2864 Q_PROPERTY(bool showToolTips READ showToolTips WRITE setShowToolTips NOTIFY showToolTipsChanged)
sauimone
legend pos to theme example, legend padding
r803
Michal Klocek
Fix attempt to wrong graphics items hadnling
r790 private:
explicit QLegend(QChart *chart);
sauimone
legend layouting change
r616
Michal Klocek
Fix attempt to wrong graphics items hadnling
r790 public:
Michal Klocek
Adds qlegend pimpl...
r950 ~QLegend();
Marc Mutz
Make public headers compile with -Wzero-as-null-pointer-constant...
r2871 void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = Q_NULLPTR);
sauimone
framework for legend
r524
Tero Ahola
Code review: Fixed simple issues in Bar and Legend
r737 void setBrush(const QBrush &brush);
Michal Klocek
Adds force option to chartTheme...
r645 QBrush brush() const;
Tero Ahola
Adding legend properties
r1452 void setColor(QColor color);
QColor color();
Michal Klocek
Adds force option to chartTheme...
r645
Tero Ahola
Code review: Fixed simple issues in Bar and Legend
r737 void setPen(const QPen &pen);
Michal Klocek
Adds force option to chartTheme...
r645 QPen pen() const;
Tero Ahola
Adding legend properties
r1452 void setBorderColor(QColor color);
QColor borderColor();
sauimone
background to legend, theme applies
r540
sauimone
legend font fix
r1522 void setFont(const QFont &font);
QFont font() const;
sauimone
legend theme fix
r1527 void setLabelBrush(const QBrush &brush);
QBrush labelBrush() const;
void setLabelColor(QColor color);
QColor labelColor() const;
sauimone
legend font fix
r1522
Tero Ahola
Qml ChartView properties; legend to use Qt alignments
r1357 void setAlignment(Qt::Alignment alignment);
Qt::Alignment alignment() const;
sauimone
legend layouting change
r616
sauimone
legend layout with padding
r799 void detachFromChart();
void attachToChart();
Michal Klocek
Refactor qledgend handling...
r855 bool isAttachedToChart();
sauimone
changed legend default visibility
r882 void setBackgroundVisible(bool visible = true);
Michal Klocek
Refactor qledgend handling...
r855 bool isBackgroundVisible() const;
Marc Mutz
Make public headers compile with -Wzero-as-null-pointer-constant...
r2871 QList <QLegendMarker*> markers(QAbstractSeries *series = Q_NULLPTR) const;
sauimone
first prototry of QLegendMarker API
r2160
Titta Heikkala
Add possibility to set markers in legend in reverse order...
r2676 bool reverseMarkers();
void setReverseMarkers(bool reverseMarkers = true);
Andy Shaw
Add support for showing tooltips when the legend text is truncated...
r2864 bool showToolTips() const;
void setShowToolTips(bool show);
Michal Klocek
Refactor qledgend handling...
r855 protected:
void hideEvent(QHideEvent *event);
void showEvent(QShowEvent *event);
sauimone
Separated legend marker to private header. Added signals for left and right mouse click
r547
Tero Ahola
Qml ChartView properties; legend to use Qt alignments
r1357 Q_SIGNALS:
Tero Ahola
Adding legend properties
r1452 void backgroundVisibleChanged(bool visible);
void colorChanged(QColor color);
void borderColorChanged(QColor color);
sauimone
legend font fix
r1522 void fontChanged(QFont font);
sauimone
legend theme fix
r1527 void labelColorChanged(QColor color);
Titta Heikkala
Add possibility to set markers in legend in reverse order...
r2676 void reverseMarkersChanged(bool reverseMarkers);
Andy Shaw
Add support for showing tooltips when the legend text is truncated...
r2864 void showToolTipsChanged(bool showToolTips);
Tero Ahola
Qml ChartView properties; legend to use Qt alignments
r1357
Michal Klocek
Refactor qledgend handling...
r855 private:
Michal Klocek
Adds qlegend pimpl...
r950 QScopedPointer<QLegendPrivate> d_ptr;
Tero Ahola
Adding legend properties
r1452 Q_DISABLE_COPY(QLegend)
Michal Klocek
Adds qlegend pimpl...
r950 friend class LegendScroller;
Michal Klocek
Refactors layout managment...
r1534 friend class LegendLayout;
friend class ChartLayout;
sauimone
Legend can now handle clicked and do scrolling
r2183 friend class LegendMarkerItem;
sauimone
fix to QTRD-1674: layout is not calculated correctly after the change in the text of legend marker
r2194 friend class QLegendMarkerPrivate;
Michal Klocek
Adds ScrolledQLegend...
r859 };
Titta Heikkala
Qt Charts project file structure change...
r2712 QT_CHARTS_END_NAMESPACE
sauimone
framework for legend
r524
#endif // QLEGEND_H