Hi,
CMake had hardcoded default support for high-dpi screens in the applications it
generated for Apple's desktop OS at some point, but that was removed very
quickly in 286c75f7f034c5fdcd43bcb755da74d09c809642.
It is my understanding that you don't actually need to set the high-dpi key
explicitly, but that it defaults to on for the desktop OS. IOW, it's enough to
set the NSPrincipalClass property to NSApplication.
I cannot check this myself, and I have no idea if and how NSPrincipalClass can
be set for Apple's other OS variants.
But maybe one could use this property in a minimal-change change to enable
high-dpi support automatically in applications that do not provide their own
Info.plist: add this to the bundle plist template:
+ <key>NSPrincipalClass</key>
+ <${MACOSX_BUNDLE_PRINCIPALCLASS}/>
If the target OS is known when the MACOSX_BUNDLE_* variables get their default,
MACOSX_BUNDLE_PRINCIPALCLASS could default to whatever class is appropriate for
the target OS, otherwise it would just be set to NSApplication (and users
targetting other OS variants would have to set the property explicitly, which
is still less cumbersome than providing a custom template).
Thoughts please?
Thanks,
R.
--
Powered by www.kitware.com
Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ
Kitware offers various services to support the CMake community. For more
information on each offering, please visit:
CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html
Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html
Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake