Updated Table Mode

- Added recommended check for vi compatibility.
- Updated docs.
This commit is contained in:
Dhruva Sagar
2013-03-26 16:45:39 +05:30
parent e997144d2f
commit 87f9e9d3f5
3 changed files with 20 additions and 9 deletions

View File

@@ -33,6 +33,11 @@ if !exists(':Tabularize')
endif
" }}}1
" Avoiding side effects {{{1
let s:save_cpo = &cpo
set cpo&vim
" }}}1
function! s:SetGlobalOptDefault(opt, val) "{{{1
if !exists('g:' . a:opt)
let g:{a:opt} = a:val
@@ -75,5 +80,9 @@ execute "xnoremap <silent> " . g:table_mode_tableize_map . " :Tableize<CR>"
execute "nnoremap <silent> " . g:table_mode_tableize_map . " :Tableize<CR>"
"}}}1
" Avoiding side effects {{{1
let &cpo = s:save_cpo
" }}}1
" ModeLine {{{
" vim:fdl=0 fdm=marker

View File

@@ -142,7 +142,7 @@ MAPPINGS *table-mode-mappings*
COMMANDS *table-mode-commands*
*:TableModeToggle*
*table-mode-commands-toggle*
*table-mode-:TableModeToggle*
:TableModeToggle
Toggles the table mode. Same effect as |toggle-mode-mappings-toggle|.
@@ -150,7 +150,7 @@ COMMANDS *table-mode-commands*
not set.
*:TableModeEnable*
*table-mode-commands-enable*
*table-mode-:TableModeEnable*
:TableModeEnable
Enables Table Mode.
@@ -158,7 +158,7 @@ COMMANDS *table-mode-commands*
not set.
*:TableModeDisable*
*table-mode-commands-disable*
*table-mode-:TableModeDisable*
:TableModeDisable
Disables Table Mode.
@@ -166,7 +166,8 @@ COMMANDS *table-mode-commands*
not set.
*:Tableize*
:Tableize *table-mode-commands-tableize*
*table-mode-:Tableize*
:Tableize
This converts the current line into a table if it consists of
|table-mode-options-delimiter|. This accepts a range, without which it
applies on the current line.
@@ -174,7 +175,7 @@ COMMANDS *table-mode-commands*
CONTRIBUTING *table-mode-contributing*
If you want to take a stab at it, by all means, send me a pull request on
Github (http://github.com/dhruvasagar/table-mode.git) or get in touch with me
Github (http://github.com/dhruvasagar/table-mode) or get in touch with me
directly via e-mail at dhruva 'dot' sagar 'at' gmail.com.
===============================================================================

View File

@@ -2,11 +2,11 @@
:TableModeEnable table-mode.txt /*:TableModeEnable*
:TableModeToggle table-mode.txt /*:TableModeToggle*
:Tableize table-mode.txt /*:Tableize*
table-mode-:TableModeDisable table-mode.txt /*table-mode-:TableModeDisable*
table-mode-:TableModeEnable table-mode.txt /*table-mode-:TableModeEnable*
table-mode-:TableModeToggle table-mode.txt /*table-mode-:TableModeToggle*
table-mode-:Tableize table-mode.txt /*table-mode-:Tableize*
table-mode-commands table-mode.txt /*table-mode-commands*
table-mode-commands-disable table-mode.txt /*table-mode-commands-disable*
table-mode-commands-enable table-mode.txt /*table-mode-commands-enable*
table-mode-commands-tableize table-mode.txt /*table-mode-commands-tableize*
table-mode-commands-toggle table-mode.txt /*table-mode-commands-toggle*
table-mode-contents table-mode.txt /*table-mode-contents*
table-mode-contributing table-mode.txt /*table-mode-contributing*
table-mode-getting-started table-mode.txt /*table-mode-getting-started*
@@ -22,6 +22,7 @@ table-mode-options-corner table-mode.txt /*table-mode-options-corner*
table-mode-options-delimiter table-mode.txt /*table-mode-options-delimiter*
table-mode-options-fillchar table-mode.txt /*table-mode-options-fillchar*
table-mode-options-loaded table-mode.txt /*table-mode-options-loaded*
table-mode-options-no-border-padding table-mode.txt /*table-mode-options-no-border-padding*
table-mode-options-separator table-mode.txt /*table-mode-options-separator*
table-mode-options-toggle-map table-mode.txt /*table-mode-options-toggle-map*
table-mode-report-issues table-mode.txt /*table-mode-report-issues*