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

用新华做网站名是否侵权wordpress网页视频播放器

用新华做网站名是否侵权,wordpress网页视频播放器,建设科技信息+网站建设,广告公司网站策划程序示例精选 VSQtC旅游景区地图导航 如需安装运行环境或远程调试&#xff0c;见文章底部个人QQ名片&#xff0c;由专业技术人员远程协助&#xff01; 前言 这篇博客针对<<VSQtC旅游景区地图导航>>编写代码&#xff0c;代码整洁&#xff0c;规则&#xff0c;易读。…

  程序示例精选

VS+Qt+C++旅游景区地图导航

如需安装运行环境或远程调试,见文章底部个人QQ名片,由专业技术人员远程协助!

前言

这篇博客针对<<VS+Qt+C++旅游景区地图导航>>编写代码,代码整洁,规则,易读。 学习与应用推荐首选。


文章目录

一、所需工具软件

二、使用步骤

        1. 引入库

        2. 代码实现

        3. 运行结果

三、在线协助

一、所需工具软件

1. VS, Qt

2. C++

二、使用步骤

1.引入库

#include "MainWindow.h"
#include<iostream>#include<qDebug>
#include<QFile>
#include <QBitmap>
#include <QPainter>
#include<QImage>
#include<QPixmap>
#include <QGraphicsScene>
#include <QGraphicsView>
#include <QPointF>
#include <QLineF>

2. 代码实现

代码如下:

