Font rendering on background threads can be a little flaky in Qt, depending on how it was compiled. Check the value of QFontDatabase::supportsThreadedFontRendering on your system.
Note the documentation:
Returns true if font rendering is supported outside the GUI thread, false otherwise. In other words, a return value of false means that all QPainter::drawText() calls outside the GUI thread will not produce readable output.
然后我分别在Windows和Linux下调试了下返回值。一个返回true一个返回false,感觉麻烦大了。


到此这篇qpainter 绘制图片(qpainter绘制文字)的文章就介绍到这了,更多相关内容请继续浏览下面的相关 推荐文章,希望大家都能在编程的领域有一番成就!
版权声明:
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。
如若内容造成侵权、违法违规、事实不符,请将相关资料发送至xkadmin@xkablog.com进行投诉反馈,一经查实,立即处理!
转载请注明出处,原文链接:https://www.xkablog.com/rfx/23183.html