你好,我尝试将一些快捷列表添加到 unity 启动器,我将一些快捷列表添加到 gnome-terminal,它们工作正常,我将一些快捷列表添加到 nautilus-home,但无法让它们显示,这是我的 .desktop 文件
[Desktop Entry]
Name=Home Folder
Comment=Open your personal folder
TryExec=nautilus
Exec=nautilus --no-desktop
Icon=user-home
Terminal=false
StartupNotify=true
Type=Application
Categories=GNOME;GTK;Core;
OnlyShowIn=GNOME;Unity
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=nautilus
X-GNOME-Bugzilla-Component=general
X-Ubuntu-Gettext-Domain=nautilus
X-Ayatana-Desktop-Shortcuts=bin;Documents;Downloads;Pictures;Video;Music;Ubuntu One;src;
[bin Desktop Shortcut Group]
Name=bin
Exec=nautilus bin
TargetEnvironment=Unity
[Documents Desktop Shortcut Group]
Name=Documents
Exec=nautilus Documents
TargetEnvironment=Unity
[Downloads Desktop Shortcut Group]
Name=Downloads
Exec=nautilus Downloads
TargetEnvironment=Unity
[Pictures Desktop Shortcut Group]
Name=Pictures
Exec=nautilus Pictures
TargetEnvironment=Unity
[Video Desktop Shortcut Group]
Name=Video
Exec=nautilus Video
TargetEnvironment=Unity
[Music Desktop Shortcut Group]
Name=Music
Exec=nautilus Music
TargetEnvironment=Unity
[Ubuntu One Desktop Shortcut Group]
Name=Ubuntu One
Exec=nautilus Ubuntu\ One
TargetEnvironment=Unity
[src Desktop Shortcut Group]
Name=src
Exec=nautilus src
TargetEnvironment=Unity
答案1
有几个错误——这里是建议的修改:
[Desktop Entry]
Name=Home Folder
Comment=Open your personal folder
TryExec=nautilus
Exec=nautilus --no-desktop
Icon=user-home
Terminal=false
StartupNotify=true
Type=Application
Categories=GNOME;GTK;Core;
OnlyShowIn=GNOME;Unity
X-GNOME-Bugzilla-Bugzilla=GNOME
X-GNOME-Bugzilla-Product=nautilus
X-GNOME-Bugzilla-Component=general
X-Ubuntu-Gettext-Domain=nautilus
X-Ayatana-Desktop-Shortcuts=bin;Documents;Downloads;Pictures;Video;Music;UbuntuOne;src;
[bin Shortcut Group]
Name=bin
Exec=nautilus bin
TargetEnvironment=Unity
[Documents Shortcut Group]
Name=Documents
Exec=nautilus Documents
TargetEnvironment=Unity
[Downloads Shortcut Group]
Name=Downloads
Exec=nautilus Downloads
TargetEnvironment=Unity
[Pictures Shortcut Group]
Name=Pictures
Exec=nautilus Pictures
TargetEnvironment=Unity
[Video Shortcut Group]
Name=Video
Exec=nautilus Video
TargetEnvironment=Unity
[Music Shortcut Group]
Name=Music
Exec=nautilus Music
TargetEnvironment=Unity
[UbuntuOne Shortcut Group]
Name=Ubuntu One
Exec=nautilus "Ubuntu One"
TargetEnvironment=Unity
[src Shortcut Group]
Name=src
Exec=nautilus src
TargetEnvironment=Unity
建议的更改:
- 组名(方括号之间的位)不能有空格
- 我引用了“Ubuntu One”——不确定是否有必要,但这样更容易阅读。
答案2
两件事情,
您的“bin”条目中的“T”和“arget ...”之间有一个标签。
我可能错了,但我认为快捷方式组条目不能有空格。尝试在属性中将“Ubuntu One”改为“UbuntuOne”
X-Ayatana-Desktop-Shortcuts
,并将相应条目更改为
[Ubuntu One Desktop Shortcut Group]
Name=Ubuntu One
Exec=nautilus Ubuntu\ One
TargetEnvironment=Unity
编辑:您的文件开头还有一个选项卡,这可能会带来问题。