Vscode: Show column numbers in vscode

Created on 10 Oct 2018  路  8Comments  路  Source: microsoft/vscode

Hey all. I recently discovered that in the "Go to Line" command, you can not only go to a specific line, but you can also go to a specific column within that line.

So for instance, Ctrl+G + 10, 10 will move you to line 10, column 10 in the editor.

It would be nice for there to be an editor option that shows column numbers as well as line numbers within the editor, so that you don't have to guess which column to move to after the comma.

If this is already a feature that exists, my bad! I couldn't find it looking through the settings.

*out-of-scope editor-rendering feature-request

Most helpful comment

@loftusa do you mean you want to see column numbers similarly to how we render line numbers?

Yep! So there's the grey column of line numbers on the right-hand side, and it'd be cool for there to be an option to also see a horizontal grey row of column numbers at the top.

All 8 comments

(Experimental duplicate detection)
Thanks for submitting this issue. Please also check if it is already covered by an existing one, like:

@loftusa do you mean you want to see column numbers similarly to how we render line numbers?

@loftusa do you mean you want to see column numbers similarly to how we render line numbers?

Yep! So there's the grey column of line numbers on the right-hand side, and it'd be cool for there to be an option to also see a horizontal grey row of column numbers at the top.

We closed this issue because we don't plan to address it in the foreseeable future. You can find more detailed information about our decision-making process here. If you disagree and feel that this issue is crucial: We are happy to listen and to reconsider.

If you wonder what we are up to, please see our roadmap and issue reporting guidelines.

Thanks for your understanding and happy coding!

I suggest to reopen this feature request.

_Edit: Line number and column number are shown in version 1.46, May 2020. On selection, they disappear._

Showing the column number of the cursor is one of the first things I try to activate whenever I use a new editor, so for me this is hardly out of scope for a great editor.

Possible uses:

  • Finding the exact position of errors from compiler output (automatic highlighting is not always available)
  • Checking the width of a line
  • Calculating the length of text
  • Checking the exact size of a selection, for example when selecting more then a few lines, or a with Column Selection

Instead of showing a bar with column numbers (like a horizontal ruler), it would be sufficient to find the column number of the cursor (and maybe a selection) in a different way, like a status bar entry or a popup shown on a specific key combination.

_Edit: Simple Line/Col info seems to be implemented._
I would be very happy with something simple as "L xx C yy" where xx is the line number and C is the column number.

For selections, format could be "L xx C yy W zz H aa" where zz is the width of selection in columns and aa is the height of selection in lines.

@alexdima @rebornix : ping

It's hard to believe this isn't already a feature in fact xD

Could this maybe be implemented via an extension?

Yep! So there's the grey column of line numbers on the right-hand side, and it'd be cool for there to be an option to also see a horizontal grey row of column numbers at the top.

@loftusa Not sure if that's really a good idea in terms of UI and graphical layout, usage of screen space.

BUT it would be just one output label necessary to display the current column where the cursor is located atm.

That value would change as the cursor is moved. I think this actually is/was a feature of popular text editors before, even in VSCode? I am confused that I am in the situation of having to search for this, and thus using "Go to line" command indeed, but very weird, I am almost sure this existed in the past.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

trstringer picture trstringer  路  3Comments

lukehoban picture lukehoban  路  3Comments

shanalikhan picture shanalikhan  路  3Comments

trstringer picture trstringer  路  3Comments

mrkiley picture mrkiley  路  3Comments