某些应用程序无法显示在 Ubuntu 16.04 上的面板中

某些应用程序无法显示在 Ubuntu 16.04 上的面板中

Nautilus、gedit、gvim、LibreOffice、Audacious 和 gimp 没有应用程序菜单,所以我找不到文件、编辑等。但 Google Brower、Firefox 和 Okular 可以。

无菜单栏显示:

在此处输入图片描述

已显示菜单栏:

在此处输入图片描述

我执行该命令时sudo service lightdm restart,这些应用程序都正常显示,我把该命令写入/etc/rc.local~/.profile,但是没用。

我安装 gvim 后就出现了这个问题。
我执行这些命令来安装 gvim:

tar xvf vim-7.4.tar.bz2
cd  ./vim74/src
sudo apt-get install libncurses5-dev  
sudo apt-get install libgnome2-dev libgnomeui-dev libgtk2.0-dev libatk1.0-dev libbonoboui2-dev libcairo2-dev libx11-dev libxpm-dev libxt-dev 
./configure --enable-gui=gtk2 --prefix=/home/pmsl/DeveloperTools/Vim
make
sudo make install

我尝试重新安装 ubuntu-desktop、unity、lightdm 并删除 libncurses5-dev、libgnome2-dev、libgnomeui-dev、libgtk2.0-dev、libatk1.0-dev、libbonoboui2-dev、libcairo2-dev、libx11-dev、libxpm-dev 和 libxt-dev。

我无法找到问题/var/log/lightdm/lightdm.log

开机lightdm.log:

