This is an automated email from the git hooks/post-receive script. smcv pushed a commit to branch debian/master in repository openjk.
commit b5c3f14ad9c3f2395617f3477312f3b96729e5be Author: Ensiform <ensif...@gmail.com> Date: Fri Nov 3 20:38:37 2017 -0500 Shared: Add DPI awareness manifest This fixes issues with text scaling on Windows. Note: only works with msvc compiles right now CMake script comes from ouned/jk2mv and the manifest file is credits to ioquake3. --- code/CMakeLists.txt | 8 ++++++++ codemp/CMakeLists.txt | 8 ++++++++ shared/sys/win_manifest.xml | 37 +++++++++++++++++++++++++++++++++++++ 3 files changed, 53 insertions(+) diff --git a/code/CMakeLists.txt b/code/CMakeLists.txt index 34525c4..db401e7 100644 --- a/code/CMakeLists.txt +++ b/code/CMakeLists.txt @@ -416,6 +416,14 @@ if(BuildSPEngine OR BuildJK2SPEngine) endif() endif(MakeApplicationBundles) + # add DPI awareness manifest + if(MSVC) + add_custom_command(TARGET ${ProjectName} POST_BUILD + COMMAND "mt.exe" -manifest \"${SharedDir}\\sys\\win_manifest.xml\" -inputresource:\"$<TARGET_FILE:${ProjectName}>\"\;\#1 -outputresource:\"$<TARGET_FILE:${ProjectName}>\"\;\#1 + COMMENT "Adding manifest..." + ) + endif() + set_target_properties(${ProjectName} PROPERTIES COMPILE_DEFINITIONS "${SPEngineDefines}") # Hide symbols not explicitly marked public. diff --git a/codemp/CMakeLists.txt b/codemp/CMakeLists.txt index 2bd4aa4..c2bcbe7 100644 --- a/codemp/CMakeLists.txt +++ b/codemp/CMakeLists.txt @@ -577,6 +577,14 @@ if(BuildMPEngine) endif(MakeApplicationBundles) endif(WIN32) + # add DPI awareness manifest + if(MSVC) + add_custom_command(TARGET ${MPEngine} POST_BUILD + COMMAND "mt.exe" -manifest \"${SharedDir}\\sys\\win_manifest.xml\" -inputresource:\"$<TARGET_FILE:${MPEngine}>\"\;\#1 -outputresource:\"$<TARGET_FILE:${MPEngine}>\"\;\#1 + COMMENT "Adding manifest..." + ) + endif() + if(MakeApplicationBundles) install(TARGETS ${MPEngine} BUNDLE diff --git a/shared/sys/win_manifest.xml b/shared/sys/win_manifest.xml new file mode 100644 index 0000000..2d4412e --- /dev/null +++ b/shared/sys/win_manifest.xml @@ -0,0 +1,37 @@ +<?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3"> + <dependency> + <dependentAssembly> + <assemblyIdentity type="win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0" processorArchitecture="*" publicKeyToken="6595b64144ccf1df" language="*"> + </assemblyIdentity> + </dependentAssembly> + </dependency> + <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3"> + <security> + <requestedPrivileges> + <requestedExecutionLevel level="asInvoker" uiAccess="false"/> + </requestedPrivileges> + </security> + </trustInfo> + <compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1"> + <application> + <!-- No id for Windows XP --> + <!-- Windows Vista --> + <supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}"/> + <!-- Windows 7 --> + <supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/> + <!-- Windows 8 --> + <supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/> + <!-- Windows 8.1 --> + <supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/> + <!-- Windows 10 --> + <supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/> + </application> + </compatibility> + <application xmlns="urn:schemas-microsoft-com:asm.v3"> + <windowsSettings> + <dpiAware xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">True/PM</dpiAware> + <dpiAwareness xmlns="http://schemas.microsoft.com/SMI/2016/WindowsSettings">PerMonitorV2, PerMonitor</dpiAwareness> + </windowsSettings> + </application> +</assembly> \ No newline at end of file -- Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/openjk.git _______________________________________________ Pkg-games-commits mailing list Pkg-games-commits@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-games-commits