Add recenter and improve help

This commit is contained in:
Andreas Fabri 2010-09-23 14:42:13 +00:00
parent dae71df61b
commit 93712c46cd
1 changed files with 5 additions and 2 deletions

View File

@ -204,8 +204,11 @@ MainWindow::on_actionClear_triggered()
void
MainWindow::on_actionRecenter_triggered()
{
// this->graphicsView->setSceneRect(convert(square));
// this->graphicsView->fitInView(convert(square), Qt::KeepAspectRatio);
if(tree.empty()){
return;
}
this->graphicsView->setSceneRect(pgi->boundingRect());
this->graphicsView->fitInView(pgi->boundingRect(), Qt::KeepAspectRatio);
}
void