[Tex/LaTex] Which text editor to make tables scripts human readable

editorstables

Suppose I want to edit a table

moon & 456456456423423534 &  2342523
sun  &             234324 &     3453

You see I have to enter a lot of spaces manually to align stuff. It is ok for a small table but for a large table this is inefficient.

I wonder there there is an editor that I can easily write tables in human readable script. I am familiar with vim and Ultraedit though I don't know which functionality specifically I should use. Perhaps there are software better than vim and Ultraedit for this purpose.

Best Answer

I am very happy with vim and the tabular plugin. To align the table, place the cursor anywhere inside the (nonaligned) table and type :Tabularize /&. The result is a nicely aligned table.

Before:

moon&456456456423423534&2342523
sun&234324&3453

Then a :Tabularize /&, after:

moon & 456456456423423534 & 2342523
sun  & 234324             & 3453

If you need this often, you can assign a custom shortcut for this.