Skip to content

Instantly share code, notes, and snippets.

@dannvix
Created April 21, 2012 12:52
Show Gist options
  • Save dannvix/2436960 to your computer and use it in GitHub Desktop.
Save dannvix/2436960 to your computer and use it in GitHub Desktop.
toggle between working mode and presentation mode (for projection demo)
" toggle between working mode and presentation mode
function! PresentationModeOn()
set background=light
colorscheme github
set guifont=Monaco\ for\ Powerline:h28.00
endfunction
function! PresentationModeOff()
set background=dark
colorscheme solarized
set guifont=Monaco\ for\ Powerline:h18.00
endfunction
function! TogglePresentationMode()
if !exists('w:present')
let w:present=0
endif
if w:present==0
call PresentationModeOn()
let w:present=1
else
call PresentationModeOff()
let w:present=0
endif
endfunction
map <leader>P :call TogglePresentationMode()<CR>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment