博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
QML实现PinchArea和MouseArea实现图片缩放和平移功能同时具备
阅读量:4112 次
发布时间:2019-05-25

本文共 885 字,大约阅读时间需要 2 分钟。

Image {            id: photoImage            //fillMode: Image.Pad  //Image.Pad:原始图像不做处理            source:  (typeof picture_Scan_D_Area.pictureList[picture_Scan_D_Area.pictureIndex] === 'undefined') ? "" : picture_Scan_D_Area.pictureList[picture_Scan_D_Area.pictureIndex]  //pictureIndex = 0            smooth: true            mipmap: true            antialiasing: true            Component.onCompleted: {           //它的存在就是在页面完成加载的时候,同时进行的操作                x = parent.width / 2 - width / 2     //width:1180                y = parent.height / 2 - height / 2   //height:770                photoImage.scale =  80 / 100         // 让图片显示80%大小                console.log("picture_Scan_D_Area.pictureList:",picture_Scan_D_Area.pictureList.length)            }           // Drag.active: mouseArea.drag.active            PinchArea {   //PinchArea 本身是一个不可见的 Item ,通常和一个可见的 Item 配合使用来处理捏拉手势,这里和

转载地址:http://jsesi.baihongyu.com/

你可能感兴趣的文章
OpenFeign学习(六):OpenFign进行表单提交参数或传输文件
查看>>
OpenFeign学习(七):Spring Cloud OpenFeign的使用
查看>>
Ribbon 学习(二):Spring Cloud Ribbon 加载配置原理
查看>>
Ribbon 学习(三):RestTemplate 请求负载流程解析
查看>>
深入理解HashMap
查看>>
XML生成(一):DOM生成XML
查看>>
XML生成(三):JDOM生成
查看>>
Ubuntu Could not open lock file /var/lib/dpkg/lock - open (13:Permission denied)
查看>>
collect2: ld returned 1 exit status
查看>>
C#入门
查看>>
查找最大值最小值
查看>>
C#中ColorDialog需点两次确定才会退出的问题
查看>>
数据库
查看>>
nginx反代 499 502 bad gateway 和timeout
查看>>
linux虚拟机安装tar.gz版jdk步骤详解
查看>>
python猜拳游戏
查看>>
python实现100以内自然数之和,偶数之和
查看>>
python数字逆序输出及多个print输出在同一行
查看>>
ESP8266 WIFI数传 Pixhaw折腾笔记
查看>>
苏宁产品经理面经
查看>>