Sunday, January 8, 2012

Re: Can vim create table like this?

Excerpts from Peng Yu's message of Mon Jan 09 03:15:13 +0100 2012:
> I see that emacs can create table like this. Does vim have a plugin
> that offers similar capability?

I don't know exactly. I never missed it. Using HTML DSLs like HAML,
slim, JADE tables can be written equally fast:

- data = [["C programming language", 234], ['other lang', 345]]
%table
- for d in data
%tr
%td = d[0]
%td ='$'+d[1]
%tr
%td total
%td = sum( ... )

And if you can't use those for whatever reason you can still use one of
- zencoding
- sparkup
plugins
Zen coding such a HTML table is as much work as

table>tr*4>td,td<c-y> (or such)
and filling in the values.

If you really need this feature I'd recommend installing Emacs and get
vi emulation layers such as "evil". Sorry about that. I don't think any
Vim plugin provides that level of abstraction - I may be wrong though.

Marc Weber

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: