找回密码
 立即注册
收起左侧

第19篇 2D绘图(九)图形视图框架(上)

3
回复
6073
查看
[复制链接]
累计签到:11 天
连续签到:1 天
来源: 2016-2-29 17:01:38 显示全部楼层 |阅读模式
1Qter豆

//我们通过类型转换来获得颜色     {        color =qVariantValue<QColor>(event->mimeData()->colorData());


D:\C++MyPrograms\forstudy\graphicView01\myitem.cpp:111: error: C2065: 'qVariantValue' : undeclared identifier


D:\C++MyPrograms\forstudy\graphicView01\myitem.cpp:111: error: C2275: 'QColor' : illegal use of this type as an expression


怎么破   求解

回复

使用道具 举报

累计签到:11 天
连续签到:1 天
2016-3-1 08:59:59 显示全部楼层
QVariantValue。。。。。。。。。。。
回复

使用道具 举报

累计签到:11 天
连续签到:1 天
2016-3-1 09:26:52 显示全部楼层
another_qt 发表于 2016-3-1 08:59
QVariantValue。。。。。。。。。。。

怎么了?我是新手  求指教
回复

使用道具 举报

累计签到:11 天
连续签到:1 天
2016-3-1 09:30:12 显示全部楼层
qVariantValue      把那个改成这个 就行了qvariant_cast
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

公告
可以关注我们的微信公众号yafeilinux_friends获取最新动态,或者加入QQ会员群进行交流:190741849、186601429(已满) 我知道了