Fix #566 by allowing for DeckName/Comments to be resized to the max, and even hidden! (#4157)

This commit is contained in:
Zach H 2020-11-13 15:36:20 -05:00 committed by GitHub
parent 68074b0f74
commit 0966a8e90f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -26,8 +26,6 @@
#include <QDir> #include <QDir>
#include <QDockWidget> #include <QDockWidget>
#include <QFileDialog> #include <QFileDialog>
#include <QGroupBox>
#include <QHBoxLayout>
#include <QHeaderView> #include <QHeaderView>
#include <QLabel> #include <QLabel>
#include <QLineEdit> #include <QLineEdit>
@ -89,6 +87,7 @@ void TabDeckEditor::createDeckDock()
commentsLabel = new QLabel(); commentsLabel = new QLabel();
commentsLabel->setObjectName("commentsLabel"); commentsLabel->setObjectName("commentsLabel");
commentsEdit = new QTextEdit; commentsEdit = new QTextEdit;
commentsEdit->setMinimumHeight(nameEdit->minimumSizeHint().height());
commentsEdit->setObjectName("commentsEdit"); commentsEdit->setObjectName("commentsEdit");
commentsLabel->setBuddy(commentsEdit); commentsLabel->setBuddy(commentsEdit);
connect(commentsEdit, SIGNAL(textChanged()), this, SLOT(updateComments())); connect(commentsEdit, SIGNAL(textChanged()), this, SLOT(updateComments()));
@ -147,7 +146,7 @@ void TabDeckEditor::createDeckDock()
auto *split = new QSplitter; auto *split = new QSplitter;
split->setObjectName("deckSplitter"); split->setObjectName("deckSplitter");
split->setOrientation(Qt::Vertical); split->setOrientation(Qt::Vertical);
split->setChildrenCollapsible(false); split->setChildrenCollapsible(true);
split->addWidget(topWidget); split->addWidget(topWidget);
split->addWidget(bottomWidget); split->addWidget(bottomWidget);
split->setStretchFactor(0, 1); split->setStretchFactor(0, 1);