From 56560fd597f94dfe6fe5fa79648398ab29d05775 Mon Sep 17 00:00:00 2001 From: xero Date: Mon, 14 Jul 2014 13:23:05 -0400 Subject: updated repo to manage dotfiles via gnu stow, the symlink farm manager. happy birthday commit! :birthday: :sparkles: --- vim/.vim/bundle/colorizer/plugin/colorizer.vim | 62 ++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 vim/.vim/bundle/colorizer/plugin/colorizer.vim (limited to 'vim/.vim/bundle/colorizer/plugin/colorizer.vim') diff --git a/vim/.vim/bundle/colorizer/plugin/colorizer.vim b/vim/.vim/bundle/colorizer/plugin/colorizer.vim new file mode 100644 index 0000000..431098c --- /dev/null +++ b/vim/.vim/bundle/colorizer/plugin/colorizer.vim @@ -0,0 +1,62 @@ +" colorizer.vim Colorize all text in the form #rrggbb or #rgb; entrance +" Maintainer: lilydjwg +" Version: 1.4.1 +" Licence: Vim license. See ':help license' +" Derived From: css_color.vim +" http://www.vim.org/scripts/script.php?script_id=2150 +" Thanks To: Niklas Hofer (Author of css_color.vim), Ingo Karkat, rykka, +" KrzysztofUrban, blueyed, shanesmith, UncleBill +" Usage: +" +" This plugin defines three commands: +" +" ColorHighlight - start/update highlighting +" ColorClear - clear all highlights +" ColorToggle - toggle highlights +" +" By default, tc is mapped to ColorToggle. If you want to use another +" key map, do like this: +" nmap ,tc Colorizer +" +" If you want completely not to map it, set the following in your vimrc: +" let g:colorizer_nomap = 1 +" +" To use solid color highlight, set this in your vimrc (later change won't +" probably take effect unless you use ':ColorHighlight!' to force update): +" let g:colorizer_fgcontrast = -1 +" set it to 0 or 1 to use a softened foregroud color. +" +" If you don't want to enable colorizer at startup, set the following: +" let g:colorizer_startup = 0 +" +" Note: if you modify a color string in normal mode, if the cursor is still on +" that line, it'll take 'updatetime' seconds to update. You can use +" :ColorHighlight (or your key mapping) again to force update. +" +" Performace Notice: In terminal, it may take several seconds to highlight 240 +" different colors. GUI version is much quicker. + +" Reload guard and 'compatible' handling {{{1 +if exists("loaded_colorizer") || v:version < 700 || !(has("gui_running") || &t_Co == 256) + finish +endif +let loaded_colorizer = 1 + +let s:save_cpo = &cpo +set cpo&vim + +"Define commands {{{1 +command! -bar -bang ColorHighlight call colorizer#ColorHighlight(1, "") +command! -bar ColorClear call colorizer#ColorClear() +command! -bar ColorToggle call colorizer#ColorToggle() +nnoremap Colorizer :ColorToggle +if !hasmapto("Colorizer") && (!exists("g:colorizer_nomap") || g:colorizer_nomap == 0) + nmap tc Colorizer +endif +if !exists('g:colorizer_startup') || g:colorizer_startup + call colorizer#ColorHighlight(0) +endif + +" Cleanup and modelines {{{1 +let &cpo = s:save_cpo +" vim:ft=vim:fdm=marker:fmr={{{,}}}: -- cgit v1.2.1