forked from vim-scripts/RST-Tables
-
Notifications
You must be signed in to change notification settings - Fork 0
/
README
54 lines (38 loc) · 1.93 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
This is a modification of the standard RST-Table vim plugin plus following features:
1. fix column width containing Chinese characters
2. add simple tables(table without headers) command: ,,C and ,,F
-------------------------------------------------------------
This is a mirror of http://www.vim.org/scripts/script.php?script_id=3041
This plugin allows to create and edit restructuredText tables easily.
Its adds two new commands:
,,c -> Creates a new restructuredText table.
,,f -> Fix table columns in a table.
For example, if you have a paragraph with data like this:
nombre apellido edad
pepe zarate 28
toto garcia 29
you can press ",,c" to create a simple table:
+--------+----------+------+
| nombre | apellido | edad |
+========+==========+======+
| pepe | zarate | 28 |
+--------+----------+------+
| toto | garcia | 29 |
+--------+----------+------+
Now, if you change the table content, for example adding characters
to the first content row.
+--------+----------+------+
| nombre | apellido | edad |
+========+==========+======+
| Un nombre muy largo que rompe la tabla | zarate | 28 |
+--------+----------+------+
| toto | un appellido largo... | 29 |
+--------+----------+------+
you need to fix the columns widths. So, press ",,f" and you will gets:
+----------------------------------------+-----------------------+------+
| nombre | apellido | edad |
+========================================+=======================+======+
| Un nombre muy largo que rompe la tabla | zarate | 28 |
+----------------------------------------+-----------------------+------+
| toto | un appellido largo... | 29 |
+----------------------------------------+-----------------------+------+