Initial commit

This commit is contained in:
Julian Ospald 2018-06-14 01:29:15 +02:00
commit d733c49ffb
No known key found for this signature in database
GPG Key ID: 511B62C09D50CD28
2 changed files with 33 additions and 0 deletions

30
ginit.vim Normal file
View File

@ -0,0 +1,30 @@
let s:default_fontsize = 11
let s:fontsize = s:default_fontsize
let s:font = "Monospace Regular"
" GuiLinespace 2
function! SetFont() abort
if exists('g:GtkGuiLoaded')
call rpcnotify(1, 'Gui', 'Font', s:font . ' ' . s:fontsize)
else
exec "GuiFont " . s:font . ":h" . s:fontsize
endif
endfunction
call SetFont()
function! AdjustFontSize(delta)
let s:fontsize += a:delta
call SetFont()
endfunction
function! ResetFontSize()
let s:fontsize = s:default_fontsize
call SetFont()
endfunction
nnoremap <C-=> :call AdjustFontSize(1)<CR>
nnoremap <C-+> :call AdjustFontSize(1)<CR>
nnoremap <C--> :call AdjustFontSize(-1)<CR>
nnoremap <C-0> :call ResetFontSize()<CR>

3
init.vim Normal file
View File

@ -0,0 +1,3 @@
set runtimepath ^=~/.vim runtimepath+=~/.vim/after
let &packpath = &runtimepath
source ~/.vim/vimrc