Sheet: Disable zooming

With PR 16130 the zooming capability was added to spreadsheet view.

The SheetTableView is added to a QGraphicsScene of a QGraphicsView
that provides the method scale(). However, this causes some problems
with header of the table view and makes resizing columns or rows
very unintuitive.

A correctly working table view is probably more important than the
possibility to zoom in or out and that's why the latter will be
disabled.

This fixes issue 19863
This commit is contained in:
wmayer
2025-03-05 16:06:32 +01:00
committed by Ladislav Michl
parent 1f11be1059
commit 4d123e8ae9
2 changed files with 8 additions and 1 deletions

View File

@@ -37,6 +37,7 @@ DlgSettingsImp::DlgSettingsImp(QWidget* parent)
, ui(new Ui_DlgSettings)
{
ui->setupUi(this);
ui->dZLSpinBox->setDisabled(true);
}
/**

View File

@@ -74,9 +74,15 @@ SheetView::SheetView(Gui::Document* pcDocument, App::DocumentObject* docObj, QWi
ui = new Ui::Sheet();
QWidget* w = new QWidget(this);
ui->setupUi(w);
ui->zoomMinus->hide();
ui->zoomPlus->hide();
ui->zoomSlider->hide();
ui->zoomTB->hide();
ui->realSB_h->hide();
ui->realSB_v->hide();
setCentralWidget(w);
new ZoomableView(ui);
// new ZoomableView(ui);
delegate = new SpreadsheetDelegate(sheet);
ui->cells->setModel(model);