summaryrefslogtreecommitdiff
path: root/_posts/2012-05-18-using-vim.md
diff options
context:
space:
mode:
authorAndreas Maunz <andreas@maunz.de>2012-08-07 12:20:38 +0200
committerAndreas Maunz <andreas@maunz.de>2012-08-07 12:20:38 +0200
commitb52ad0ea3b42a2317cdd3f72e5585214e0fb36b7 (patch)
treedcdcddec2ac65a94c25f4e3cfa6a85b1b33df44c /_posts/2012-05-18-using-vim.md
parent4deab97fc056ce885699160f5884f435ed98ed70 (diff)
Window handling in .vimrc, .gvimrc
Diffstat (limited to '_posts/2012-05-18-using-vim.md')
-rw-r--r--_posts/2012-05-18-using-vim.md15
1 files changed, 14 insertions, 1 deletions
diff --git a/_posts/2012-05-18-using-vim.md b/_posts/2012-05-18-using-vim.md
index d102508..fc32d52 100644
--- a/_posts/2012-05-18-using-vim.md
+++ b/_posts/2012-05-18-using-vim.md
@@ -76,8 +76,20 @@ Put this in your `~/.vimrc`:
set t_Co=256
-Your user experience should now be much better.
+ " Maps Alt-[h,j,k,l] to resizing a window split
+ map <silent> <A-h> <C-w><
+ map <silent> <A-j> <C-W>-
+ map <silent> <A-k> <C-W>+
+ map <silent> <A-l> <C-w>>
+ " Maps Alt-[s.v] to horizontal and vertical split respectively
+ map <silent> <A-s> :split<CR>
+ map <silent> <A-v> :vsplit<CR>
+ " Maps Alt-[n,p] for moving next and previous window respectively
+ map <silent> <A-n> <C-w><C-w>
+ map <silent> <A-p> <C-w><S-w>
+
+Your user experience should now be much better. You will have syntax highlighting, and can split the **Vim** window using `Alt+s` and `Alt+v`. See the comments above for more options.
<p></p>
---
@@ -348,6 +360,7 @@ Note: Reduce colors and decrease font size in **Gvim** by setting
colorscheme morning
set guifont=Monospace\ 8
+ set guioptions-=m
in your `.gvimrc`.