ui 0.11 修改按钮颜色 增加help界面
This commit is contained in:
15
Classes/Help.cpp
Normal file
15
Classes/Help.cpp
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
#include "Help.h"
|
||||||
|
|
||||||
|
Help::Help(QWidget *parent)
|
||||||
|
: QWidget(parent)
|
||||||
|
{
|
||||||
|
ui.setupUi(this);
|
||||||
|
|
||||||
|
// QTextCodec *codec = QTextCodec::codecForName("utf-8"); //不起作用
|
||||||
|
// QTextCodec::setCodecForLocale(codec);
|
||||||
|
ui.textBrowser->setText(QString::fromUtf8("help")); // 暂时不能写显示中文
|
||||||
|
}
|
||||||
|
|
||||||
|
Help::~Help()
|
||||||
|
{
|
||||||
|
}
|
||||||
17
Classes/Help.h
Normal file
17
Classes/Help.h
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <QWidget>
|
||||||
|
#include "ui_Help.h"
|
||||||
|
#include <QTextCodec>
|
||||||
|
|
||||||
|
class Help : public QWidget
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
Help(QWidget *parent = Q_NULLPTR);
|
||||||
|
~Help();
|
||||||
|
|
||||||
|
private:
|
||||||
|
Ui::Help ui;
|
||||||
|
};
|
||||||
@@ -48,8 +48,8 @@ void Reconstruction::setPicStyle()
|
|||||||
void Reconstruction::setButtonStyle()
|
void Reconstruction::setButtonStyle()
|
||||||
{
|
{
|
||||||
QString buttonStyle = "QPushButton{background-color:white;color: black;}"
|
QString buttonStyle = "QPushButton{background-color:white;color: black;}"
|
||||||
"QPushButton:hover{background-color:#cceeff; color: black;}"
|
"QPushButton:hover{background-color:#e5ebfb; color: black;}"
|
||||||
"QPushButton:pressed{background-color:rgb(85, 170, 255);border - style: inset; }";
|
"QPushButton:pressed{background-color:rgb(204,213,240);border - style: inset; }";
|
||||||
ui.pushButton->setStyleSheet(buttonStyle);
|
ui.pushButton->setStyleSheet(buttonStyle);
|
||||||
ui.pushButton_2->setStyleSheet(buttonStyle);
|
ui.pushButton_2->setStyleSheet(buttonStyle);
|
||||||
ui.pushButton_3->setStyleSheet(buttonStyle);
|
ui.pushButton_3->setStyleSheet(buttonStyle);
|
||||||
@@ -359,4 +359,11 @@ void Reconstruction::on_pushButton_16_clicked()
|
|||||||
// todo 颜色选取框已选择颜色color,接下来对color进行处理
|
// todo 颜色选取框已选择颜色color,接下来对color进行处理
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 帮助
|
||||||
|
void Reconstruction::on_pushButton_18_clicked()
|
||||||
|
{
|
||||||
|
Help* help = new Help();
|
||||||
|
help->show();
|
||||||
|
}
|
||||||
#pragma endregion
|
#pragma endregion
|
||||||
|
|||||||
@@ -16,6 +16,7 @@
|
|||||||
#include <vtkRenderWindow.h>
|
#include <vtkRenderWindow.h>
|
||||||
#include <QProgressDialog>
|
#include <QProgressDialog>
|
||||||
#include "MyThread.h"
|
#include "MyThread.h"
|
||||||
|
#include "Help.h"
|
||||||
using namespace pcl;
|
using namespace pcl;
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
@@ -60,6 +61,7 @@ private slots:
|
|||||||
void on_pushButton_15_clicked();
|
void on_pushButton_15_clicked();
|
||||||
void on_pushButton_16_clicked();
|
void on_pushButton_16_clicked();
|
||||||
void on_pushButton_17_clicked();
|
void on_pushButton_17_clicked();
|
||||||
|
void on_pushButton_18_clicked();
|
||||||
void setPicAction(QString action);
|
void setPicAction(QString action);
|
||||||
void setCloud();
|
void setCloud();
|
||||||
};
|
};
|
||||||
|
|||||||
30
UI/Help.ui
Normal file
30
UI/Help.ui
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<ui version="4.0">
|
||||||
|
<class>Help</class>
|
||||||
|
<widget class="QWidget" name="Help">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>601</width>
|
||||||
|
<height>411</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>Help</string>
|
||||||
|
</property>
|
||||||
|
<widget class="QTextBrowser" name="textBrowser">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>10</x>
|
||||||
|
<y>10</y>
|
||||||
|
<width>581</width>
|
||||||
|
<height>391</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</widget>
|
||||||
|
<layoutdefault spacing="6" margin="11"/>
|
||||||
|
<resources/>
|
||||||
|
<connections/>
|
||||||
|
</ui>
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
<string notr="true"/>
|
<string notr="true"/>
|
||||||
</property>
|
</property>
|
||||||
<property name="currentIndex">
|
<property name="currentIndex">
|
||||||
<number>1</number>
|
<number>2</number>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QWidget" name="page">
|
<widget class="QWidget" name="page">
|
||||||
<widget class="QLabel" name="label_2">
|
<widget class="QLabel" name="label_2">
|
||||||
@@ -1016,7 +1016,7 @@
|
|||||||
<property name="geometry">
|
<property name="geometry">
|
||||||
<rect>
|
<rect>
|
||||||
<x>820</x>
|
<x>820</x>
|
||||||
<y>330</y>
|
<y>310</y>
|
||||||
<width>141</width>
|
<width>141</width>
|
||||||
<height>41</height>
|
<height>41</height>
|
||||||
</rect>
|
</rect>
|
||||||
@@ -1034,7 +1034,7 @@
|
|||||||
<property name="geometry">
|
<property name="geometry">
|
||||||
<rect>
|
<rect>
|
||||||
<x>820</x>
|
<x>820</x>
|
||||||
<y>410</y>
|
<y>390</y>
|
||||||
<width>141</width>
|
<width>141</width>
|
||||||
<height>41</height>
|
<height>41</height>
|
||||||
</rect>
|
</rect>
|
||||||
@@ -1052,7 +1052,7 @@
|
|||||||
<property name="geometry">
|
<property name="geometry">
|
||||||
<rect>
|
<rect>
|
||||||
<x>820</x>
|
<x>820</x>
|
||||||
<y>490</y>
|
<y>470</y>
|
||||||
<width>141</width>
|
<width>141</width>
|
||||||
<height>41</height>
|
<height>41</height>
|
||||||
</rect>
|
</rect>
|
||||||
@@ -1098,6 +1098,24 @@
|
|||||||
<string/>
|
<string/>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
|
<widget class="QPushButton" name="pushButton_18">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>820</x>
|
||||||
|
<y>550</y>
|
||||||
|
<width>141</width>
|
||||||
|
<height>41</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="font">
|
||||||
|
<font>
|
||||||
|
<family>黑体</family>
|
||||||
|
</font>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>帮助</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
</widget>
|
</widget>
|
||||||
</widget>
|
</widget>
|
||||||
<widget class="QWidget" name="widget" native="true">
|
<widget class="QWidget" name="widget" native="true">
|
||||||
|
|||||||
Reference in New Issue
Block a user