问题描述
Qt 接口目前在视网膜显示器上看起来很糟糕,因为它们按比例放大.可以将 Info.Plist 用于编译的应用程序,但是有人有动态 Python 的解决方案,例如在 PySide 中创建的接口吗?
Qt interfaces currently look horrible on a retina display as they scale up.Its possible to use an Info.Plist for a complied application but does anyone have a solution for dynamic python such as interfaces created in PySide?
推荐答案
您没有说明您使用的是哪个 Qt 版本.Retina 支持在最新版本 Qt v5.1 中是最好的.但是v5.0的也不错.如果您仍在使用 Qt v4.8,则必须手动应用 补丁 启用高 DPI.
高 DPI 模式由 Info.Plist 文件中的以下键控制:
High DPI mode is controlled by the following keys in the Info.Plist file:
<key>NSPrincipalClass</key>
<string>NSApplication</string>
<key>NSHighResolutionCapable</key>
<string>True</string>
启用高 DPI 后,您仍然必须确保所有光栅内容(图像资源)具有足够高的分辨率才能很好地显示.请参阅 QT 博客文章 Mac OS、iOS 和 X11 的 Retina 显示支持 了解完整详情.
Once high DPI is enabled you still have to make sure that all your raster content (image resources) has a high-enough resolution to be displayed nicely. See the QT Blog post Retina display support for Mac OS, iOS and X11 for the full details.
这篇关于在视网膜显示器上优化 Python QT 应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!