Compare commits
3 Commits
TAG-2.16be
...
TAG-2.16
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f46f5148a3 | ||
|
|
97b083ed07 | ||
|
|
9743c6f757 |
@@ -103,10 +103,12 @@ int NoMeiryoUI::OnAppliStart(TCHAR *lpCmdLine)
|
||||
} else {
|
||||
// Windows 8/8.1
|
||||
WIN8_SIZE = true;
|
||||
use7Compat = true;
|
||||
}
|
||||
} else {
|
||||
// Windows 10 or later
|
||||
WIN8_SIZE = true;
|
||||
WIN8_SIZE = false;
|
||||
use7Compat = false;
|
||||
}
|
||||
|
||||
return 0;
|
||||
@@ -377,7 +379,7 @@ INT_PTR NoMeiryoUI::OnCommand(WPARAM wParam)
|
||||
return (INT_PTR)0;
|
||||
case IDM_ABOUT:
|
||||
MessageBox(hWnd,
|
||||
_T("Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!! Version 2.16 Beta 1\n\nBy Tatsuhiko Syoji(Tatsu) 2005,2012-2015"),
|
||||
_T("Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!! Version 2.16\n\nBy Tatsuhiko Syoji(Tatsu) 2005,2012-2015"),
|
||||
_T("Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!!<21>ɂ<C982><C282><EFBFBD>"),
|
||||
MB_OK | MB_ICONINFORMATION);
|
||||
|
||||
@@ -1066,11 +1068,33 @@ void NoMeiryoUI::OnBnClickedAll()
|
||||
updateDisplay();
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>V<EFBFBD>X<EFBFBD>e<EFBFBD><65><EFBFBD><EFBFBD>DPI<50><49><EFBFBD>擾<EFBFBD><E693BE><EFBFBD><EFBFBD><EFBFBD>B
|
||||
*
|
||||
* @return <20>擾<EFBFBD><E693BE><EFBFBD><EFBFBD>DPI
|
||||
*/
|
||||
int NoMeiryoUI::getDPI(void)
|
||||
{
|
||||
// DPI<50><49><EFBFBD>擾<EFBFBD><E693BE><EFBFBD><EFBFBD><EFBFBD>B
|
||||
int dpiY = 96;
|
||||
HDC hdc = GetDC(NULL);
|
||||
|
||||
if (hdc) {
|
||||
dpiY = GetDeviceCaps(hdc, LOGPIXELSY);
|
||||
ReleaseDC(NULL, hdc);
|
||||
}
|
||||
|
||||
return dpiY;
|
||||
}
|
||||
|
||||
/**
|
||||
* Windows 8/8.1<EFBFBD>̏ꍇ<EFBFBD>̃v<EFBFBD><EFBFBD><EFBFBD>Z<EFBFBD>b<EFBFBD>g<EFBFBD>l<EFBFBD><EFBFBD><EFBFBD>ݒ肷<EFBFBD><EFBFBD><EFBFBD>B
|
||||
*/
|
||||
void NoMeiryoUI::OnSet8(void)
|
||||
{
|
||||
// DPI<50><49><EFBFBD>擾<EFBFBD><E693BE><EFBFBD><EFBFBD><EFBFBD>B
|
||||
int dpiY = getDPI();
|
||||
|
||||
// <20>t<EFBFBD>H<EFBFBD><48><EFBFBD>g<EFBFBD>ȊO<C88A><4F>NONCLIENTMETRICS<43>̌<EFBFBD><CC8C>ݒl<DD92><6C><EFBFBD>ێ<EFBFBD><DB8E><EFBFBD><EFBFBD>邽<EFBFBD>߁A
|
||||
// NONCLIENTMETRICS<43>̓<EFBFBD><CC93>e<EFBFBD><65><EFBFBD>擾<EFBFBD><E693BE><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>B
|
||||
FillMemory(&metrics,sizeof(NONCLIENTMETRICS),0x00);
|
||||
@@ -1082,39 +1106,45 @@ void NoMeiryoUI::OnSet8(void)
|
||||
|
||||
memset(&metrics.lfCaptionFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfCaptionFont.lfFaceName, _T("Meiryo UI"));
|
||||
metrics.lfCaptionFont.lfHeight = -15;
|
||||
metrics.lfCaptionFont.lfHeight = MulDiv(-15,dpiY,96);
|
||||
metrics.lfCaptionFont.lfWeight = 400;
|
||||
metrics.lfCaptionFont.lfCharSet = 1;
|
||||
metrics.lfCaptionFont.lfQuality = 5;
|
||||
|
||||
memset(&iconFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(iconFont.lfFaceName, _T("Meiryo UI"));
|
||||
iconFont.lfHeight = -12;
|
||||
iconFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
iconFont.lfWeight = 400;
|
||||
iconFont.lfCharSet = 1;
|
||||
iconFont.lfQuality = 5;
|
||||
|
||||
memset(&metrics.lfSmCaptionFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfSmCaptionFont.lfFaceName, _T("Meiryo UI"));
|
||||
metrics.lfSmCaptionFont.lfHeight = -15;
|
||||
metrics.lfSmCaptionFont.lfHeight = MulDiv(-15, dpiY, 96);
|
||||
metrics.lfSmCaptionFont.lfWeight = 400;
|
||||
metrics.lfSmCaptionFont.lfCharSet = 1;
|
||||
metrics.lfSmCaptionFont.lfQuality = 5;
|
||||
|
||||
memset(&metrics.lfStatusFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfStatusFont.lfFaceName, _T("Meiryo UI"));
|
||||
metrics.lfStatusFont.lfHeight = -12;
|
||||
metrics.lfStatusFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
metrics.lfStatusFont.lfWeight = 400;
|
||||
metrics.lfStatusFont.lfCharSet = 1;
|
||||
metrics.lfStatusFont.lfQuality = 5;
|
||||
|
||||
memset(&metrics.lfMessageFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfMessageFont.lfFaceName, _T("Meiryo UI"));
|
||||
metrics.lfMessageFont.lfHeight = -12;
|
||||
metrics.lfMessageFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
metrics.lfMessageFont.lfWeight = 400;
|
||||
metrics.lfMessageFont.lfCharSet = 1;
|
||||
metrics.lfMessageFont.lfQuality = 5;
|
||||
|
||||
memset(&metrics.lfMenuFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfMenuFont.lfFaceName, _T("Meiryo UI"));
|
||||
metrics.lfMenuFont.lfHeight = -12;
|
||||
metrics.lfMenuFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
metrics.lfMenuFont.lfWeight = 400;
|
||||
metrics.lfMenuFont.lfCharSet = 1;
|
||||
metrics.lfMenuFont.lfQuality = 5;
|
||||
|
||||
// <20>\<5C><><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>B
|
||||
updateDisplay();
|
||||
@@ -1122,10 +1152,13 @@ void NoMeiryoUI::OnSet8(void)
|
||||
}
|
||||
|
||||
/**
|
||||
* Windows 10<31>̏ꍇ<CC8F>̃v<CC83><76><EFBFBD>Z<EFBFBD>b<EFBFBD>g<EFBFBD>l<EFBFBD><6C><EFBFBD>ݒ肷<DD92><E882B7><EFBFBD>B
|
||||
*/
|
||||
* Windows 10<31>̏ꍇ<CC8F>̃v<CC83><76><EFBFBD>Z<EFBFBD>b<EFBFBD>g<EFBFBD>l<EFBFBD><6C><EFBFBD>ݒ肷<DD92><E882B7><EFBFBD>B
|
||||
*/
|
||||
void NoMeiryoUI::OnSet10(void)
|
||||
{
|
||||
// DPI<50><49><EFBFBD>擾<EFBFBD><E693BE><EFBFBD><EFBFBD><EFBFBD>B
|
||||
int dpiY = getDPI();
|
||||
|
||||
// <20>t<EFBFBD>H<EFBFBD><48><EFBFBD>g<EFBFBD>ȊO<C88A><4F>NONCLIENTMETRICS<43>̌<EFBFBD><CC8C>ݒl<DD92><6C><EFBFBD>ێ<EFBFBD><DB8E><EFBFBD><EFBFBD>邽<EFBFBD>߁A
|
||||
// NONCLIENTMETRICS<43>̓<EFBFBD><CC93>e<EFBFBD><65><EFBFBD>擾<EFBFBD><E693BE><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>B
|
||||
FillMemory(&metrics, sizeof(NONCLIENTMETRICS), 0x00);
|
||||
@@ -1137,39 +1170,45 @@ void NoMeiryoUI::OnSet10(void)
|
||||
|
||||
memset(&metrics.lfCaptionFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfCaptionFont.lfFaceName, _T("Yu Gothic UI"));
|
||||
metrics.lfCaptionFont.lfHeight = -12;
|
||||
metrics.lfCaptionFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
metrics.lfCaptionFont.lfWeight = 400;
|
||||
metrics.lfCaptionFont.lfCharSet = 1;
|
||||
metrics.lfCaptionFont.lfQuality = 5;
|
||||
|
||||
memset(&iconFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(iconFont.lfFaceName, _T("Yu Gothic UI"));
|
||||
iconFont.lfHeight = -12;
|
||||
iconFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
iconFont.lfWeight = 400;
|
||||
iconFont.lfCharSet = 1;
|
||||
iconFont.lfQuality = 5;
|
||||
|
||||
memset(&metrics.lfSmCaptionFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfSmCaptionFont.lfFaceName, _T("Yu Gothic UI"));
|
||||
metrics.lfSmCaptionFont.lfHeight = -12;
|
||||
metrics.lfSmCaptionFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
metrics.lfSmCaptionFont.lfWeight = 400;
|
||||
metrics.lfSmCaptionFont.lfCharSet = 1;
|
||||
metrics.lfSmCaptionFont.lfQuality = 5;
|
||||
|
||||
memset(&metrics.lfStatusFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfStatusFont.lfFaceName, _T("Yu Gothic UI"));
|
||||
metrics.lfStatusFont.lfHeight = -12;
|
||||
metrics.lfStatusFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
metrics.lfStatusFont.lfWeight = 400;
|
||||
metrics.lfStatusFont.lfCharSet = 1;
|
||||
metrics.lfStatusFont.lfQuality = 5;
|
||||
|
||||
memset(&metrics.lfMessageFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfMessageFont.lfFaceName, _T("Yu Gothic UI"));
|
||||
metrics.lfMessageFont.lfHeight = -12;
|
||||
metrics.lfMessageFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
metrics.lfMessageFont.lfWeight = 400;
|
||||
metrics.lfMessageFont.lfCharSet = 1;
|
||||
metrics.lfMessageFont.lfQuality = 5;
|
||||
|
||||
memset(&metrics.lfMenuFont, 0, sizeof(LOGFONTW));
|
||||
_tcscpy(metrics.lfMenuFont.lfFaceName, _T("Yu Gothic UI"));
|
||||
metrics.lfMenuFont.lfHeight = -12;
|
||||
metrics.lfMenuFont.lfHeight = MulDiv(-12, dpiY, 96);
|
||||
metrics.lfMenuFont.lfWeight = 400;
|
||||
metrics.lfMenuFont.lfCharSet = 1;
|
||||
metrics.lfMenuFont.lfQuality = 5;
|
||||
|
||||
// <20>\<5C><><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>B
|
||||
updateDisplay();
|
||||
|
||||
@@ -1,25 +1,30 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
|
||||
<assemblyIdentity
|
||||
version="2.1.6.0"
|
||||
processorArchitecture="X86"
|
||||
name="TatsuhikoSyoji.noMeiryoUI.noMeiryoUI"
|
||||
type="win32"
|
||||
/>
|
||||
<description>noMeiryoUI set system fonts on Windows 8.x/10</description>
|
||||
<dependency>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity
|
||||
type="win32"
|
||||
name="Microsoft.Windows.Common-Controls"
|
||||
version="6.0.0.0"
|
||||
processorArchitecture="X86"
|
||||
publicKeyToken="6595b64144ccf1df"
|
||||
language="*"
|
||||
/>
|
||||
</dependentAssembly>
|
||||
</dependency>
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<assemblyIdentity
|
||||
version="2.1.6.2"
|
||||
processorArchitecture="X86"
|
||||
name="TatsuhikoSyoji.noMeiryoUI.noMeiryoUI"
|
||||
type="win32"
|
||||
/>
|
||||
<description>noMeiryoUI set system fonts on Windows 8.x/10</description>
|
||||
<dependency>
|
||||
<dependentAssembly>
|
||||
<assemblyIdentity
|
||||
type="win32"
|
||||
name="Microsoft.Windows.Common-Controls"
|
||||
version="6.0.0.0"
|
||||
processorArchitecture="X86"
|
||||
publicKeyToken="6595b64144ccf1df"
|
||||
language="*"
|
||||
/>
|
||||
</dependentAssembly>
|
||||
</dependency>
|
||||
<asmv3:application xmlns:asmv3="urn:schemas-microsoft-com:asm.v3">
|
||||
<asmv3:windowsSettings xmlns="http://schemas.microsoft.com/SMI/2005/WindowsSettings">
|
||||
<dpiAware>True</dpiAware>
|
||||
</asmv3:windowsSettings>
|
||||
</asmv3:application>
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<application>
|
||||
<!-- Windows 10 -->
|
||||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>
|
||||
@@ -32,5 +37,5 @@
|
||||
<!--Windows Vista-->
|
||||
<supportedOS Id="{e2011457-1546-43c5-a5fe-008deee3d3f0}" />
|
||||
</application>
|
||||
</compatibility>
|
||||
</compatibility>
|
||||
</assembly>
|
||||
|
||||
@@ -54,6 +54,7 @@ private:
|
||||
void OnSet8();
|
||||
void OnSet10(void);
|
||||
void SetWinVer();
|
||||
int getDPI(void);
|
||||
|
||||
void setFont(
|
||||
NONCLIENTMETRICS *fontMetrics,
|
||||
|
||||
@@ -57,7 +57,7 @@ CAPTION "Meiryo UI
|
||||
MENU IDR_MENU1
|
||||
FONT 10, "<22>l<EFBFBD>r <20>o<EFBFBD>S<EFBFBD>V<EFBFBD>b<EFBFBD>N", 400, 0, 0x80
|
||||
BEGIN
|
||||
LTEXT "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!! Version 2.16 Beta1",IDC_STATIC,7,7,138,8,SS_NOPREFIX
|
||||
LTEXT "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!! Version 2.16",IDC_STATIC,7,7,138,8,SS_NOPREFIX
|
||||
RTEXT "Copyright (C) Tatsu 2005,2012-2015",IDC_STATIC,161,7,137,8
|
||||
LTEXT "<22><><EFBFBD>ׂẴt<CC83>H<EFBFBD><48><EFBFBD>g",IDC_STATIC,7,37,89,12
|
||||
EDITTEXT IDC_EDIT_ALL,102,37,91,12,ES_AUTOHSCROLL | ES_READONLY
|
||||
@@ -171,8 +171,8 @@ END
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 2,1,6,0
|
||||
PRODUCTVERSION 2,1,6,0
|
||||
FILEVERSION 2,1,6,2
|
||||
PRODUCTVERSION 2,1,6,2
|
||||
FILEFLAGSMASK 0x17L
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
@@ -189,12 +189,12 @@ BEGIN
|
||||
BEGIN
|
||||
VALUE "CompanyName", "T.Syoji's Personal Development"
|
||||
VALUE "FileDescription", "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!!"
|
||||
VALUE "FileVersion", "2.1.6.0"
|
||||
VALUE "FileVersion", "2.1.6.2"
|
||||
VALUE "InternalName", "noMeiryo"
|
||||
VALUE "LegalCopyright", "Copyright (C) Tatsuhiko Syoji 2005,2012-2015"
|
||||
VALUE "OriginalFilename", "noMeiryoUI.exe"
|
||||
VALUE "ProductName", "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!!"
|
||||
VALUE "ProductVersion", "2.1.6.0"
|
||||
VALUE "ProductVersion", "2.1.6.2"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
|
||||
@@ -224,7 +224,9 @@
|
||||
<ResourceCompile Include="noMeiryoUI.rc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Manifest Include="noMeiryoUI.exe.manifest" />
|
||||
<Manifest Include="noMeiryoUI.exe.manifest">
|
||||
<SubType>Designer</SubType>
|
||||
</Manifest>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Text Include="ReadMe.txt" />
|
||||
|
||||
2
util.cpp
2
util.cpp
@@ -21,7 +21,7 @@ int getFontPointInt(LOGFONT *font, HWND hWnd)
|
||||
|
||||
if (WIN8_SIZE) {
|
||||
// Windows 8<>f<EFBFBD>B<EFBFBD>X<EFBFBD>v<EFBFBD><76><EFBFBD>C<EFBFBD>R<EFBFBD><52><EFBFBD>g<EFBFBD><67><EFBFBD>[<5B><><EFBFBD>p<EFBFBD>l<EFBFBD><6C><EFBFBD>݊<EFBFBD>
|
||||
if (point > 10) {
|
||||
if ((point > 10) || (point < 8)) {
|
||||
return (int)point;
|
||||
} else {
|
||||
// 10pt<70>܂ł<DC82>Windows 7<>Ɠ<EFBFBD><C693>l<EFBFBD>Ɍv<C98C>Z<EFBFBD><5A><EFBFBD><EFBFBD><EFBFBD>B
|
||||
|
||||
Reference in New Issue
Block a user