diff --git a/MainWindow.cpp b/MainWindow.cpp index 472a315..b6c3d74 100644 --- a/MainWindow.cpp +++ b/MainWindow.cpp @@ -263,6 +263,7 @@ void MainWindow::createLayout() sourceList = new QListWidget; sourceList->setSelectionMode(QAbstractItemView::SingleSelection); sourceList->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Preferred); + sourceList->setMinimumWidth(SOURCE_LIST_MINIMUM_WIDTH); layerList = new QListWidget; layerList->setSelectionMode(QAbstractItemView::SingleSelection); @@ -270,9 +271,11 @@ void MainWindow::createLayout() //layerList->setDragDropMode(QAbstractItemView::DragDrop); layerList->setDefaultDropAction(Qt::MoveAction); layerList->setDragDropMode(QAbstractItemView::InternalMove); + layerList->setMinimumWidth(LAYER_LIST_MINIMUM_WIDTH); propertyPanel = new QStackedWidget; propertyPanel->setDisabled(true); + propertyPanel->setMinimumWidth(PROPERTY_PANEL_MINIMUM_WIDTH); sourceCanvas = new SourceGLCanvas; destinationCanvas = new DestinationGLCanvas(0, sourceCanvas); diff --git a/MainWindow.h b/MainWindow.h index 9f18ea5..184f680 100644 --- a/MainWindow.h +++ b/MainWindow.h @@ -177,6 +177,9 @@ public: static const int DEFAULT_HEIGHT = 800; static const int SOURCE_LIST_ITEM_HEIGHT = 40; static const int SHAPE_LIST_ITEM_HEIGHT = 40; + static const int SOURCE_LIST_MINIMUM_WIDTH = 100; + static const int LAYER_LIST_MINIMUM_WIDTH = 300; + static const int PROPERTY_PANEL_MINIMUM_WIDTH = 400; static const int CANVAS_MINIMUM_WIDTH = 480; static const int CANVAS_MINIMUM_HEIGHT = 270; };