gvim

Can I see changes before I save my file in Vim?

I use Vim. I open a file. I edit it and I want to see what I've edited before I save it. How can I do this in Vim? ...

Can GVIM have a background image?

Hello All, Wanted to know if I can place a background image into GVIM. Can this be done programatically? Thanks! ...

gVim tabline

In gvim, is it possible to have multiple rows of file tabs? That is, instead of showing left/right arrows to navigate around the tabline (for tabs that don't fit into the tabline), it should "start" a new row of tabs. Thanks in advance. ...

where is the : command history stored?

Hi, I want to know where the : command history is stored for a particular vim session. I know we can scroll and search through the history. My objective is to take a portion of the commands that I executed using trial and error and create a vim source file. ...

Emulate Windows C-Del/C-Backspace behavior in VIM

I like to emulate the normal behavior of C-Del/C-Backspace on Windows in VIM. Currently i'm using: imap <C-Del> <C-o>dw imap <C-Backspace> <C-o>db This is close but not perfect. E.g. when trying to delete this from the end of the line foo(1, 2) with C-Backspace, this happens: foo(1, ) How can I solve this? ...

Columns in VI

I have a bunch of lines that I'd like to split into two columns, and get the data from each column. The data looks something like this: current_well.well_number current_well.well_name current_well.well_type_code well_location.section well_location.range Essentially what I'd like to do is split the line based o...

gVim showing carriage return (^M) even when file mode is explicitly DOS

I really don't want to give up on vim again, but every time I try to learn it something gets in the way. I'm using gVim on Windows. My code shows ^M characters at the end of lines. I used :set ff=dos to no avail. The ^M characters remain for existing lines, but don't show up for newlines I enter. I've switched modes to mac (shows ^J c...

Gvim in UTF8 with Russian keyboard layout

I am a big fan of vim and gvim. But whenever I write localization code in PHP and have to translate some strings (primarily in Russian), I have to open Notepad to translate all the entries. That kinda sucks, but so far I have not found out how to make gvim work in utf8 mode. Any ideas would be appreciated. ...

How to find functions in a cpp file that contain a specific word

Hi all, using grep, vim's grep, or another unix shell command, I'd like to find the functions in a large cpp file that contain a specific word in their body. In the files that I'm working with the word I'm looking for is on an indented line, the corresponding function header is the first line above the indented line that starts at posi...

vim - yank entire file

I often write something in gvim, then need to copy-paste it into another application. Is there an easy way to yank the entire file? I usually do something like this, but is there a better way that I'm missing out on? ggVG"+y (Go to top, visual-line mode, go to bottom, yank) ...

Changing background color in vim at a certain column

I'd like to be able to highlight the wrap margin/text width in vim by changing the background color (or maybe just a line?). A lot of IDEs have this. I mocked up what I'm talking about: Anyone know if this can be done in macvim or gvim? ...

Deleting "blocks" of text in vim

I have files that look like the following: >>Start-pattern some text some more text >>Start-pattern some other text some more other text >>Start-pattern [and so on] What I would like to have is a mapping that allows me to delete the current "block" of text. Where "block" is defined as all lines ranging from ">>Start-pattern" until be...

Remove Tool Bar in GVim

How do I remove the Tool bar(which has the open save buttons) in the GVim? ...

Why does VIM create a X~ file for every X?

What is the purpose of the X~ files? And if its unnecessary, is there a way to prevent Vim from creating one? ...

What Fold should I use in VIM?

I usually edit RUBY files in VIM. I want the methods(def...end) to fold. Could you please help me define the fold syntax? ...

Stuck in installing Taglist in Vim

I was trying to install Taglist in VIM and I did not understand this step: If the exuberant ctags utility is not present in your PATH, then set the Tlist_Ctags_Cmd variable to point to the location of the exuberant ctags utility (not to the directory) in the .vimrc file. What does it mean? If anybody uses this plugi...

What is the difference between vim72 and vimfiles folder?

I am learning VIM. The VIM folder in the windows has two subdirectories VIM72 and VIMFILE. What is the difference between them? Where should I install my plugins? ...

Vertical spilts and folding in gvim

I have problems with automated splits and folding. In my ~/.gvimrc file, at the very end, I have the command vsplit, so that when I'm using gvim as opposed to vim, it opens with two panes. The problem occurs when I open a file that would normally be folded via the command line, as in gvim example.cpp. This opens the example.cpp file i...

Can I redirect output of a program to gvim?

I want to redirect the output of some Windows program directly to gvim basically for searching the output. Say for example the result of findstr cmd. Is it possible to do this without dumping it to a file and subsequently loading that file in gvim? ...

Formatting PHP Code within Vim

I'm currently using Vim as a lightweight IDE. I have NERDTree, bufexplorer, supertab, and ctags plugins which do almost everything I want. Only big thing missing for me is auto code formatting. I'm working with some messy PHP code which has inconsistent indenting and code formatting, ideally I could highlight the code I want formatted (...