Переверстал Главный виджет

This commit is contained in:
2025-09-08 17:11:47 +03:00
parent 86b268f13f
commit 120cf894ed
2 changed files with 339 additions and 318 deletions

View File

@@ -70,7 +70,7 @@ InstructorsAndTraineesWidget::InstructorsAndTraineesWidget(QWidget *parent) :
ui->groupBox_Instructors->setMinimumHeight(300); ui->groupBox_Instructors->setMinimumHeight(300);
ui->groupBox_Instructors->setMaximumHeight(300); ui->groupBox_Instructors->setMaximumHeight(300);
ui->groupBox_Trainees->setMinimumHeight(400); ui->groupBox_Trainees->setMinimumHeight(600);
ui->groupBox_Trainees->setMinimumWidth(800); ui->groupBox_Trainees->setMinimumWidth(800);
ui->groupBox_Instructors->setMinimumWidth(800); ui->groupBox_Instructors->setMinimumWidth(800);

View File

@@ -27,360 +27,260 @@
</property> </property>
<layout class="QGridLayout" name="gridLayout"> <layout class="QGridLayout" name="gridLayout">
<item row="0" column="0"> <item row="0" column="0">
<layout class="QHBoxLayout" name="horizontalLayout_Main"> <layout class="QVBoxLayout" name="verticalLayout_Main">
<item> <item>
<widget class="QWidget" name="widget_Control" native="true"> <layout class="QHBoxLayout" name="horizontalLayout_Main">
<property name="sizePolicy"> <item>
<sizepolicy hsizetype="Preferred" vsizetype="Preferred"> <widget class="QWidget" name="widget_Control" native="true">
<horstretch>0</horstretch> <property name="sizePolicy">
<verstretch>0</verstretch> <sizepolicy hsizetype="Preferred" vsizetype="Preferred">
</sizepolicy> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
<layout class="QGridLayout" name="gridLayout_6"> </sizepolicy>
<item row="1" column="0"> </property>
<layout class="QVBoxLayout" name="verticalLayout_Control"> <layout class="QGridLayout" name="gridLayout_6">
<item> <item row="1" column="0">
<widget class="QToolButton" name="btnConnectionToServer"> <layout class="QVBoxLayout" name="verticalLayout_Control">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>Connection</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/connectDB.png</normaloff>:/resources/icons/connectDB.png</iconset>
</property>
<property name="iconSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="checkable">
<bool>false</bool>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_ConnectedServer">
<item> <item>
<widget class="QLabel" name="lblDBisConnected"> <widget class="QToolButton" name="btnConnectionToServer">
<property name="minimumSize"> <property name="minimumSize">
<size> <size>
<width>32</width> <width>130</width>
<height>32</height> <height>58</height>
</size> </size>
</property> </property>
<property name="maximumSize"> <property name="text">
<string>Connection</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/connectDB.png</normaloff>:/resources/icons/connectDB.png</iconset>
</property>
<property name="iconSize">
<size> <size>
<width>32</width> <width>32</width>
<height>32</height> <height>32</height>
</size> </size>
</property> </property>
<property name="text"> <property name="checkable">
<string/>
</property>
<property name="pixmap">
<pixmap resource="resources.qrc">:/resources/icons/circleGray.png</pixmap>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="lblServerPrefix">
<property name="text">
<string>Server: </string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="lblServer">
<property name="text">
<string>none</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="QToolButton" name="btnAuthorizationInstructor">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>Authorization</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/login-user.png</normaloff>:/resources/icons/login-user.png</iconset>
</property>
<property name="iconSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="checkable">
<bool>true</bool>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_LoggedInInstructor">
<item>
<widget class="QLabel" name="lblLoggedIn">
<property name="minimumSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="resources.qrc">:/resources/icons/circleGray.png</pixmap>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="lblLoggedInPrefix">
<property name="maximumSize">
<size>
<width>16777215</width>
<height>40</height>
</size>
</property>
<property name="text">
<string> Instructor: </string>
</property>
<property name="textFormat">
<enum>Qt::AutoText</enum>
</property>
<property name="scaledContents">
<bool>false</bool> <bool>false</bool>
</property> </property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget> </widget>
</item> </item>
<item> <item>
<widget class="QLabel" name="lblLoggedInInstructor"> <widget class="QToolButton" name="btnAuthorizationInstructor">
<property name="maximumSize"> <property name="minimumSize">
<size> <size>
<width>16777215</width> <width>130</width>
<height>40</height> <height>58</height>
</size> </size>
</property> </property>
<property name="text"> <property name="text">
<string>none</string> <string>Authorization</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/login-user.png</normaloff>:/resources/icons/login-user.png</iconset>
</property>
<property name="iconSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="checkable">
<bool>true</bool>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="btnEditorTrainees">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>Editor Trainees</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/DB-trainees.png</normaloff>:/resources/icons/DB-trainees.png</iconset>
</property>
<property name="iconSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="btnEditorInstructors">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>Editor Instructors</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/DB-instructors.png</normaloff>:/resources/icons/DB-instructors.png</iconset>
</property>
<property name="iconSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QToolButton" name="btnSettings">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>Settings</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/settings.png</normaloff>:/resources/icons/settings.png</iconset>
</property>
<property name="iconSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="btnSetVersion">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>ChangeVersion</string>
</property> </property>
</widget> </widget>
</item> </item>
</layout> </layout>
</item> </item>
<item>
<widget class="QToolButton" name="btnEditorTrainees">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>Editor Trainees</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/DB-trainees.png</normaloff>:/resources/icons/DB-trainees.png</iconset>
</property>
<property name="iconSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="btnEditorInstructors">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>Editor Instructors</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/DB-instructors.png</normaloff>:/resources/icons/DB-instructors.png</iconset>
</property>
<property name="iconSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget>
</item>
<item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QToolButton" name="btnSettings">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>Settings</string>
</property>
<property name="icon">
<iconset resource="resources.qrc">
<normaloff>:/resources/icons/settings.png</normaloff>:/resources/icons/settings.png</iconset>
</property>
<property name="iconSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextUnderIcon</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="btnSetVersion">
<property name="minimumSize">
<size>
<width>130</width>
<height>58</height>
</size>
</property>
<property name="text">
<string>ChangeVersion</string>
</property>
</widget>
</item>
</layout> </layout>
</item> </widget>
</layout> </item>
</widget>
</item>
<item>
<layout class="QVBoxLayout" name="verticalLayout_Main">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_Bottom"> <layout class="QVBoxLayout" name="verticalLayout_Work">
<item> <item>
<layout class="QVBoxLayout" name="verticalLayout_L"> <layout class="QHBoxLayout" name="horizontalLayout_Work">
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout_L"> <layout class="QVBoxLayout" name="verticalLayout_L">
<item> <item>
<layout class="QVBoxLayout" name="verticalLayout_TI"> <layout class="QHBoxLayout" name="horizontalLayout_L">
<item> <item>
<widget class="QGroupBox" name="groupBox_Trainees"> <layout class="QVBoxLayout" name="verticalLayout_TI">
<property name="sizePolicy"> <item>
<sizepolicy hsizetype="Expanding" vsizetype="Expanding"> <widget class="QGroupBox" name="groupBox_Trainees">
<horstretch>0</horstretch> <property name="sizePolicy">
<verstretch>0</verstretch> <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
</sizepolicy> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
<property name="title"> </sizepolicy>
<string>Trainees</string> </property>
</property> <property name="title">
<layout class="QGridLayout" name="gridLayout_2"> <string>Trainees</string>
<item row="0" column="0"> </property>
<layout class="QVBoxLayout" name="verticalLayout_Trainees"/> <layout class="QGridLayout" name="gridLayout_2">
</item> <item row="0" column="0">
</layout> <layout class="QVBoxLayout" name="verticalLayout_Trainees"/>
</widget> </item>
</item> </layout>
<item> </widget>
<widget class="QGroupBox" name="groupBox_Instructors"> </item>
<property name="sizePolicy"> <item>
<sizepolicy hsizetype="Expanding" vsizetype="Expanding"> <widget class="QGroupBox" name="groupBox_Instructors">
<horstretch>0</horstretch> <property name="sizePolicy">
<verstretch>0</verstretch> <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
</sizepolicy> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
<property name="title"> </sizepolicy>
<string>Instructors</string> </property>
</property> <property name="title">
<layout class="QGridLayout" name="gridLayout_8"> <string>Instructors</string>
<item row="0" column="0"> </property>
<layout class="QVBoxLayout" name="verticalLayout_Instructors"/> <layout class="QGridLayout" name="gridLayout_8">
</item> <item row="0" column="0">
</layout> <layout class="QVBoxLayout" name="verticalLayout_Instructors"/>
</widget> </item>
</layout>
</widget>
</item>
</layout>
</item> </item>
</layout> </layout>
</item> </item>
</layout> </layout>
</item> </item>
</layout>
</item>
<item>
<layout class="QVBoxLayout" name="verticalLayout_R">
<item> <item>
<widget class="QGroupBox" name="groupBox_Messenger"> <layout class="QVBoxLayout" name="verticalLayout_R">
<property name="sizePolicy"> <item>
<sizepolicy hsizetype="Expanding" vsizetype="Expanding"> <widget class="QGroupBox" name="groupBox_Messenger">
<horstretch>0</horstretch> <property name="sizePolicy">
<verstretch>0</verstretch> <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
</sizepolicy> <horstretch>0</horstretch>
</property> <verstretch>0</verstretch>
<property name="title"> </sizepolicy>
<string>Messenger</string> </property>
</property> <property name="title">
<layout class="QGridLayout" name="gridLayout_7"> <string>Messenger</string>
<item row="0" column="0"> </property>
<layout class="QVBoxLayout" name="verticalLayout_Messenger"/> <layout class="QGridLayout" name="gridLayout_7">
</item> <item row="0" column="0">
</layout> <layout class="QVBoxLayout" name="verticalLayout_Messenger"/>
</widget> </item>
</layout>
</widget>
</item>
</layout>
</item> </item>
</layout> </layout>
</item> </item>
@@ -388,6 +288,127 @@
</item> </item>
</layout> </layout>
</item> </item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_FootNote">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_ConnectedServer">
<item>
<widget class="QLabel" name="lblDBisConnected">
<property name="minimumSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="resources.qrc">:/resources/icons/circleGray.png</pixmap>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="lblServerPrefix">
<property name="text">
<string>Server: </string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="lblServer">
<property name="text">
<string>none</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_LoggedInInstructor">
<item>
<widget class="QLabel" name="lblLoggedIn">
<property name="minimumSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>32</width>
<height>32</height>
</size>
</property>
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="resources.qrc">:/resources/icons/circleGray.png</pixmap>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="lblLoggedInPrefix">
<property name="maximumSize">
<size>
<width>16777215</width>
<height>40</height>
</size>
</property>
<property name="text">
<string> Instructor: </string>
</property>
<property name="textFormat">
<enum>Qt::AutoText</enum>
</property>
<property name="scaledContents">
<bool>false</bool>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="lblLoggedInInstructor">
<property name="maximumSize">
<size>
<width>16777215</width>
<height>40</height>
</size>
</property>
<property name="text">
<string>none</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</item>
</layout> </layout>
</item> </item>
</layout> </layout>