mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Fix the rest of item visibilities and a few alignment fixes.
Every item is now back on the profile. Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
c05575e103
commit
cacf5b3b24
2 changed files with 19 additions and 12 deletions
|
@ -99,7 +99,6 @@ void DiveEventItem::setupToolTipString()
|
||||||
|
|
||||||
void DiveEventItem::eventVisibilityChanged(const QString& eventName, bool visible)
|
void DiveEventItem::eventVisibilityChanged(const QString& eventName, bool visible)
|
||||||
{
|
{
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void DiveEventItem::recalculatePos()
|
void DiveEventItem::recalculatePos()
|
||||||
|
|
|
@ -146,7 +146,7 @@ void ProfileWidget2::setupItemOnScene()
|
||||||
cartesianPlane->setBottomAxis(timeAxis);
|
cartesianPlane->setBottomAxis(timeAxis);
|
||||||
cartesianPlane->setLeftAxis(profileYAxis);
|
cartesianPlane->setLeftAxis(profileYAxis);
|
||||||
|
|
||||||
diveComputerText->setAlignment(Qt::AlignLeft | Qt::AlignTop);
|
diveComputerText->setAlignment(Qt::AlignRight | Qt::AlignTop);
|
||||||
diveComputerText->setBrush(getColor(TIME_TEXT));
|
diveComputerText->setBrush(getColor(TIME_TEXT));
|
||||||
|
|
||||||
setupItem(reportedCeiling, timeAxis, profileYAxis, dataModel, DivePlotDataModel::CEILING, DivePlotDataModel::TIME, 1);
|
setupItem(reportedCeiling, timeAxis, profileYAxis, dataModel, DivePlotDataModel::CEILING, DivePlotDataModel::TIME, 1);
|
||||||
|
@ -490,15 +490,23 @@ void ProfileWidget2::setProfileState()
|
||||||
|
|
||||||
cartesianPlane->setVisible(true);
|
cartesianPlane->setVisible(true);
|
||||||
meanDepth->setVisible(true);
|
meanDepth->setVisible(true);
|
||||||
|
|
||||||
diveComputerText->setVisible(true);
|
diveComputerText->setVisible(true);
|
||||||
cartesianPlane->setHorizontalLine( timeAxis->line() );
|
diveComputerText->setPos(itemPos.dcLabel.on);
|
||||||
cartesianPlane->setVerticalLine( profileYAxis->line() );
|
|
||||||
// diveCeiling->setVisible(true);
|
cartesianPlane->setHorizontalLine( itemPos.time.expanded );
|
||||||
// reportedCeiling->setVisible(true);
|
cartesianPlane->setVerticalLine( itemPos.depth.expanded );
|
||||||
// Q_FOREACH(DiveCalculatedTissue *tissue, allTissues){
|
|
||||||
// tissue->setVisible(true);
|
diveCeiling->setVisible(s.value("calcceiling").toBool());
|
||||||
// }
|
reportedCeiling->setVisible(s.value("dcceiling").toBool());
|
||||||
// Q_FOREACH(DiveEventItem *event, eventItems){
|
|
||||||
// event->setVisible(true);
|
if(s.value("calcalltissues").toBool()){
|
||||||
// }
|
Q_FOREACH(DiveCalculatedTissue *tissue, allTissues){
|
||||||
|
tissue->setVisible(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// Only set visible the ones that should be visible, but how?
|
||||||
|
Q_FOREACH(DiveEventItem *event, eventItems){
|
||||||
|
event->setVisible(true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue