Commit 50a34cae authored by lm's avatar lm

Adjusted to small screens

parent 297d2ac5
......@@ -25,7 +25,7 @@
<property name="windowTitle">
<string>Form</string>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_2">
<layout class="QHBoxLayout" name="horizontalLayout_2" stretch="10,20">
<property name="spacing">
<number>3</number>
</property>
......@@ -51,8 +51,14 @@
</property>
<property name="minimumSize">
<size>
<width>250</width>
<height>300</height>
<width>90</width>
<height>200</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>370</width>
<height>16777215</height>
</size>
</property>
<property name="title">
......@@ -71,21 +77,21 @@
<item>
<widget class="QScrollArea" name="curveListWidget">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Expanding">
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>240</width>
<height>250</height>
<width>60</width>
<height>150</height>
</size>
</property>
<property name="baseSize">
<size>
<width>150</width>
<height>200</height>
<width>60</width>
<height>150</height>
</size>
</property>
<property name="autoFillBackground">
......@@ -108,7 +114,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>242</width>
<width>210</width>
<height>361</height>
</rect>
</property>
......@@ -122,14 +128,14 @@
<widget class="QGroupBox" name="diagramGroupBox">
<property name="sizePolicy">
<sizepolicy hsizetype="MinimumExpanding" vsizetype="MinimumExpanding">
<horstretch>9</horstretch>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>400</width>
<height>300</height>
<width>200</width>
<height>200</height>
</size>
</property>
<property name="baseSize">
......
......@@ -216,6 +216,19 @@ MainWindow::~MainWindow()
}
void MainWindow::resizeEvent(QResizeEvent * event)
{
Q_UNUSED(event);
if (height() < 800)
{
ui.statusBar->setVisible(false);
}
else
{
ui.statusBar->setVisible(true);
}
}
QString MainWindow::getWindowStateKey()
{
return QString::number(currentView)+"/windowstate";
......
......@@ -297,6 +297,8 @@ protected:
*/
void showTheCentralWidget (TOOLS_WIDGET_NAMES centralWidget, VIEW_SECTIONS view);
/** @brief Catch window resize events */
void resizeEvent(QResizeEvent * event);
/** @brief Keeps track of the current view */
VIEW_SECTIONS currentView;
......
......@@ -199,7 +199,7 @@ void LinechartWidget::createLayout()
layout->addWidget(activePlot, 0, 0, 1, 6);
layout->setRowStretch(0, 10);
layout->setRowStretch(1, 0);
layout->setRowStretch(1, 1);
// Linear scaling button
scalingLinearButton = createButton(this);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment