How can I detect Windows 10 light/dark mode?

后端 未结 6 556
情话喂你
情话喂你 2020-12-03 15:12

I\'m using Windows.UI.ViewManagement.UISettings to get system accent color but it seems this class does not have any method or property for light/dark mode. I f

6条回答
  •  眼角桃花
    2020-12-03 15:50

    If you want to get the Value in PowerShell you can use the following code:

    (New-Object Windows.UI.ViewManagement.UISettings).GetColorValue("background")
    

提交回复
热议问题