- fix: when messages panel is docked at right, its width not correctly restored when restart.
This commit is contained in:
parent
2f0a7a3d89
commit
5c2c2bead2
1
NEWS.md
1
NEWS.md
|
@ -9,6 +9,7 @@ Red Panda C++ Version 1.1.1
|
||||||
- fix: when open in shell, add current compiler set's bin folders to path
|
- fix: when open in shell, add current compiler set's bin folders to path
|
||||||
- fix: when debug the executable using gdb server, add current compiler set's bin folders to path
|
- fix: when debug the executable using gdb server, add current compiler set's bin folders to path
|
||||||
- fix: reduce height of the message panel when dragging from right to bottom
|
- fix: reduce height of the message panel when dragging from right to bottom
|
||||||
|
- fix: when messages panel is docked at right, its width not correctly restored when restart.
|
||||||
|
|
||||||
Red Panda C++ Version 1.1.0
|
Red Panda C++ Version 1.1.0
|
||||||
- enhancement: when ctrl+mouse cursor hovered an identifier or header name, use underline to highlight it
|
- enhancement: when ctrl+mouse cursor hovered an identifier or header name, use underline to highlight it
|
||||||
|
|
|
@ -108,8 +108,6 @@ private:
|
||||||
QMap<QString,PCompilerInfo> mInfos;
|
QMap<QString,PCompilerInfo> mInfos;
|
||||||
};
|
};
|
||||||
|
|
||||||
extern PCompilerInfoManager pCompilerInfoManager;
|
|
||||||
|
|
||||||
class ClangCompilerInfo: public CompilerInfo{
|
class ClangCompilerInfo: public CompilerInfo{
|
||||||
public:
|
public:
|
||||||
ClangCompilerInfo();
|
ClangCompilerInfo();
|
||||||
|
|
|
@ -6266,19 +6266,24 @@ static void setSplitterInDockLocation(QSplitter* splitter, const Qt::DockWidgetA
|
||||||
}
|
}
|
||||||
void MainWindow::setDockExplorerToArea(const Qt::DockWidgetArea &area)
|
void MainWindow::setDockExplorerToArea(const Qt::DockWidgetArea &area)
|
||||||
{
|
{
|
||||||
if (area==Qt::DockWidgetArea::NoDockWidgetArea)
|
|
||||||
return;
|
|
||||||
setDockTitlebarLocation(ui->dockExplorer,area);
|
|
||||||
setTabsInDockLocation(ui->tabExplorer,area);
|
|
||||||
ui->dockMessages->setAllowedAreas(
|
ui->dockMessages->setAllowedAreas(
|
||||||
(Qt::DockWidgetArea::LeftDockWidgetArea |
|
(Qt::DockWidgetArea::LeftDockWidgetArea |
|
||||||
Qt::DockWidgetArea::BottomDockWidgetArea |
|
Qt::DockWidgetArea::BottomDockWidgetArea |
|
||||||
Qt::DockWidgetArea::RightDockWidgetArea)
|
Qt::DockWidgetArea::RightDockWidgetArea)
|
||||||
& ~area);
|
& ~area);
|
||||||
|
if (area==Qt::DockWidgetArea::NoDockWidgetArea)
|
||||||
|
return;
|
||||||
|
setDockTitlebarLocation(ui->dockExplorer,area);
|
||||||
|
setTabsInDockLocation(ui->tabExplorer,area);
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainWindow::setDockMessagesToArea(const Qt::DockWidgetArea &area)
|
void MainWindow::setDockMessagesToArea(const Qt::DockWidgetArea &area)
|
||||||
{
|
{
|
||||||
|
ui->dockExplorer->setAllowedAreas(
|
||||||
|
(Qt::DockWidgetArea::LeftDockWidgetArea |
|
||||||
|
Qt::DockWidgetArea::BottomDockWidgetArea |
|
||||||
|
Qt::DockWidgetArea::RightDockWidgetArea)
|
||||||
|
& ~area);
|
||||||
Qt::DockWidgetArea effectiveArea;
|
Qt::DockWidgetArea effectiveArea;
|
||||||
if (area==Qt::DockWidgetArea::NoDockWidgetArea) {
|
if (area==Qt::DockWidgetArea::NoDockWidgetArea) {
|
||||||
switch (mMessagesDockLocation) {
|
switch (mMessagesDockLocation) {
|
||||||
|
@ -6300,11 +6305,6 @@ void MainWindow::setDockMessagesToArea(const Qt::DockWidgetArea &area)
|
||||||
setTabsInDockLocation(ui->tabMessages,effectiveArea);
|
setTabsInDockLocation(ui->tabMessages,effectiveArea);
|
||||||
setSplitterInDockLocation(ui->splitterDebug,effectiveArea);
|
setSplitterInDockLocation(ui->splitterDebug,effectiveArea);
|
||||||
setSplitterInDockLocation(ui->splitterProblem,effectiveArea);
|
setSplitterInDockLocation(ui->splitterProblem,effectiveArea);
|
||||||
ui->dockExplorer->setAllowedAreas(
|
|
||||||
(Qt::DockWidgetArea::LeftDockWidgetArea |
|
|
||||||
Qt::DockWidgetArea::BottomDockWidgetArea |
|
|
||||||
Qt::DockWidgetArea::RightDockWidgetArea)
|
|
||||||
& ~effectiveArea);
|
|
||||||
QGridLayout* layout=(QGridLayout*)ui->panelProblemCase->layout();
|
QGridLayout* layout=(QGridLayout*)ui->panelProblemCase->layout();
|
||||||
layout->removeWidget(ui->widgetProblemCaseInputCaption);
|
layout->removeWidget(ui->widgetProblemCaseInputCaption);
|
||||||
layout->removeWidget(ui->widgetProblemCaseOutputCaption);
|
layout->removeWidget(ui->widgetProblemCaseOutputCaption);
|
||||||
|
|
|
@ -463,7 +463,7 @@
|
||||||
<enum>QTabWidget::West</enum>
|
<enum>QTabWidget::West</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="currentIndex">
|
<property name="currentIndex">
|
||||||
<number>4</number>
|
<number>1</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="usesScrollButtons">
|
<property name="usesScrollButtons">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
|
@ -858,7 +858,7 @@
|
||||||
<enum>QTabWidget::South</enum>
|
<enum>QTabWidget::South</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="currentIndex">
|
<property name="currentIndex">
|
||||||
<number>6</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="iconSize">
|
<property name="iconSize">
|
||||||
<size>
|
<size>
|
||||||
|
@ -1003,16 +1003,16 @@
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout_2">
|
<layout class="QGridLayout" name="gridLayout_2">
|
||||||
<property name="leftMargin">
|
<property name="leftMargin">
|
||||||
<number>11</number>
|
<number>7</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="topMargin">
|
<property name="topMargin">
|
||||||
<number>11</number>
|
<number>7</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="rightMargin">
|
<property name="rightMargin">
|
||||||
<number>11</number>
|
<number>7</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="bottomMargin">
|
<property name="bottomMargin">
|
||||||
<number>11</number>
|
<number>7</number>
|
||||||
</property>
|
</property>
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
<widget class="QLabel" name="lblEvaluate">
|
<widget class="QLabel" name="lblEvaluate">
|
||||||
|
@ -1054,7 +1054,7 @@
|
||||||
<enum>QTabWidget::North</enum>
|
<enum>QTabWidget::North</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="currentIndex">
|
<property name="currentIndex">
|
||||||
<number>0</number>
|
<number>3</number>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QWidget" name="tabDebugConsole">
|
<widget class="QWidget" name="tabDebugConsole">
|
||||||
<attribute name="title">
|
<attribute name="title">
|
||||||
|
|
|
@ -2682,7 +2682,7 @@ void Settings::CompilerSets::saveSet(int index)
|
||||||
savePath("profiler", pSet->profiler());
|
savePath("profiler", pSet->profiler());
|
||||||
|
|
||||||
mSettings->mSettings.remove("Options");
|
mSettings->mSettings.remove("Options");
|
||||||
foreach(const PCompilerOption& option, pCompilerInfoManager->getCompilerOptions(pSet->compilerType())) {
|
foreach(const PCompilerOption& option, CompilerInfoManager::getInstance()->getCompilerOptions(pSet->compilerType())) {
|
||||||
mSettings->mSettings.remove(option->key);
|
mSettings->mSettings.remove(option->key);
|
||||||
}
|
}
|
||||||
// Save option string
|
// Save option string
|
||||||
|
|
|
@ -137,6 +137,8 @@ QSize ShrinkableTabWidget::minimumSizeHint() const
|
||||||
void ShrinkableTabWidget::resizeEvent(QResizeEvent *event)
|
void ShrinkableTabWidget::resizeEvent(QResizeEvent *event)
|
||||||
{
|
{
|
||||||
QTabWidget::resizeEvent(event);
|
QTabWidget::resizeEvent(event);
|
||||||
|
if (!isVisible())
|
||||||
|
return;
|
||||||
if (!isShrinked())
|
if (!isShrinked())
|
||||||
setBeforeShrinkSize(event->size());
|
setBeforeShrinkSize(event->size());
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue