当前位置: 首页 > news >正文

三水网站设计wordpress 待审文章

三水网站设计,wordpress 待审文章,网站如何在百度上搜索到,做直播app的公司文章目录 前言一、温度湿度曲线布局二、环境监测界面布局三、摄像头界面布局总结 前言 本篇文章来完成另外三个界面的布局设置。 这里会使用到 feiyangqingyun的一些控件库。 一、温度湿度曲线布局 TempHumtiy.h: #ifndef TEMPHUMTIY_H #define TEMPHUMTIY_H#include … 文章目录 前言一、温度湿度曲线布局二、环境监测界面布局三、摄像头界面布局总结 前言 本篇文章来完成另外三个界面的布局设置。 这里会使用到 feiyangqingyun的一些控件库。 一、温度湿度曲线布局 TempHumtiy.h: #ifndef TEMPHUMTIY_H #define TEMPHUMTIY_H#include QWidget #include wavechart.hnamespace Ui { class TempHumtiy; }class TempHumtiy : public QWidget {Q_OBJECTWaveChart* TempWave;//温度曲线WaveChart* HumityWave;//湿度曲线public:explicit TempHumtiy(QWidget *parent nullptr);~TempHumtiy();private:Ui::TempHumtiy *ui; };#endif // TEMPHUMTIY_H TempHumtiy.cpp: #include TempHumtiy.h #include ui_TempHumtiy.h #include QVBoxLayoutTempHumtiy::TempHumtiy(QWidget *parent) :QWidget(parent),ui(new Ui::TempHumtiy) {ui-setupUi(this);QVBoxLayout* vlaout new QVBoxLayout(this);//温度曲线TempWave new WaveChart();TempWave-setTitle(温度曲线);//湿度曲线HumityWave new WaveChart();HumityWave-setTitle(温度曲线);vlaout-addWidget(TempWave);vlaout-addWidget(HumityWave); }TempHumtiy::~TempHumtiy() {delete ui; } 运行效果 二、环境监测界面布局 Illumination.h: #include Illumination.h #include ui_Illumination.h #include QHBoxLayout #include QLabel #include QFont #include QPaletteIllumination::Illumination(QWidget *parent) :QWidget(parent),ui(new Ui::Illumination) {ui-setupUi(this);QFont font(Arial, 20);QPalette palette;palette.setColor(QPalette::WindowText, Qt::white);QLabel* label1 new QLabel(烟雾浓度);label1-setFont(font);label1-setPalette(palette);label1-setAlignment(Qt::AlignCenter);QLabel* label2 new QLabel(光照强度);label2-setFont(font);label2-setPalette(palette);label2-setAlignment(Qt::AlignCenter);QLabel* label3 new QLabel(Co2浓度);label3-setFont(font);label3-setPalette(palette);label3-setAlignment(Qt::AlignCenter);QHBoxLayout* hlayout new QHBoxLayout();QHBoxLayout* hlayout1 new QHBoxLayout();QVBoxLayout* vlayout new QVBoxLayout(this);hlayout1-addWidget(label1);hlayout1-addWidget(label2);hlayout1-addWidget(label3);/* 烟雾浓度 */Smoke new ProgressPercent();Smoke-setValue(20);Smoke-setUsedColor(QColor(255, 127, 39));Smoke-setPercentStyle(ProgressPercent::PercentStyle_Arc_Wave);/* 光照强度 */IllCent new ProgressPercent();IllCent-setValue(15);IllCent-setUsedColor(QColor(237, 201, 14));IllCent-setPercentStyle(ProgressPercent::PercentStyle_Arc_Wave);/* Co2 */Co2 new ProgressPercent();Co2-setValue(25);Co2-setUsedColor(QColor(237, 28, 36));Co2-setPercentStyle(ProgressPercent::PercentStyle_Arc_Wave);hlayout-addWidget(Smoke);hlayout-addWidget(IllCent);hlayout-addWidget(Co2);vlayout-addStretch();vlayout-addLayout(hlayout);vlayout-addLayout(hlayout1);vlayout-addStretch(); }Illumination::~Illumination() {delete ui; } Illumination.cpp: #include Illumination.h #include ui_Illumination.h #include QHBoxLayout #include QLabel #include QFont #include QPaletteIllumination::Illumination(QWidget *parent) :QWidget(parent),ui(new Ui::Illumination) {ui-setupUi(this);QFont font(Arial, 20);QPalette palette;palette.setColor(QPalette::WindowText, Qt::white);QLabel* label1 new QLabel(烟雾浓度);label1-setFont(font);label1-setPalette(palette);label1-setAlignment(Qt::AlignCenter);QLabel* label2 new QLabel(光照强度);label2-setFont(font);label2-setPalette(palette);label2-setAlignment(Qt::AlignCenter);QLabel* label3 new QLabel(Co2浓度);label3-setFont(font);label3-setPalette(palette);label3-setAlignment(Qt::AlignCenter);QHBoxLayout* hlayout new QHBoxLayout();QHBoxLayout* hlayout1 new QHBoxLayout();QVBoxLayout* vlayout new QVBoxLayout(this);hlayout1-addWidget(label1);hlayout1-addWidget(label2);hlayout1-addWidget(label3);/* 烟雾浓度 */Smoke new ProgressPercent();Smoke-setValue(20);Smoke-setUsedColor(QColor(255, 127, 39));Smoke-setPercentStyle(ProgressPercent::PercentStyle_Arc_Wave);/* 光照强度 */IllCent new ProgressPercent();IllCent-setValue(15);IllCent-setUsedColor(QColor(237, 201, 14));IllCent-setPercentStyle(ProgressPercent::PercentStyle_Arc_Wave);/* Co2 */Co2 new ProgressPercent();Co2-setValue(25);Co2-setUsedColor(QColor(237, 28, 36));Co2-setPercentStyle(ProgressPercent::PercentStyle_Arc_Wave);hlayout-addWidget(Smoke);hlayout-addWidget(IllCent);hlayout-addWidget(Co2);vlayout-addStretch();vlayout-addLayout(hlayout);vlayout-addLayout(hlayout1);vlayout-addStretch(); }Illumination::~Illumination() {delete ui; } 运行效果: 三、摄像头界面布局 将QWidget提升为QVideoWidget,这个界面用于显示摄像头的图形。 Camera.h: #ifndef CAMERA_H #define CAMERA_H#include QWidget #include QCamera #include QVideoWidget #include QMediaCaptureSession #include QMediaDevicesnamespace Ui { class Camera; }class Camera : public QWidget {Q_OBJECT// 设置摄像机QCamera* camera;// 媒体会话QMediaCaptureSession* captureSession;public:explicit Camera(QWidget *parent nullptr);~Camera();private:Ui::Camera *ui; };#endif // CAMERA_H Camera.cpp: #include Camera.h #include ui_Camera.hCamera::Camera(QWidget *parent) :QWidget(parent),ui(new Ui::Camera) {ui-setupUi(this);// 默认的视频输入设备QCameraDevice defaultVideoInput QMediaDevices::defaultVideoInput();// 设置摄像机camera new QCamera(QMediaDevices::defaultVideoInput());// 媒体会话captureSession new QMediaCaptureSession();captureSession-setCamera(camera);captureSession-setVideoOutput(ui-widget);camera-start();}Camera::~Camera() {delete ui; } 运行效果 总结 本篇文章就讲解到这里。
http://wiki.neutronadmin.com/news/316019/

