On Wednesday, September 08, 2010 08:26:33 pm Ven Tadipatri wrote:
> After some difficulties I had with my c++ IDE I decided to switch to
> using vi. I have a lot to learn, but already I'm really impressed by
> the possibilities of navigation. It offers so much more than the
> standard arrow keys and page up/page down/home/end keys in a standard
> IDE:
> - you can mark a point in the code and go to it
> - ctrl I and O allow you to navigate back and forth
> - / and f allow you to find
> - w and b move you back and forth across words and with numbers you
> can navigate across multiple words
> - you can fold parts of the code and navigate across the folds
> - it's integrated fully with the shell itself, so you can open up a
> new window with ctrl+w, and execute whatever commands you want.
> -I'm sure there's lots more, this is just from a first glance what
> struck me as far superior to navigation I see in most editors.
> 
> There are still difficulties I'm trying to get over, like navigating
> across multiple files and autocompletion, but I think I'm definitely
> on the right track in switching to vi from an IDE like Eclipse or
> Netbeans.
>    Eclipse works well for java, but when I tried using it for C++, I
> got so frustrated with it, despite the fancy graphical interface, I
> wanted an editor with good code navigation. In fact, oddly enough, the
> fact that most IDE's have a graphical interfaces actually causes more
> problems. Whereas in VI, a few keystrokes can get you to where you
> want (granted there's a learning curve), in an IDE, there's a dialog
> that pops up, you're restricted to the buttons and textboxes they give
> you, plus there's the extra GUI load time. And it's the customization
> feature of vi that makes it really powerful. You can make the
> shortcuts you want, and it's all self-contained within a single
> .vimrc. There's no digging through Eclipse plugin configuration files.
>    If anyone can point me to good tutorials for using VIM as an
> effective IDE (for C++ specifically), I would greatly appreciate it.
> There's so many subtle things about VIM I really don't know where to
> go to learn more about using it effectively.
> 
> Thanks,
> Ven
Check this plugin for C++ http://www.vim.org/scripts/script.php?script_id=213. 
Here is VIM wiki for code completion in C++ 
http://vim.wikia.com/wiki/C%2B%2B_code_completion. If using Linux with KDE, 
you can also try kdevelop editor. Check Vim Wiki for lots of trips and tricks 
http://vim.runpaint.org/ and I found this website really very good for 
learning Vim http://vim.runpaint.org/

For navigating across multiple files you can either use "buffers" or firefox 
like tabs. For using tabs like you do in firefox put this in .vimrc (Linux) or 
_vimrc (windows):

nmap <C-tab> :tabnext<CR>
nmap <C-S-tab> :tabprevious<CR>
map <C-S-tab> :tabprevious<CR>
map <C-tab> :tabnext<CR>
imap <C-S-tab> <Esc>:tabprevious<CR>i
imap <C-tab> <Esc>:tabnext<CR>i
nmap <C-t> :tabnew<CR>
imap <C-t> <Esc>:tabnew<CR>


Thanks
Vivek Bhat

-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Reply via email to