mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Started the code for the Profile Plotting
This small patch adds a new class - ProfileGraphicsView it's a QGraphicsView based class that will holds all graphics-items for the plotting. The setup is simple, just call ui->ListView->plot( dive ) ( that's already a ProfileGraphicsView and magic will happen. Since Im using a QGraphicsView , the size of the canvas doesn't matter and I'm fixing it at 0,0,100,100. when a resize is done, the resizeEvent will be called, fitting the scene's rectangle on the view. Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
fcd6903621
commit
8353d57164
5 changed files with 53 additions and 3 deletions
|
@ -67,7 +67,6 @@ void MainWindow::on_actionOpen_triggered()
|
|||
g_error_free(error);
|
||||
error = NULL;
|
||||
}
|
||||
|
||||
process_dives(FALSE, FALSE);
|
||||
|
||||
ui->InfoWidget->reload();
|
||||
|
@ -94,6 +93,7 @@ void MainWindow::dive_selection_changed(const QItemSelection& newSelection, cons
|
|||
continue;
|
||||
select_dive(get_divenr(d));
|
||||
}
|
||||
ui->ProfileWidget->plot(get_dive(selected_dive));
|
||||
}
|
||||
|
||||
void MainWindow::on_actionSave_triggered()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue