mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-13 16:18:42 +00:00
Blank texts break axes login in GenericPlot
.. for some reason in earlier version of Qt Charts there are errant items in the same area as the axes that are blank, these break the code that derives the axes rectangles in Qt Charts <= 5.10
This commit is contained in:
@@ -271,6 +271,9 @@ GenericPlot::plotAreaChanged()
|
||||
foreach(QGraphicsItem *item, qchart->scene()->items(zone, Qt::ItemSelectionMode::ContainsItemShape)) {
|
||||
if (item->type() != QGraphicsTextItem::Type) continue;
|
||||
|
||||
// for some reason 5.10 or earlier has errant text items we should ignore
|
||||
if (static_cast<QGraphicsTextItem*>(item)->toPlainText() == "") continue;
|
||||
|
||||
// is this an axis title?
|
||||
QAbstractAxis *found=NULL;
|
||||
foreach(QAbstractAxis *axis, qchart->axes()) {
|
||||
|
||||
Reference in New Issue
Block a user