Use Segoe Fluent Icons font for modern settings icons on Win11

It seems that Windows 11 prefers `Segoe Fluent Icons` over `Segoe MDL2 Assets` font.
https://learn.microsoft.com/en-us/windows/apps/design/style/segoe-fluent-icons-font

Most of settings defined in `AllSystemSettings_{253E530E-387D-4BC2-959D-E6F86122E5F2}.xml` now refer to the new font.
This commit is contained in:
ge0rdi
2022-12-03 11:46:28 +01:00
parent 77d2d3a01d
commit 0465ac9c1b

View File

@@ -9,6 +9,7 @@
#include "stdafx.h"
#include "ModernSettings.h"
#include "ModernSettingsShellFolder.h"
#include "ResourceHelper.h"
#include <propkey.h>
#include <strsafe.h>
#include <Uxtheme.h>
@@ -181,7 +182,7 @@ HICON IconFromGlyph(UINT glyph, UINT size)
HDC dc = CreateCompatibleDC(nullptr);
SelectObject(dc, info.hbmColor);
HFONT font = CreateFontW(size, 0, 0, 0, 400, 0, 0, 0, 1, 0, 0, 0, 0, L"Segoe MDL2 Assets");
HFONT font = CreateFontW(size, 0, 0, 0, 400, 0, 0, 0, 1, 0, 0, 0, 0, IsWin11() ? L"Segoe Fluent Icons" : L"Segoe MDL2 Assets");
SelectObject(dc, font);
RECT rc{};