.h*************************************
#pragma once#include <QtWidgets/QMainWindow>
#include "ui_MainWindow.h"#include <qDebug>class MainWindow : public QMainWindow
{Q_OBJECTpublic:MainWindow(QWidget *parent = Q_NULLPTR);protected:private:Ui::MainWindowClass ui;private slots:void OnSearch();void mapBackGround();void initStyleSheetTitle();void paintEvent(QPaintEvent* event);void initStyleSheetMapButton();void initStyleSheetButton();void initStyleSheetLabel();};.cpp********************************
MainWindow::MainWindow(QWidget *parent): QMainWindow(parent)
{ui.setupUi(this);QObject::connect(ui.pushButton_7, SIGNAL(clicked()), this, SLOT(OnSearch()));ui.frame->setFrameStyle(QFrame::NoFrame);ui.frame_3->setFrameStyle(QFrame::NoFrame);
}void MainWindow::mouseDoubleClickEvent(QMouseEvent* event)
{int x = pos.x();int y = pos.y();qDebug() << "Double clicked at (" << x << "," << y << ")";
}void MainWindow::OnSearch()
{std::cout << "modelRun" << std::endl;QString startPos = ui.comboBox->currentText();QString endPos = ui.comboBox_2->currentText();qDebug() << "startPos: " << startPos;qDebug() << "endPos: " << endPos;if (startPos == QStringLiteral("孔子文化园") | startPos == QStringLiteral("碰碰车")){qDebug() << QStringLiteral("孔子文化园") ;// 添加两个点坐标QPointF point1(165, 228);QPointF point2(271, 218);QPointF point3(310, 95);// 设置GraphicsView的大小ui.graphicsView->setRenderHint(QPainter::Antialiasing); // 设置抗锯齿渲染ui.graphicsView->setAlignment(Qt::AlignLeft | Qt::AlignTop); // 设置对齐方式ui.graphicsView->setResizeAnchor(QGraphicsView::AnchorUnderMouse); // 设置缩放锚点为鼠标位置ui.graphicsView->setDragMode(QGraphicsView::ScrollHandDrag); // 设置拖拽模式为滚动手势拖拽QPen pen(Qt::red); // 设置线条颜色为红色pen.setWidth(2);   // 设置线宽为2// 在graphicsView_2的坐标系下绘制圆int radius = 25;int borderWidth = 5; // 壁厚pen.setWidth(borderWidth); // 设置线宽scene->addEllipse(point1.x() - (radius - borderWidth),point1.y() - (radius - borderWidth),(radius - borderWidth) * 2,(radius - borderWidth) * 2,pen, QBrush(Qt::NoBrush));scene->addEllipse(point2.x() - (radius - borderWidth),point2.y() - (radius - borderWidth),(radius - borderWidth) * 2,(radius - borderWidth) * 2,pen, QBrush(Qt::NoBrush));scene->addEllipse(point3.x() - (radius - borderWidth),point3.y() - (radius - borderWidth),(radius - borderWidth) * 2,(radius - borderWidth) * 2,pen, QBrush(Qt::NoBrush));// 绘制线段scene->addLine(QLineF(point1, point2), pen);scene->addLine(QLineF(point2, point3), pen);}}void MainWindow::initStyleSheetTitle()
{QString cssStr = "./style/style_label_title.css";QFile file(cssStr);if (file.open(QFile::ReadOnly)){QString qss = QLatin1String(file.readAll());ui.label->setStyleSheet(qss);file.close();}else {qDebug() << "Failed to open CSS file: " << file.fileName();}}void MainWindow::mapBackGround()
{QString cssStr = "./style/style_frame_mapBG.css";QString qss;QFile file(cssStr);if (file.open(QFile::ReadOnly)){qss = QLatin1String(file.readAll());//ui.frame_2->setStyleSheet(qss);file.close();}else {qDebug() << "Failed to open CSS file: " << file.fileName();}
}void MainWindow::initStyleSheetButton()
{QString cssStr = "./style/style_pushButton.css";QString qss;QFile file(cssStr);if (file.open(QFile::ReadOnly)){qss = QLatin1String(file.readAll());ui.pushButton_7->setStyleSheet(qss);file.close();}else {qDebug() << "Failed to open CSS file: " << file.fileName();}}void MainWindow::initStyleSheetMapButton()
{QString cssStr = "./style/style_pushButton_map.css";QString qss;QFile file(cssStr);if (file.open(QFile::ReadOnly)){qss = QLatin1String(file.readAll());//ui.pushButton_3->setStyleSheet(qss);//ui.pushButton_4->setStyleSheet(qss);//ui.pushButton_5->setStyleSheet(qss);//ui.pushButton_6->setStyleSheet(qss);file.close();}else {qDebug() << "Failed to open CSS file: " << file.fileName();}}

3. 运行结果

三、在线协助:

如需安装运行环境或远程调试,见文章底部个人 QQ 名片,由专业技术人员远程协助!
1)远程安装运行环境,代码调试
2)Qt, C++, Python入门指导
3)界面美化
4)软件制作

当前文章连接:Python+Qt桌面端与网页端人工客服沟通工具_alicema1111的博客-CSDN博客

博主推荐文章:python人脸识别统计人数qt窗体-CSDN博客

博主推荐文章:Python Yolov5火焰烟雾识别源码分享-CSDN博客

                         Python OpenCV识别行人入口进出人数统计_python识别人数-CSDN博客

个人博客主页:alicema1111的博客_CSDN博客-Python,C++,网页领域博主

博主所有文章点这里alicema1111的博客_CSDN博客-Python,C++,网页领域博主

http://www.yayakq.cn/news/261462/

相关文章:

  • hexo建设网站建设小型网站
  • 网站建设维护工作nova wordpress主题
  • 网站开发语言哪几种视频上传网站源码
  • 网站建设不一定当地wordpress手机插件
  • 建筑设计网站 知乎建站系统的选用分析
  • 上海市城乡建设网站中国最大网站建设商推荐知乎
  • 浚县网站建设成都专业网站推广公司
  • 阿里云除了做网站还能用来干什么洛阳做家教去什么网站
  • 山东省建设工程信息网官网seo的方法
  • 苏州网站推广建设前程无忧做一年网站多钱
  • 广州网站建设公司排行青海建设云网站
  • 网站制作网页制作手机网站打开微信登录
  • 那种转转假网站怎么做的wordpress动漫博客主题免费下载
  • 深圳设计师品牌清城网站seo
  • 广州 海珠 建网站南阳网站seo
  • 优化网站速度的要点百度编辑器wordpress
  • 松岗网站设计怎么做网站有利于收录
  • 东莞网站优化科技有限公司长沙网页设计培训班哪家好
  • 网站建设文案策划浮雕模东莞网站建设
  • 京东商城网站的搜索引擎营销做的案例分析上海注册公司需要多少钱
  • 网站建设包括网页设计网站文章批量上传工具
  • 各大网站代下单怎么做外贸如何做网站推广
  • 网站建设如何商谈wordpress 的前端框架
  • html5网站引导页模板网络营销推广方法和工具有哪些?
  • 广东网站建设服务个人网站怎么注册
  • 网页设计与网站建设教程南宁做网站价格
  • 中英文的网站是怎么做的毕业设计查资料的网站
  • 深圳网站的优化哪里可以接公司外包业务
  • 上海广告网站建设如何提供网站建设公司
  • 开发网站中心做网站需要几万吗