Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Show column marker in vim

1,363 views
Skip to first unread message

cub...@gmail.com

unread,
Aug 12, 2008, 9:09:11 AM8/12/08
to
Hi,

I have trawled google, www.vim.org and vim.wikia.com to try and find
this one out...

Does anyone know if it is possible to make a column marker display in
vim - e.g. a thin line at a given column number that runs down the
screen so you can see at a glance where that column is. I find such a
thing useful for when doing block comments and stuff like that.

I used to be able to do this yonks ago when I used EditPlus on
windows. Is it possible with Vim?

Pete

Mikolaj Machowski

unread,
Aug 12, 2008, 9:50:39 AM8/12/08
to
cub...@gmail.com scripsit:

No. you can highlight characters which are after some column instead.

m.
--
LaTeX + Vim = http://vim-latex.sourceforge.net/
Vim Universal Templates: http://vim.sf.net/script.php?script_id=1078
vim.pl - http://skawina.eu.org/mikolaj
CLEWN - http://clewn.sf.net

Bob Harris

unread,
Aug 12, 2008, 8:43:09 PM8/12/08
to
In article
<bb11d1e2-8101-4132...@m73g2000hsh.googlegroups.com
>,
cub...@gmail.com wrote:

Not exactly what you want. The following will highlight
characters greater than column 80.

:match Todo '\%81v.*'

as

unread,
Aug 13, 2008, 1:06:54 AM8/13/08
to
Le Tue, 12 Aug 2008 06:09:11 -0700 (PDT),
cub...@gmail.com a écrit :

> Does anyone know if it is possible to make a column marker display in
> vim -

set cursorcolumn

> e.g. a thin line at a given column number that runs down the
> screen so you can see at a glance where that column is. I find such a
> thing useful for when doing block comments and stuff like that.

not exactly what you want because it follows your moves but it can help
you to align your comment block.


--
Arnaud Schmittbuhl


Luka Djigas

unread,
Aug 13, 2008, 1:21:36 AM8/13/08
to

Well, he can always combine it with
set virtualedit=all

ldigas

John Beckett

unread,
Aug 13, 2008, 2:01:23 AM8/13/08
to
cubabit wrote:
>Does anyone know if it is possible to make a column marker display in
>vim - e.g. a thin line at a given column number that runs down the
>screen so you can see at a glance where that column is. I find such a
>thing useful for when doing block comments and stuff like that.

You've had the answer, but here is the tip (recently cleaned up, with
some in-progress comments at the bottom that will be removed soon):

http://vim.wikia.com/wiki/Highlight_text_beyond_80_columns

John

cub...@gmail.com

unread,
Aug 13, 2008, 5:54:36 AM8/13/08
to
On Aug 13, 7:01 am, John Beckett <nom...@thanks.junk> wrote:
> You've had the answer, but here is the tip (recently cleaned up, with
> some in-progress comments at the bottom that will be removed soon):
>
> http://vim.wikia.com/wiki/Highlight_text_beyond_80_columns

Thanks everyone!

/\%80v.*

Did the trick. Its not pretty but it does the job. set cursorcolumn
looks nicer but if only you could get the thing to stick in one place.
ah well.

0 new messages