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

Can I get column numbers in vi (Ruler)?

5,340 views
Skip to first unread message

Brian Casson

unread,
Jun 21, 1995, 3:00:00 AM6/21/95
to
Is there a way to view a ruler which reveals line numbers in vi?
Much appreciated..

Kevin Buettner

unread,
Jun 22, 1995, 3:00:00 AM6/22/95
to
Sven Guckes (guc...@inf.fu-berlin.de) wrote:
: Brian Casson <cassonb%i...@clipper.ssb.com> writes:
: >Is there a way to view a ruler which reveals line numbers in vi?

: Well, "vim" can; and the "vim.reference.txt" says that vi doesn«t have such
: a feature:

[snip]

vile also has this capability which is available via ":set [no]ruler".

There are also additional mechanisms to change the layout of the modeline
if you do not like the default. If "ruler" mode is on, the line and column
number are displayed at the lower right along with a percentage indicator
which shows the approximate position within the buffer (e.g, 12%). I use
xvile most of the time and did not really want the percentage indicator
since this functionality is more or less duplicated by just looking at the
position of the scrollbars. So I customized this indicator out of the
modeline in the initialization file.

Beirne Konarski

unread,
Jun 22, 1995, 3:00:00 AM6/22/95
to
Brian Casson (cassonb%i...@clipper.ssb.com) wrote:
: Is there a way to view a ruler which reveals line numbers in vi?
: Much appreciated..

If you want line numbers then type

:set number

If you want column numbers then just make a ruler and read it into your text
when you need it.

Beirne

--
Beirne Konarski | Subscribe to the Unicycling Mailing List
bkon...@mcs.kent.edu | Send requests to unicyclin...@mcs.kent.edu
Kent State University | Unicycling Web Page:
"Untouched by Scandal" | http://nimitz.mcs.kent.edu/~bkonarsk/

Sven Guckes

unread,
Jun 22, 1995, 3:00:00 AM6/22/95
to
Brian Casson <cassonb%i...@clipper.ssb.com> writes:
>Is there a way to view a ruler which reveals line numbers in vi?

Well, "vim" can; and the "vim.reference.txt" says that vi doesn«t have such
a feature:

ruler (ru) toggle (default off)
Show the line and column number of the cursor position in the status
line, separated by a comma. If there are characters in the line that
take two positions on the screen, both the "real" column and the
screen column are shown, separated with a dash. This option is reset
when the 'paste' option is set. {not in Vi}

Sven

--
[950621] "VIM Pages" ("vi improved") - free vi! UNIX, DOS, OS/2, Mac, ...
Home Page: http://www.inf.fu-berlin.de/~guckes/vim/
Sample vimrc: http://www.inf.fu-berlin.de/~guckes/setup/vimrc

Steffen Koehler

unread,
Jun 26, 1995, 3:00:00 AM6/26/95
to
Brian Casson (cassonb%i...@clipper.ssb.com) wrote:
: Is there a way to view a ruler which reveals line numbers in vi?
: Much appreciated..
Hello,

type
:set number
thats all.

Bye Steffen
--
--------------------------------------------------------------------------------
Steffen K"ohler
Department of Computer Science
Friedrich-Schiller-Universit"at Jena

Tobias Voegele

unread,
Jun 26, 1995, 3:00:00 AM6/26/95
to
Brian Casson (cassonb%i...@clipper.ssb.com) wrote:
: Is there a way to view a ruler which reveals line numbers in vi?
: Much appreciated..

Hi,
type
CTRL-G
or
72|
for FORTRAN sources

--
Tobias Voegele, Institut fuer Technische Thermodynamik, Universitaet Karlsruhe
Kaiserstrasse 12, D-76128 Karlsruhe, Tel.: 0721/608-3932
================================================================================
If the automobile had followed the same development as the computer,
a Rolls-Royce would today cost $100, get a million miles per gallon,
and explode once a year killing everyone inside. --Robert Cringley

Douglas Denholm

unread,
Jun 28, 1995, 3:00:00 AM6/28/95
to
On 26 Jun 1995 10:36:44 GMT Steffen Koehler seems to have wrote:

: Brian Casson (cassonb%i...@clipper.ssb.com) wrote:
: : Is there a way to view a ruler which reveals line numbers in vi?
: : Much appreciated..
: Hello,

: type
: :set number
: thats all.

:set ruler
gives a running account of what line you're on in lower right

:set number
numbers the lines down the left of screen

to have either or both make a file .exrc in your home dir
that sez:

set ruler
set number

I like having the ruler on all the time & the number option
I just turn on for scripts

0 new messages