TransWikia.com

Default rulerformat

Vi and Vim Asked on January 6, 2021

I like the default rulerformat, but I would like to add to it. However it
seems the default value is hidden. If I try these:

set rulerformat
set rulerformat?

I just get:

rulerformat=

Same for statusline.

One Answer

The default format of the ruler option is directly set in the C core of Vim. If you do not like the default, you can customize it using the 'rulerformat' option and using the statusline format expressions.

By experimenting, it seems the default ruler format (when not customized) is:

:set rulerformat=%l,%c%V%=%P
                  │  │ │ │ └ position in the file in percent (or ALL/TOP/BOT)
                  │  │ │ └—— right align the following items
                  │  │ └———— virtual (or screen) column, matters for TAB and multibyte chars
                  │  └—————— cursor column (in bytes)
                  └————————— current line

Answered by Christian Brabandt on January 6, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP