我在Ubuntu Desktop 16.04 LTS上,gvim
(使用图形用户界面的vim)在尝试使用GUI /菜单打开任何文件时一直崩溃。但是,我可以从终端打开文件,例如:
user@computer:~$ vim -g ./path/to/file
如果我gvim
使用以下命令从终端启动,则会将以下错误消息打印到终端vim -g
,然后尝试通过GUI /菜单栏打开文件,从而导致崩溃:
(gvim:20175): GLib-CRITICAL **: g_ptr_array_insert: assertion 'index_ <= (gint)rarray->len' failed
** (gvim:20175): CRITICAL **: unity_gtk_menu_shell_get_item: assertion '0 <= index && index < items->len' failed
** (gvim:20175): CRITICAL **: unity_gtk_menu_item_get_child_shell: assertion 'UNITY_GTK_IS_MENU_ITEM (item)' failed
** (gvim:20175): CRITICAL **: unity_gtk_menu_shell_get_item: assertion '0 <= index && index < items->len' failed
** (gvim:20175): CRITICAL **: unity_gtk_menu_item_get_label: assertion 'UNITY_GTK_IS_MENU_ITEM (item)' failed
** (gvim:20175): CRITICAL **: unity_gtk_menu_item_get_icon: assertion 'UNITY_GTK_IS_MENU_ITEM (item)' failed
Vim: Caught deadly signal SEGV
Vim: Finished.
这些是我安装的与vim相关的软件包:
user@computer:~$ apt list --installed | grep vim
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
vim-common/xenial-updates,now 2:7.4.1689-3ubuntu1.1 amd64 [installed]
vim-gtk3/xenial-updates,now 2:7.4.1689-3ubuntu1.1 amd64 [installed]
vim-gui-common/xenial-updates,xenial-updates,now 2:7.4.1689-3ubuntu1.1 all [installed,automatic]
vim-runtime/xenial-updates,xenial-updates,now 2:7.4.1689-3ubuntu1.1 all [installed,automatic]
vim-tiny/xenial-updates,now 2:7.4.1689-3ubuntu1.1 amd64 [installed]