社区
其他技术讨论专区
帖子详情
我移动图像移动提示:QPainter::setPen: Painter not active
weixin_38061618
2019-09-19 04:38:43
大家好。我做使用键盘控制图标移动,按键提示:QPainter::begin: A paint device can only be painted by one painter at a time.QPainter::setPen: Painter not active不知道什么意思:谢谢了
...全文
131
回复
打赏
收藏
我移动图像移动提示:QPainter::setPen: Painter not active
大家好。我做使用键盘控制图标移动,按键提示:QPainter::begin: A paint device can only be painted by one painter at a time.QPainter::setPen: Painter not active不知道什么意思:谢谢了
复制链接
扫一扫
分享
转发到动态
举报
写回复
配置赞助广告
用AI写文章
回复
切换为时间正序
请发表友善的回复…
发表回复
打赏红包
Q
Paint
er
::
set
Pen
:
Paint
er
not
active
问题解决
利用QT库中的
Q
Paint
er
进行绘图,产生
Q
Paint
er
::
set
Pen
:
Paint
er
not
active
运行输出。。。
Q
Paint
er
::
set
Pen
:
Paint
er
not
active
解决方案
Q
Paint
er
::
set
Pen
:
Paint
er
not
active
解决方案:把绘制图形的操作放在
paint
Event事件函数中
Q
Paint
er
::
set
Font:
Paint
er
not
active
和
Q
Paint
er
::
set
Pen
:
Paint
er
not
active
运用想要使用
Q
Paint
er
绘图时,运行时出现如上所示错误,原因如下: 因为QT不像MFC在什么时间都可以绘图,使用
Q
Paint
er
画图,就要继承QWidget,重写p
paint
Event()虚函数,在里面进行绘图。 如果要在其他地方绘制图形,可以考虑绘制到QImage或者QPixmap上面,然后在
paint
Event()里面调用
Q
Paint
er
的绘制
图像
的
解决Qt6 C++
Q
paint
er
画图时
Paint
er
not
active
QWidget::
paint
Engine: Should no long
er
be calledQ
Paint
的问题
画图出现问题如下: QWidget::
paint
Engine: Should no long
er
be called
Q
Paint
er
::begin:
Paint
device returned engine == 0, type: 1
Q
Paint
er
::
set
Pen
:
Paint
er
not
active
Q
Paint
er
::
set
Pen
:
Paint
er
not
active
Q
Paint
er
::end:
Paint
er
not
active
, aborted QWidget::
paint
En
qt
Q
Paint
er
错误总结
QWidget::
paint
Engine: Should no long
er
be called
Q
Paint
er
::begin:
Paint
device returned engine == 0, type: 1
Q
Paint
er
::
set
Pen
:
Paint
er
not
active
Q
Paint
er
::drawPoints:
Paint
er
not
active
其他技术讨论专区
430
社区成员
791,273
社区内容
发帖
与我相关
我的任务
其他技术讨论专区
其他技术讨论专区
复制链接
扫一扫
分享
社区描述
其他技术讨论专区
其他
技术论坛(原bbs)
社区管理员
加入社区
获取链接或二维码
近7日
近30日
至今
加载中
查看更多榜单
社区公告
暂无公告
试试用AI创作助手写篇文章吧
+ 用AI写文章