Windows10开启透明磁贴


张登友,张登友的博客,张登友的网站——

如何开启新版菜单

如何立即启用Windows 10 20H2开始菜单

更改完成的效果

系统要求

首先需要更新系统至指定版本

用于Windows 10 2004的可选更新KB4568831(即2020年5月更新)已经发布了新“开始”菜单的代码。为了激活新的“开始”菜单,Microsoft计划发布一个小的“功能包”,但是您可以通过简单的注册表编辑来自己激活它。

WindowsLatest具有以下说明,如果您已经在Windows 10 May 2020中更新,那么它就变得相对简单。
测试版本,win10 20h2,在https://next.itellyou.cn/Original/Index#cbp=Product?ID=f905b2d9-11e7-4ee3-8b52-407a8befe8d1下载,直接打开加载,覆盖安装即可

版本 Windows 10 专业版
安装日期 ‎2020/‎10/‎4
操作系统版本 19041.508
体验 Windows Feature Experience Pack 120.2212.31.0

如何启用WINDOWS 10 20H2开始菜单

1、通过在开始菜单中搜索“还原点”并按照向导进行操作来创建还原点。
2、检查更新并安装可选更新KB4568831。

3、打开记事本。
4、将以下内容粘贴到记事本中:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FeatureManagement\Overrides\0\2093230218]
"EnabledState"=dword:00000002
"EnabledStateOptions"=dword:00000000

5、将记事本文件另存为20H2.reg
6、运行20H2.reg并应用注册表更改。
7、重新启动系统。
现在,您应该看到新的开始菜单,并且还获得了新的Alt-Tab体验(包括Microsoft Edge的选项卡)和文件夹的新图标。

注册表编辑和破解当然需要您自担风险。

一键提取聚焦壁纸

提取win10聚焦壁纸代码

所需要的的代码,复制到文本编辑器然后保存,更名为SetWallPaperFromSpotlight.ps1

# 将复制出来的缓存图片保存在下面的文件夹
add-type -AssemblyName System.Drawing
New-Item "$($env:USERPROFILE)\Pictures\Spotlight" -ItemType directory -Force;
New-Item "$($env:USERPROFILE)\Pictures\Spotlight\CopyAssets" -ItemType directory -Force;
New-Item "$($env:USERPROFILE)\Pictures\Spotlight\Horizontal" -ItemType directory -Force;
New-Item "$($env:USERPROFILE)\Pictures\Spotlight\Vertical" -ItemType directory -Force;
 
# 将横竖图片分别复制到对应的两个文件夹
foreach($file in (Get-Item "$($env:LOCALAPPDATA)\Packages\Microsoft.Windows.ContentDeliveryManager_cw5n1h2txyewy\LocalState\Assets\*"))
{
    if ((Get-Item $file).length -lt 100kb) { continue }
    Copy-Item $file.FullName "$($env:USERPROFILE)\Pictures\Spotlight\CopyAssets\$($file.Name).jpg";
}
 
foreach($newfile in (Get-Item "$($env:USERPROFILE)\Pictures\Spotlight\CopyAssets\*"))
{
    $image = New-Object -comObject WIA.ImageFile;
    $image.LoadFile($newfile.FullName);
    if($image.Width.ToString() -eq "1920"){ Move-Item $newfile.FullName "$($env:USERPROFILE)\Pictures\Spotlight\Horizontal" -Force; }
    elseif($image.Width.ToString() -eq "1080"){ Move-Item $newfile.FullName "$($env:USERPROFILE)\Pictures\Spotlight\Vertical" -Force; }
}
 
# 壁纸设置函数
function Set-Wallpaper
{
    param(
        [Parameter(Mandatory=$true)]
        $Path,
 
        [ValidateSet('Center', 'Stretch')]
        $Style = 'Center'
    )
 
    Add-Type @"
using System;
using System.Runtime.InteropServices;
using Microsoft.Win32;
namespace Wallpaper
{
public enum Style : int
{
Center, Stretch
}
public class Setter {
public const int SetDesktopWallpaper = 20;
public const int UpdateIniFile = 0x01;
public const int SendWinIniChange = 0x02;
[DllImport("user32.dll", SetLastError = true, CharSet = CharSet.Auto)]
private static extern int SystemParametersInfo (int uAction, int uParam, string lpvParam, int fuWinIni);
public static void SetWallpaper ( string path, Wallpaper.Style style ) {
SystemParametersInfo( SetDesktopWallpaper, 0, path, UpdateIniFile | SendWinIniChange );
RegistryKey key = Registry.CurrentUser.OpenSubKey("Control Panel\\Desktop", true);
switch( style )
{
case Style.Stretch :
key.SetValue(@"WallpaperStyle", "2") ;
key.SetValue(@"TileWallpaper", "0") ;
break;
case Style.Center :
key.SetValue(@"WallpaperStyle", "1") ;
key.SetValue(@"TileWallpaper", "0") ;
break;
}
key.Close();
}
}
}
"@
 
    [Wallpaper.Setter]::SetWallpaper( $Path, $Style )
}
 
 
$filePath = "$($env:USERPROFILE)\Pictures\Spotlight\Horizontal\*"
$file = Get-Item -Path $filePath | Sort-Object -Property LastWriteTime -Descending | Select-Object -First 1
Set-Wallpaper -Path $file.FullName  
# echo $file.FullName
 
Remove-Item "$($env:USERPROFILE)\Pictures\Spotlight\CopyAssets\*";
#pause

然后右键使用powershell运行,图解:

powershell命令运行后,提取后文件夹所在位置为:C:\Users\你的用户名\Pictures\Spotlight下的Horizontal(横屏壁纸,适合电脑)和Vertical(竖屏壁纸,适合手机)文件夹下


文章作者: 张登友
版权声明: 本博客所有文章除特別声明外,均采用 CC BY 4.0 许可协议。转载请注明来源 张登友 !
  目录