Skip to main content

Questions tagged [gvim]

All about the VIM editor in one of its graphical incarnations.

Filter by
Sorted by
Tagged with
129 votes
4 answers
145k views

How to setup a line length marker in vim/gvim?

Some GUI text editors have a vertical line which serves as line length marker (it helps keeping lines shorter than 80 chars in source code files). Is is possible to have something similar in vim/gvim?...
vtest's user avatar
  • 5,280
121 votes
4 answers
60k views

How to get vim to open multiple files into tabs at once

Is it possible to get vim to open multiple files into tabs, similar to the way the args <path> command will open multiple files into buffers? Doing something like :tabe ./* results in the error ...
Ash's user avatar
  • 3,024
112 votes
1 answer
31k views

How to make Vim spellcheck remember a new word

I'm using gVim for LaTeX editing. I write lots of scientific documents with words that the vim dictionary does not know. When running through spell checking I come across words that I know are ...
Andrew Redd's user avatar
  • 1,762
106 votes
3 answers
109k views

How do I find the encoding of the current buffer in vim?

Say I am editing some file with vim (or gvim). I have no idea about the file's encoding and I want to know whether it is in UTF-8 or ISO-8859-1 or whatever? Can I somehow tell vim to show me what ...
innaM's user avatar
  • 10.3k
102 votes
9 answers
88k views

How can I get (g)Vim to display the character count of the current file?

I like to write tutorials and articles for a programming forum I frequent. This forum has a character limit per post. I've used Notepad++ in the past to write posts and it keeps a live character ...
OwenP's user avatar
  • 1,549
83 votes
11 answers
58k views

Vim: How to synchronize NERDTree with current opened tab file path?

When I open a new tab with different path from the previous file in VIM, NERDTree will still remains the same directory hierarchy of the previous file. Is there a sync shortcut to change the current ...
Jichao's user avatar
  • 7,570
77 votes
5 answers
28k views

Where does VIM (gvim/macvim) keep swap files for unsaved/unnamed buffers?

Where does VIM (gvim/macvim) keep swap files for unsaved/unnamed buffers? (If it does so at all). Background: Throughout a semi intense seminar I was taking notes in an unnamed/unsaved MacVim buffer ...
davur's user avatar
  • 927
74 votes
10 answers
94k views

How to remove this symbol "^@" with vim?

I have some files that are corrupted with this symbol: ^@ It's not part of the string; it's not searchable. How do I substitute this symbol with nothing, or how do I delete this symbol? Here is ...
mrt181's user avatar
  • 925
69 votes
8 answers
37k views

Move cursor to beginning of non-whitespace characters in a line in Vim

In Vim, is there a way to move the cursor to the beginning of non-whitespace characters in a line? For instance, how can I move the cursor to the "S" in the second line below? First line Second ...
Joe Mornin's user avatar
  • 1,667
66 votes
4 answers
67k views

How to make cut/copy/paste in GVim on Ubuntu work with Ctrl+X,Ctrl+C,Ctrl+V?

By default, the cut/copy/paste short-cuts in GVim on Ubuntu are: Cut "+x Copy "+y Paste "+gP I would like to use control key combos in GVim, like I use in Firefox and othe gnome ...
pcapademic's user avatar
  • 3,781
64 votes
3 answers
61k views

How do I move around and otherwise rearrange splits in vim?

So far, I've figured out swapping splits laterally via CTRL+W x, and that's pretty much it. How do I move a split anywhere in a viewport that contains multiple vertical and horizontal splits? How do ...
hakanensari's user avatar
  • 2,167
57 votes
3 answers
14k views

Is there a way to move a split page to a new tab in Vim?

I have opened a file in a horizontal or vertical split and which to put it in a new tab instead. Can this be done easily?
Pierre-Antoine LaFayette's user avatar
54 votes
7 answers
20k views

How do I copy command output in vim?

For example, if I type ':pwd' to get the current working directory, I can select the text in gvim but I can't figure out how to copy it to the clipboard. If I try the same in console vim, I can't even ...
Steven's user avatar
  • 2,359
43 votes
11 answers
30k views

How to start gVim maximized?

How to make gVim automatically maximize it's window when I open it? And a cross-plataform solution, I'm trying to use the same configs in a Linux and Windows machine... I've tried the hack :set lines=...
Somebody still uses you MS-DOS's user avatar
32 votes
6 answers
6k views

How can I discard my undo history in vim?

Undo is nice to have in Vim. But sometimes, at a known good point, I want to erase my undo history - to be able to use u to undo individual changes, but only back to a certain point. (For instance, ...
Nathan Long's user avatar
  • 26.8k
31 votes
3 answers
13k views

Vim - dynamic list of open buffers in a window

I've investigated a few ways to maintain a list of open buffers in Vim, and some of them are very good, but none of them seem to behave the way I'd like. It's very possible that nothing like what I ...
asfallows's user avatar
  • 1,041
30 votes
1 answer
17k views

Can't run Vimdiff (7.4) on Windows 7

I recently installed the 7.4 version of gVim on a Windows 7 machine. Trying to diff two files from the context-sensitive menu on Windows Explorer, I keep getting the error messages: E810: Cannot ...
ysap's user avatar
  • 2,690
28 votes
5 answers
12k views

vim line wrap with indent

Vim/gvim will wrap long lines like this: 000000000000000000000000000000000000| 00000000000000 | 11111111111111111111111111111111| 111111111111111111 | ...
retracile's user avatar
  • 3,526
25 votes
4 answers
51k views

What is a vim "runtime directory"?

I'm trying to get started with things like FuzzyFinder, but I am stuck at the point where it says: INSTALLATION Put all files into your runtime directory. If you have the zip file, extract ...
Andres Jaan Tack's user avatar
22 votes
2 answers
8k views

Convert HTML to image

Background Batch convert various syntax-highlighted source files (C, SQL, Java, PHP, batch, bash) into high-resolution images (600dpi), suitable for an eBook and printed book. Failed Solutions A ...
Dave Jarvis's user avatar
  • 3,258
21 votes
2 answers
43k views

Setting background color in gvim

I use a terminal with white text on black background (I just like it better), so I wrote the following line in my .vimrc file: set background=dark However, gvim has black on white text. How do I do ...
petersohn's user avatar
  • 2,692
20 votes
7 answers
43k views

gVim: How to open multiple files in its own tab at once?

in most GUI text editor I can use ctrl click to open multiple files at once. I can't do that in gvim. What the gvim way to do it? Tnx. -edit- ...using gui way instead of command line.
mhd's user avatar
  • 393
19 votes
1 answer
15k views

Show command as it's being entered in console vim?

For example, in gvim if I'm in normal mode then I press "ayiw to yank a word into register a, gvim shows the "ayi as I type it near the bottom right corner. Is it possible to get this real-time ...
Steven's user avatar
  • 2,359
18 votes
2 answers
11k views

How to navigate between begin and end html tag in Vim?

For example, if I want to jump to the close form tag. how could I do this?
Jichao's user avatar
  • 7,570
18 votes
2 answers
10k views

How do I customize the gvim toolbar?

I'd like to remove some of the default icons and maybe add one or two icons of my own. For example, it would be nice if there were icons for the NerdTree and the Taglist.
17 votes
9 answers
30k views

Change menu/ui language of vim to english

I search on google and I read several answers but I am unable to change the menu/ui language of vim to english. Im my .vimrc I have set langmenu=en_US.UTF-8 language messages en_US.UTF-8 but it ...
res1's user avatar
  • 454
17 votes
7 answers
48k views

Better GUI for vim?

I enjoy using vim, its endless features and the way it does things (for the most part). I've been using it on and off (not as my main editor) for at least 7 years now, so while I'm far from being an ...
imiric's user avatar
  • 498
17 votes
4 answers
4k views

How to set background color for Vim's active window only?

A small but visually pleasing feature, and slightly adding to usability, I'd like to have Vim use different background color for the active window. Here's a sketch of what I am after: Normally that ...
mike3996's user avatar
  • 1,581
15 votes
3 answers
18k views

How do you change the default colorscheme in gvim?

In GVIM for Windows I know you are supposed to be able to add something to the $VIM/_vimrc file in order to customize the start up and I have managed how to figure out a few neat tricks with that but ...
faceless1_14's user avatar
13 votes
5 answers
5k views

Disable mouse clicks in gvim on ubuntu

How do I make gvim ignore mouse clicks. I'm really sick of the trackpad making my cursor all over the place. I use xubuntu if that means anything.
Galadude's user avatar
  • 351
13 votes
3 answers
16k views

Dynamically change font size in gvim?

I'd like to be able to dynamically change the font size in gvim. Essentially, the common zoom-in/zoom-out functionality you find in a lot of software. So if I press Ctrl+=, the font size gets bigger....
ngm's user avatar
  • 1,823
12 votes
1 answer
17k views

How to install gvim on Ubuntu 10.10?

I checked under Software Center, but I could not find it. How can I install gvim?
roxrook's user avatar
  • 257
12 votes
5 answers
11k views

Where's my Open-With gVim context menu option in Windows 7?

I have gVim installed. Under Vista and XP, this offered me an addition to either the object context menu of "Edit with gVim", or an addtion to the "Open With" context menu of "gVim". This would let ...
David Mackintosh's user avatar
12 votes
6 answers
8k views

Compile gvim from sources?

Recently, I've installed vim like so: hg clone https://vim.googlecode.com/hg/ vim cd vim sudo ./configure --enable-rubyinterp=yes --enable-pythoninterp=yes --enable-gui=gtk2 --prefix=/opt/vim make ...
Nemoden's user avatar
  • 2,507
12 votes
4 answers
5k views

Close all locations list or quick fix windows in vim

Is there a way to close all locations lists and quick fix windows with a single command in vim/gvim?
vonhogen's user avatar
  • 2,409
11 votes
1 answer
3k views

Hitting enter in the quickfix window doesn't work

Normally, hitting enter in the qucikfix window leads to jump to the corresponding line. But when I hit enter, there is a message in the status line, says "xxx matchs, xx lines", instead of jumping. It ...
Sisyphus's user avatar
  • 213
11 votes
2 answers
1k views

Insert a new full-width buffer underneath two vertically split buffers

When having the window split vertically how do I split the window horizontally with a new buffer so that the new buffer ends up on the bottom and takes up the full width of the window: Start here: |-...
tom's user avatar
  • 213
11 votes
3 answers
11k views

How can I set gvim's window width to 80 columns of text, plus the ones needed to show the line number

I use gvim with set number in my .vimrc so it shows the linenumber, plus a space, before every line. If the document has less than 10 lines, this takes 2 columns, If it has more than 10, 3 columns ...
Elton Carvalho's user avatar
11 votes
1 answer
9k views

how to turn off gvim error highlighting?

I use gvim as my text editor and the syntax coloring is great except it highlights "errors" and gives it a white background with red font. How do I turn off error highlighting? I find it annoying and ...
user2719875's user avatar
11 votes
3 answers
5k views

Getting gvim to show unicode

How to get GVim (v. 7.3. on Windows XP, if that matters) to show Unicode characters? Something along the lines of http://vimcasts.org/episodes/show-invisibles/ (search for listchars to see the ...
Rook's user avatar
  • 24k
11 votes
1 answer
3k views

Vim - automatically delete SWP file after recovery doesn't change the original file

When the Vim process is abruptly terminated (e.g. system crash), it leaves a SWP file. Opening the original file in Vim later gives the option of recovery. Most of the time the recovered file is the ...
Evgeni Sergeev's user avatar
10 votes
6 answers
6k views

bashrc: how to know X window is available or not?

There is a part in my ~/.bashrc, which sets $EDITOR to be gvim. It works fine when I am in X window. However, if I ssh to my workstation (from another workstation) gvim starts to complain "cannot open ...
Ryan's user avatar
  • 203
10 votes
1 answer
10k views

VIM: how to select a line, up to the cursor, including the char under the cursor?

From normal mode I select what's before the cursor with: v<Home> Is adding to the selection what's under the cursor possible? Thanks!!
dan's user avatar
  • 203
10 votes
1 answer
2k views

'Fixing' the right click menu in gvim in Ubuntu

I have installed gvim in Ubuntu 12.04 and it has no right click menu. For example, if I select a block of text and right click in the region, the size of the selection changes up to the cursor ...
gebby's user avatar
  • 309
10 votes
4 answers
2k views

gvim redraw failure

I have a problem with gvim where the screen redraw partially fails. It's hard to explain but when I open a text file and page down or up the entire text file is not redraw properly. I have to move the ...
sashang's user avatar
  • 340
10 votes
1 answer
7k views

GVim: Shift + Insert dump <S-Insert> instead of the clipboard text

While editing inside gVIM, whenever I press Shift+Insert, it's insert the <S-Insert> text. I'm running on Ubuntu Maverick and compile Vim from source. This is really annoying. What's wrong with ...
Phuong Nguyen's user avatar
9 votes
2 answers
3k views

How to configure MacVim to quit on exit?

When I close MacVim using the standard vim command :q, the MacVim window closes, but the program is still running. This causes trouble when other processes try to spawn an instance of MacVim, because ...
tlehman's user avatar
  • 283
9 votes
3 answers
20k views

How can I indent multiple lines, and indent "backwards", in gvim?

I'm just learning vim (via gvim, I used to be a Notepad++ user) and haven't yet found how to do 2 things: How can I indent a set of rows x spaces/tabs right? In Notepad++, for example, I just ...
drapkin11's user avatar
  • 984
9 votes
3 answers
808 views

Replacing the pager inside vim?

Note: Not using vim as a pager. That's covered extensively on the Internet. When you press Tab to complete various kinds of stuff inside vim/gvim, it brings up a fairly basic pager. For example, ...
Roger Lipscombe's user avatar
9 votes
2 answers
2k views

Multiple foldmethods in vim

I use the folding option of vim quite a lot, and have usually set foldmethod to syntax. Recently I discovered that it is possible to add custom folds, such that I can put whole blocks in /*{{{*/ and /*...
Bjarke Freund-Hansen's user avatar

1
2 3 4 5
11