Created new Layout prototype.

This commit is contained in:
2025-12-26 12:04:02 +01:00
parent 0bec8dfeb7
commit 3ff995d547
5 changed files with 191 additions and 94 deletions

View File

@@ -14,45 +14,113 @@
<string>BCMainWindow</string>
</property>
<widget class="QWidget" name="_centralwidget">
<layout class="QVBoxLayout" name="verticalLayout">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QFrame" name="_controlFrame">
<property name="minimumSize">
<size>
<width>200</width>
<height>0</height>
</size>
</property>
<property name="frameShape">
<enum>QFrame::Shape::StyledPanel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Shadow::Raised</enum>
</property>
<widget class="QPushButton" name="_syncButton">
<property name="geometry">
<rect>
<x>30</x>
<y>50</y>
<width>171</width>
<height>51</height>
</rect>
</property>
<property name="text">
<string>Sync</string>
<widget class="QWidget" name="_buttonWidget" native="true">
<property name="styleSheet">
<string notr="true">background-color: grey;</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QWidget" name="widget" native="true">
<property name="styleSheet">
<string notr="true">background-color: #aaaaaa;</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="BCToolButton" name="_pimpButton">
<property name="minimumSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
<property name="text">
<string>...</string>
</property>
<property name="iconSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
</widget>
</item>
<item>
<widget class="BCToolButton" name="_batteryButton">
<property name="minimumSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
<property name="text">
<string>...</string>
</property>
<property name="iconSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
</widget>
</item>
<item>
<widget class="BCToolButton" name="_motorButton">
<property name="minimumSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
<property name="text">
<string>...</string>
</property>
<property name="iconSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
</widget>
</item>
<item>
<widget class="BCToolButton" name="_consoleButton">
<property name="minimumSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
<property name="text">
<string>...</string>
</property>
<property name="iconSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QPushButton" name="_connectButton">
<property name="geometry">
<rect>
<x>10</x>
<y>180</y>
<width>171</width>
<height>51</height>
</rect>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Orientation::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>227</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="_connectButton">
<property name="text">
<string>Connect</string>
</property>
@@ -60,58 +128,38 @@
<bool>true</bool>
</property>
</widget>
<widget class="QToolButton" name="_motorlButton">
<property name="geometry">
<rect>
<x>70</x>
<y>240</y>
<width>71</width>
<height>71</height>
</rect>
</property>
</item>
<item>
<widget class="QPushButton" name="_syncButton">
<property name="text">
<string>...</string>
</property>
<property name="iconSize">
<size>
<width>64</width>
<height>64</height>
</size>
</property>
<property name="autoRaise">
<bool>true</bool>
<string>Sync</string>
</property>
</widget>
</widget>
</item>
<item>
<widget class="QTableView" name="_valueView">
<property name="frameShape">
<enum>QFrame::Shape::NoFrame</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Shadow::Plain</enum>
</property>
<property name="alternatingRowColors">
<bool>false</bool>
</property>
<property name="showGrid">
<bool>false</bool>
</property>
<property name="gridStyle">
<enum>Qt::PenStyle::NoPen</enum>
</property>
<attribute name="horizontalHeaderStretchLastSection">
<bool>true</bool>
</attribute>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QStackedWidget" name="_controlWidget">
<property name="minimumSize">
<size>
<width>200</width>
<height>0</height>
</size>
</property>
<property name="currentIndex">
<number>3</number>
</property>
<widget class="BCDevicePanel" name="_consolePanel"/>
<widget class="BCDevicePanel" name="_motorPanel"/>
<widget class="BCDevicePanel" name="_batteryPanel"/>
<widget class="BCDevicePanel" name="_pimpPanel"/>
</widget>
</item>
</layout>
</widget>
<widget class="QStatusBar" name="_statusbar"/>
<action name="_actionPimp">
<action name="_pimpAction">
<property name="icon">
<iconset>
<normaloff>:restart.png</normaloff>:restart.png</iconset>
@@ -123,7 +171,7 @@
<string>Pimp my Ride</string>
</property>
</action>
<action name="_actionMotor">
<action name="_motorAction">
<property name="icon">
<iconset>
<normaloff>:bionx_motor.png</normaloff>:bionx_motor.png</iconset>
@@ -135,7 +183,7 @@
<string>Show motor settings</string>
</property>
</action>
<action name="_actionBattery">
<action name="_batteryAction">
<property name="icon">
<iconset>
<normaloff>:bionx_akku.png</normaloff>:bionx_akku.png</iconset>
@@ -147,7 +195,7 @@
<string>Show battery settings</string>
</property>
</action>
<action name="_actionConsole">
<action name="_consoleAction">
<property name="icon">
<iconset>
<normaloff>:bionx_console.png</normaloff>:bionx_console.png</iconset>
@@ -159,7 +207,7 @@
<string>Show console settings</string>
</property>
</action>
<action name="_actionExit">
<action name="_exitAction">
<property name="icon">
<iconset>
<normaloff>:exit.png</normaloff>:exit.png</iconset>
@@ -171,7 +219,7 @@
<string>Exit</string>
</property>
</action>
<action name="_actionConnect">
<action name="_connectAction">
<property name="icon">
<iconset resource="bionxcontrol.qrc">
<normaloff>:/connected.png</normaloff>:/connected.png</iconset>
@@ -187,6 +235,19 @@
</property>
</action>
</widget>
<customwidgets>
<customwidget>
<class>BCDevicePanel</class>
<extends>QWidget</extends>
<header location="global">bcdevicepanel.h</header>
<container>1</container>
</customwidget>
<customwidget>
<class>BCToolButton</class>
<extends>QToolButton</extends>
<header location="global">bctoolbutton.h</header>
</customwidget>
</customwidgets>
<resources>
<include location="bionxcontrol.qrc"/>
</resources>