6

If I purge my existing vim-full installation and install a GUI version like vim-gnome or vim-gtk, can I still use it in the text mode I am familiar with?

What if I am using it from a terminal via SSH? How does the gui mode interact with a terminal-based user?

I have seen the gui version of Vim referred to as "gvim". Does that mean you start it with the command gvim instead of vim?

  • 1
    Yes. Gvim is a visual app and you can start by clicking the icon or through the options.Almost, all vim options will be supported in gvim. You can use it as vim without GUI by not using mouse except for copying and pasting. By the way, these days people are comfortable with GUI version,why don't you try that? Iuse both but love vim than gvim – SibiCoder Jul 27 '16 at 17:06
10

Yes.

Vim-gnome does install gvim, but it also installs a much more feature-filled version of command line vim, including Perl, Python, Ruby, and TCL scripting, system-clipboard, newer patches, etc.

So not only can you continue to use command line vim, you will get a better version of command line vim along with the GUI.

As for SSH editing, I don't believe anything will change for you. I personally have never used vim to edit over SSH, but according to this article, you can edit remote files from directly within gvim with:

:e scp://username@someremotehost/./path/to/file

Even if that doesn't work, your original command line vim will be the same, so (assuming you can edit through SSH now) you could just choose to use command line vim instead.

Also, yes the GUI version is called "gvim", and can be launched either with

gvim

or

vim -g

From :help -g

                            *-g*
-g      Start Vim in GUI mode.  See |gui|. For the opposite see |-v|.
        {not in Vi}

and from :help gui-start

1. Starting the GUI             *gui-start* *E229* *E233*

First you must make sure you actually have a version of Vim with the GUI code
included.  You can check this with the ":version" command, it says "with xxx
GUI", where "xxx" is X11-Motif, X11-Athena, Photon, GTK, GTK2, etc., or
"MS-Windows 32 bit GUI version".

How to start the GUI depends on the system used.  Mostly you can run the
GUI version of Vim with:
    gvim [options] [files...]

The X11 version of Vim can run both in GUI and in non-GUI mode.  See
|gui-x11-start|.
6

can I still use it in the text mode I am familiar with?

Yes, you can still use the terminal version of vim.

How does the gui mode interact with a terminal-based user?

If you SSH into a machine and run vim there, you won't be able to use the GUI unless you have some setup for remote desktop.

Does that mean you start it with the command gvim instead of vim?

Actually using the GUI version (which is indeed executed with gvim or vim -g) is entirely optional. I never use the GUI, except for text files from the web browser. But I'd still recommend installing the GUI version because it will allow you to access the clipboard which is very handy (I.e. "+yy to copy the current line to the X11 clipboard which you can paste into any other application).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.