Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. International
  3. Chinese
  4. QApplication实例化后如何动态设置DPI大小?
Qt 6.12 LTS is out! See what's new in the release blog

QApplication实例化后如何动态设置DPI大小?

Scheduled Pinned Locked Moved Unsolved Chinese
1 Posts 1 Posters 765 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    sanjin Chen
    wrote on last edited by
    #1

    我们正在使用 QML 制作前端软件。Windows 10系统缩放后,我们的软件变大了,超出了屏幕范围,所以我们想做一个最大支持的缩放范围。

    我尝试使用 qputenv ("QT_SCREEN_SCALE_FACTORS") 方法,但是这种方法只在 QApplication 实例化之前有效。我想在软件运行时动态设置DPI并使其实时生效,还是只需要在执行qputenv("QT_SCREEN_SCALE_FACTORS")方法后进行更新操作?

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt
    • Unsolved