相关文章:

  • 贵阳网站建设制作织梦 音乐网站
  • 深圳建站网站公司怎样在我的世界做汽车视频网站
  • 网站信息查询北京房产网官网
  • 网站运营适合什么样的人做微官网 手机网站
  • 织梦网站地图制作好看的模板
  • 江苏华江建设集团有限公司网站南京网站制作费用
  • 保定市制作网站公司软件工程专业招聘网站
  • 网站两个域名简单广告设计软件
  • 站群cms系统区块链
  • 网站公司注册流程淘宝客网站源码html
  • 网站开发需求文件进口网站建设
  • 浙江网站建设抖音seo优化建材网站建设 南宁
  • 一个空间只能放一个网站吗福田住房和建设局网站官网
  • 滁州新手跨境电商建站哪家好wordpress评论头像
  • 求好的设计网站福州网站开发风格
  • 新闻宣传培训网站内容建设网站建设需要的资料
  • 网站建设需不需要编程江苏建设教育协会网站
  • 南海做网站公司网站开发合同注意事项
  • 网站的技术支持汶上手机网站建设
  • 网站建设什么行业天津购物网站搭建
  • 上高做网站公司做配单ic去什么网站好
  • 做网站用百度地图和天地图东莞百域网站建设公司
  • 《网站平台建设》课程实训wordpress无法连接数据库连接
  • 网页版微信二维码登录方法做优化的网站
  • 购买网站模板盘锦兴隆台住房和城乡建设网站
  • 多平台网站设计实例电子商务网站建设功能
  • 网站建设朋友圈广告桥头镇网站仿做
  • 学网站开发的能找什么工作WordPress如何恢复最初
  • 站长之家网站建设酒店找人做网站
  • 用wordpress做淘宝客应用商店关键词优化