我们看到的文件夹名,不一定是文件夹的实际名
比如我们看到的图片文件夹,实际文件夹名是Pictures
因为desktop.ini的存在,我们看到的文件夹名是图片
[.ShellClassInfo]
LocalizedResourceName=@%SystemRoot%\system32\shell32.dll,-21779
InfoTip=@%SystemRoot%\system32\shell32.dll,-12688
IconResource=%SystemRoot%\system32\imageres.dll,-113
IconFile=%SystemRoot%\system32\shell32.dll
IconIndex=-236
那么如何定义desktop.ini呢?我们以下载文件夹为例,注意文本编码是GB2312
[.ShellClassInfo]
IconIndex=0
IconFile=C:\Program Files (x86)\Thunder Network\Thunder\Program\downloadfolder.ico
InfoTip=下载文件夹
LocalizedResourceName=下载
由于编辑此文件需要的权限很高,建议使用vscode编辑,保存时会跳出覆盖保存
我们可以创建个info.ini,右键-更改默认程序-选择vscode
在文件夹的路径处拼接desktop.ini便可使用vscode编辑了
更改后快速访问刷新:取消固定到快速访问-重启-固定到快速访问
以下是Win10默认的配置
下载:
[.ShellClassInfo]
LocalizedResourceName=@%SystemRoot%\system32\shell32.dll,-21798
IconResource=%SystemRoot%\system32\imageres.dll,-184
文档:
[.ShellClassInfo]
LocalizedResourceName=@%SystemRoot%\system32\shell32.dll,-21770
IconResource=%SystemRoot%\system32\imageres.dll,-112
IconFile=%SystemRoot%\system32\shell32.dll
IconIndex=-235
图片:
[.ShellClassInfo]
LocalizedResourceName=@%SystemRoot%\system32\shell32.dll,-21779
InfoTip=@%SystemRoot%\system32\shell32.dll,-12688
IconResource=%SystemRoot%\system32\imageres.dll,-113
IconFile=%SystemRoot%\system32\shell32.dll
IconIndex=-236
视频:
[.ShellClassInfo]
LocalizedResourceName=@%SystemRoot%\system32\shell32.dll,-21791
InfoTip=@%SystemRoot%\system32\shell32.dll,-12690
IconResource=%SystemRoot%\system32\imageres.dll,-189
IconFile=%SystemRoot%\system32\shell32.dll
IconIndex=-238
音乐:
[.ShellClassInfo]
LocalizedResourceName=@%SystemRoot%\system32\shell32.dll,-21790
InfoTip=@%SystemRoot%\system32\shell32.dll,-12689
IconResource=%SystemRoot%\system32\imageres.dll,-108
IconFile=%SystemRoot%\system32\shell32.dll
IconIndex=-237
桌面:
[.ShellClassInfo]
LocalizedResourceName=@%SystemRoot%\system32\shell32.dll,-21769
IconResource=%SystemRoot%\system32\imageres.dll,-183