From 4422e1fbb74a85fd7167d9506c837cdfd09311ee Mon Sep 17 00:00:00 2001 From: Vincent Driessen Date: Fri, 20 Aug 2010 10:27:41 +0200 Subject: Implemented the "reflow" command. For example, if you have the following table in your source file: Type Message Foo I like bananas very much. Even so much that I adore them. Position your cursor in it and call ReformatTable(). This makes the following: +======+===========================================================+ | Type | Message | +======+===========================================================+ | Foo | I like bananas very much. Even so much that I adore them. | +------+-----------------------------------------------------------+ But if you don't like these kinds of long wrappings, you can now simply remove (or add, for that matter) some of the '='-signs from the top row, like this: +======+================================+ | Type | Message | +======+===========================================================+ | Foo | I like bananas very much. Even so much that I adore them. | +------+-----------------------------------------------------------+ And then, call ReflowTable(): +======+================================+ | Type | Message | +======+================================+ | Foo | I like bananas very much. Even | | | so much that I adore them. | +------+--------------------------------+ This fixed issue #1. --- src/base.vim | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/base.vim') diff --git a/src/base.vim b/src/base.vim index 46bdb05..037a9dd 100644 --- a/src/base.vim +++ b/src/base.vim @@ -24,6 +24,9 @@ endpython " The default mapping is registered, unless the user remapped it already. if !exists("no_plugin_maps") && !exists("no_rst_table_maps") if !hasmapto('ReformatTable(') - noremap f :call ReformatTable() + noremap c :call ReformatTable() + endif + if !hasmapto('ReflowTable(') + noremap f :call ReflowTable() endif endif -- cgit v1.2.3