Frontend to the famous GRBL.

loadeagleboarddialog.cpp 951B

    /* Part of x2grbl * * Copyright Johann Wilhelm <johann.wilhelm@9mal6.de> 2015 * * see Readme.md for detailed license and usage information! */ #include "loadeagleboarddialog.h" #include "ui_loadeagleboarddialog.h" LoadEagleBoardDialog::LoadEagleBoardDialog(EagleBrdParser *Parser, QWidget *parent) : QDialog(parent), ui(new Ui::LoadEagleBoardDialog) { ui->setupUi(this); ui->graphicsView->setScene(Parser->scene()); ui->tableView->setModel(Parser); ui->graphicsView->setTransform(QTransform::fromScale(1,-1)); ui->graphicsView->fitInView(ui->graphicsView->scene()->itemsBoundingRect()); } LoadEagleBoardDialog::~LoadEagleBoardDialog() { delete ui; } void LoadEagleBoardDialog::on_splitter_splitterMoved(int pos, int index) { ui->graphicsView->fitInView(ui->graphicsView->scene()->itemsBoundingRect(),Qt::KeepAspectRatio); } void LoadEagleBoardDialog::accept() { QDialog::accept(); }