[+0.03s] DEBUG: Logging to /var/log/lightdm/lightdm.log
[+0.26s] DEBUG: Starting Light Display Manager 1.18.1, UID=0 PID=1106
[+0.26s] DEBUG: Loading configuration dirs from /usr/share/lightdm/lightdm.conf.d
[+0.26s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-disable-log-backup.conf
[+0.26s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-greeter-wrapper.conf
[+0.26s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-guest-wrapper.conf
[+0.26s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-no-guest.conf
[+0.26s] DEBUG:   [SeatDefaults] is now called [Seat:*], please update this configuration
[+0.26s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf
[+0.26s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-unity-greeter.conf
[+0.26s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-xserver-command.conf
[+0.26s] DEBUG: Loading configuration dirs from /usr/local/share/lightdm/lightdm.conf.d
[+0.26s] DEBUG: Loading configuration dirs from /etc/xdg/lightdm/lightdm.conf.d
[+0.26s] DEBUG: Loading configuration from /etc/lightdm/lightdm.conf
[+0.26s] DEBUG: Using D-Bus name org.freedesktop.DisplayManager
[+0.26s] DEBUG: Registered seat module xlocal
[+0.26s] DEBUG: Registered seat module xremote
[+0.26s] DEBUG: Registered seat module unity
[+0.27s] DEBUG: Monitoring logind for seats
[+0.27s] DEBUG: New seat added from logind: seat0
[+0.27s] DEBUG: Seat seat0: Loading properties from config section Seat:*
[+0.27s] DEBUG: Seat seat0: Starting
[+0.27s] DEBUG: Seat seat0: Creating user session
[+0.27s] DEBUG: Loading users from org.freedesktop.Accounts
[+0.27s] DEBUG: User /org/freedesktop/Accounts/User1000 added
[+0.97s] DEBUG: Seat seat0: Creating display server of type x

[+0.98s] DEBUG: Seat seat0: Plymouth is running on VT 1, but this is less than the configured minimum of 7 so not replacing it
[+0.98s] DEBUG: Quitting Plymouth

[+1.02s] DEBUG: Using VT 7
[+1.02s] DEBUG: Seat seat0: Starting local X display on VT 7
[+1.02s] DEBUG: DisplayServer x-0: Logging to /var/log/lightdm/x-0.log
[+1.02s] DEBUG: DisplayServer x-0: Writing X server authority to /var/run/lightdm/root/:0
[+1.02s] DEBUG: DisplayServer x-0: Launching X Server
[+1.02s] DEBUG: Launching process 1215: /usr/bin/X -core :0 -seat seat0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
[+1.02s] DEBUG: DisplayServer x-0: Waiting for ready signal from X server :0
[+1.02s] DEBUG: Acquired bus name org.freedesktop.DisplayManager
[+1.02s] DEBUG: Registering seat with bus path /org/freedesktop/DisplayManager/Seat0
[+2.65s] DEBUG: Got signal 10 from process 1215
[+2.65s] DEBUG: DisplayServer x-0: Got signal from X server :0
[+2.65s] 
[Thread 0x7fffc3eef700 (LWP 5295) exited]DEBUG: DisplayServer x-0: Connecting to XServer :0
[+2.66s] DEBUG: Seat seat0: Display server ready, starting session authentication
[+2.66s] DEBUG: Session pid=1442: Started with service 'lightdm-autologin', username 'pmsl'
[+2.70s] DEBUG: Session pid=1442: Authentication complete with return value 0: Success
[+2.70s] DEBUG: Seat seat0: Session authenticated, running command
[+2.70s] 
[Thread 0x7fffc3eef700 (LWP 5295) exited]DEBUG: Registering session with bus path /org/freedesktop/DisplayManager/Session0
[+2.70s] DEBUG: Session pid=1442: Running command /usr/sbin/lightdm-session gnome-session --session=ubuntu
[+2.70s] DEBUG: Creating shared data directory /var/lib/lightdm-data/pmsl
[+2.70s] DEBUG: Session pid=1442: Logging to .xsession-errors
[+2.84s] DEBUG: Activating VT 7
[+2.84s] DEBUG: Activating login1 session c1
[+2.84s] DEBUG: Seat seat0 changes active session to c1
[+2.84s] DEBUG: Session c1 is already active

重新启动服务lightdm.log:

[+0.00s] DEBUG: Logging to /var/log/lightdm/lightdm.log
[+0.00s] DEBUG: Starting Light Display Manager 1.18.1, UID=0 PID=3548
[+0.00s] DEBUG: Loading configuration dirs from /usr/share/lightdm/lightdm.conf.d
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-disable-log-backup.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-greeter-wrapper.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-guest-wrapper.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-no-guest.conf
[+0.00s] DEBUG:   [SeatDefaults] is now called [Seat:*], please update this configuration
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-unity-greeter.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-xserver-command.conf
[+0.00s] DEBUG: Loading configuration dirs from /usr/local/share/lightdm/lightdm.conf.d
[+0.00s] DEBUG: Loading configuration dirs from /etc/xdg/lightdm/lightdm.conf.d
[+0.00s] DEBUG: Loading configuration from /etc/lightdm/lightdm.conf
[+0.00s] DEBUG: Using D-Bus name org.freedesktop.DisplayManager
[+0.00s] DEBUG: Registered seat module xlocal
[+0.00s] DEBUG: Registered seat module xremote
[+0.00s] DEBUG: Registered seat module unity
[+0.01s] DEBUG: Monitoring logind for seats
[+0.01s] DEBUG: New seat added from logind: seat0
[+0.01s] DEBUG: Seat seat0: Loading properties from config section Seat:*
[+0.01s] DEBUG: Seat seat0: Starting
[+0.01s] DEBUG: Seat seat0: Creating user session
[+0.01s] DEBUG: Loading users from org.freedesktop.Accounts
[+0.01s] DEBUG: User /org/freedesktop/Accounts/User1000 added
[+0.01s] DEBUG: Seat seat0: Creating display server of type x
[+0.02s] DEBUG: Using VT 7
[+0.02s] DEBUG: Seat seat0: Starting local X display on VT 7
[+0.02s] DEBUG: DisplayServer x-0: Logging to /var/log/lightdm/x-0.log
[+0.02s] DEBUG: DisplayServer x-0: Writing X server authority to /var/run/lightdm/root/:0
[+0.02s] DEBUG: DisplayServer x-0: Launching X Server
[+0.02s] DEBUG: Launching process 3554: /usr/bin/X -core :0 -seat seat0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
[+0.02s] DEBUG: DisplayServer x-0: Waiting for ready signal from X server :0
[+0.02s] DEBUG: Acquired bus name org.freedesktop.DisplayManager
[+0.02s] DEBUG: Registering seat with bus path /org/freedesktop/DisplayManager/Seat0
[+0.26s] DEBUG: Got signal 10 from process 3554
[+0.26s] DEBUG: DisplayServer x-0: Got signal from X server :0
[+0.26s] DEBUG: DisplayServer x-0: Connecting to XServer :0
[+0.26s] DEBUG: Seat seat0: Display server ready, starting session authentication
[+0.26s] DEBUG: Session pid=3565: Started with service 'lightdm-autologin', username 'pmsl'
[+0.27s] DEBUG: Session pid=3565: Authentication complete with return value 0: Success
[+0.27s] DEBUG: Seat seat0: Session authenticated, running command
[+0.27s] DEBUG: Registering session with bus path /org/freedesktop/DisplayManager/Session0
[+0.27s] DEBUG: Session pid=3565: Running command /usr/sbin/lightdm-session gnome-session --session=ubuntu
[+0.27s] DEBUG: Creating shared data directory /var/lib/lightdm-data/pmsl
[+0.27s] 
[Thread 0x7fffc3eef700 (LWP 5295) exited]DEBUG: Session pid=3565: Logging to .xsession-errors
[+0.29s] DEBUG: Activating VT 7
[+0.29s] DEBUG: Activating login1 session c2
[+0.29s] DEBUG: Seat seat0 changes active session to c2
[+0.29s] DEBUG: Session c2 is already active

我不喜欢在启动计算机时手动执行命令“sudo service lightdm restart”。

[Thread 0x7fffc3eef700 (LWP 5295) exited]

答案1

暂时,您可以尝试将菜单栏移动到应用程序窗口: http://www.linuxandubuntu.com/home/10-things-to-do-after-installing-ubuntu-16-04-xenial-xerus

请参阅“(ii)在窗口标题栏中显示菜单”下的说明。

注销,登录——对我有用!

欢呼吧,蒂洛

答案2

我选择将菜单栏放在应用程序窗口中,并使其始终可见。在我的设置下,我遇到了同样的问题,但有一个区别:我有两个不同的变体。要么应用程序(例如 LibreOffice)完全没有菜单栏,要么应用程序(例如 gnome-terminal)的菜单栏翻倍。这两个问题在重新启动后立即出现,如果我注销并重新登录,它们就会消失。也就是说,完全不需要调整任何设置或运行任何命令;简单的注销-登录就可以解决问题。好吧,对于大多数应用程序来说——有些应用程序仍然偶尔会将其菜单栏翻倍。

我希望有人能告诉我我可以将我的错误报告指向系统的哪个部分,因为现在,我不知道哪个组件可能导致了这个问题。

答案3

正如在其他论坛中发布的那样(不能承担责任),打开命令窗口并输入以下命令:

重新启动 unity-panel-service

这对我来说是有效的 - 至少直到找到更永久的解决办法为止。

相关内容