Ubuntu 16.06 带有普通桌面(据我所知,Unity 和 gnome)。
这是我的桌面文件。我尝试了很多不同的方法,比如%u
在 exec 文件末尾添加一个。但都不起作用。现在请记住,如果我打开终端并输入/usr/lib/firefox/firefox
它,则肯定会启动 Firefox。
[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
NoDisplay=true
Exec=/usr/lib/firefox/firefox
Name=Firefox
Comment=Firefox newset version
Icon=/usr/lib/firefox/browser/chrome/icons/default/default128.png
Terminal=false
当我执行以下任一操作时,会发生以下情况compiz --replace
:
compiz (core) - Info: Loading plugin: unityshell
compiz (core) - Info: Starting plugin: unityshell
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:131 Unable to load desktop file: /home/joe/Desktop/firefox.desktop
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:144 Unable to load Favorite for uri 'application:///home/joe/Desktop/firefox.desktop'
WARN 2018-03-19 20:02:55 unity.glib.dbus.server GLibDBusServer.cpp:593 Can't register object 'org.gnome.Shell' yet as we don't have a connection, waiting for it...
WARN 2018-03-19 20:02:55 unity.debug.interface DebugDBusInterface.cpp:217 Unable to load entry point in libxpathselect: libxpathselect.so.1.4: cannot open shared object file: No such file or directory -- full D-Bus introspection will not be available
WARN 2018-03-19 20:02:55 xim.controller XIMController.cpp:103 IBus natively supported.
WARN 2018-03-19 20:02:55 unity.dash.gsettingsscopereader GSettingsScopes.cpp:108 Error fetching protocol metadata for scope: social.scope : Valid key file could not be found in search dirs
WARN 2018-03-19 20:02:55 unity.glib.dbus.server GLibDBusServer.cpp:593 Can't register object 'com.canonical.Unity.Launcher' yet as we don't have a connection, waiting for it...
WARN 2018-03-19 20:02:55 unity.glib.dbus.server GLibDBusServer.cpp:593 Can't register object 'com.canonical.Unity.Dash' yet as we don't have a connection, waiting for it...
WARN 2018-03-19 20:02:55 unity.glib.dbus.server GLibDBusServer.cpp:593 Can't register object 'org.gnome.SessionManager.EndSessionDialog' yet as we don't have a connection, waiting for it...
WARN 2018-03-19 20:02:55 unity.glib.dbus.server GLibDBusServer.cpp:593 Can't register object 'com.canonical.Unity.Session' yet as we don't have a connection, waiting for it...
WARN 2018-03-19 20:02:55 unity.glib.dbus.server GLibDBusServer.cpp:593 Can't register object 'org.gnome.ScreenSaver' yet as we don't have a connection, waiting for it...
WARN 2018-03-19 20:02:55 unityo (appinfo2) <unknown>:0 g_settings_set_value: value for key 'visual-bell-type' in schema 'org.gnome.desktop.wm.preferences' is outside of valid range
WARN 2018-03-19 20:02:55 unityo (appinfo2) <unknown>:0 g_settings_set_value: value for key 'visual-bell-type' in schema 'org.gnome.desktop.wm.preferences' is outside of valid range
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:131 Unable to load desktop file: /home/joe/Desktop/firefox.desktop
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:144 Unable to load Favorite for uri 'application:///home/joe/Desktop/firefox.desktop'
WARN 2018-03-19 20:02:55 unityo (appinfo2) <unknown>:0 g_settings_set_value: value for key 'visual-bell-type' in schema 'org.gnome.desktop.wm.preferences' is outside of valid range
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:131 Unable to load desktop file: /home/joe/Desktop/firefox.desktop
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:144 Unable to load Favorite for uri 'application:///home/joe/Desktop/firefox.desktop'
WARN 2018-03-19 20:02:55 unityo (appinfo2) <unknown>:0 g_settings_set_value: value for key 'visual-bell-type' in schema 'org.gnome.desktop.wm.preferences' is outside of valid range
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:131 Unable to load desktop file: /home/joe/Desktop/firefox.desktop
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:144 Unable to load Favorite for uri 'application:///home/joe/Desktop/firefox.desktop'
WARN 2018-03-19 20:02:55 unityo (appinfo2) <unknown>:0 g_settings_set_value: value for key 'visual-bell-type' in schema 'org.gnome.desktop.wm.preferences' is outside of valid range
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:131 Unable to load desktop file: /home/joe/Desktop/firefox.desktop
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:144 Unable to load Favorite for uri 'application:///home/joe/Desktop/firefox.desktop'
WARN 2018-03-19 20:02:55 unityo (appinfo2) <unknown>:0 g_settings_set_value: value for key 'visual-bell-type' in schema 'org.gnome.desktop.wm.preferences' is outside of valid range
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:131 Unable to load desktop file: /home/joe/Desktop/firefox.desktop
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:144 Unable to load Favorite for uri 'application:///home/joe/Desktop/firefox.desktop'
WARN 2018-03-19 20:02:55 unityo (appinfo2) <unknown>:0 g_settings_set_value: value for key 'visual-bell-type' in schema 'org.gnome.desktop.wm.preferences' is outside of valid range
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:131 Unable to load desktop file: /home/joe/Desktop/firefox.desktop
WARN 2018-03-19 20:02:55 unity.favorite.store FavoriteStore.cpp:144 Unable to load Favorite for uri 'application:///home/joe/Desktop/firefox.desktop'
ERROR 2018-03-19 20:02:55 unity.glib.dbus.server GLibDBusServer.cpp:538 DBus name lost 'org.gnome.Shell'
ERROR 2018-03-19 20:02:55 unity.glib.dbus.server GLibDBusServer.cpp:538 DBus name lost 'com.canonical.Unity'
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
WARN 2018-03-19 20:02:55 unity.key.gnome.grabber GnomeKeyGrabber.cpp:108 Trying to grab a disabled action, we skip it
(soffice:2790): Gdk-WARNING **: gdk_window_set_icon_list: icons too large
(soffice:2790): Gdk-WARNING **: gdk_window_set_icon_list: icons too large
WARN 2018-03-19 20:06:24 unity.launcher.icon LauncherIcon.cpp:413 Unable to load 'firefox' from icon theme: Error opening file: No such file or directory
WARN 2018-03-19 20:06:24 unity.launcher.icon LauncherIcon.cpp:413 Unable to load 'firefox' from icon theme: Error opening file: No such file or directory
WARN 2018-03-19 20:06:24 unity.launcher.icon LauncherIcon.cpp:413 Unable to load 'firefox' from icon theme: Error opening file: No such file or directory
答案1
Firefox 运行时,其图标应出现在左侧面板中。只需右键单击该图标并选择将其锁定到位的选项。然后它将始终可用。