sublime_text
sublime_text copied to clipboard
Allow disabling line and column numbers in the statusbar
1. Summary
It would be nice, if would be option, that user can disable line and column number in a status bar.
Related request in Sublime Text forum.
2. Argumentation
I use Sublime Text 6 years, but I have never felt the need for this function. It extra data for me.
This extra data can make it difficult to see useful messages in the status bar. See #1642 for details.
3. Actual behavior
Line and column numbers in status bar.
4. Expected behavior
No line and column numbers in status bar.
Thanks.
Furthermore the line and column is at the wrong position. It should get a dedicated position at the right with fixed size and position, such as git, encoding, indention, syntax indicators.
The current position conflicts with status messages and the dynamic position makes it hard to find.
A setting analog to show_encoding
would help to enable/disable the indicator, then.
Maybe something like show_caret_position
?
I have another thought: a setting of a string template for formatting so users can customize the message to whatever they want
"caret_position_msg": "Line ${line}, Column ${column}",
// probably provide more variables
// or even make it into
"status_bar_msg": "...",
Hehe, looks like GitGutter's customizable status_bar_message
using jinja2.
Or make it a button, that when clicked triggers the goto (line and column) command.
+1 from the future! I really like @deathaxe's and @jfcherng's suggestions! Any changes on this since 2020?
Here's some screenshots of one implementation I've enjoyed (from IntelliJ - don't hate me sometimes I use an IDE alright :) ):
Without selection:
With selection:
In ST 4138,
// Show Line, Column in the status bar in full length, compact or completely
// hidden. Valid values are "enabled", "compact" and "disabled"
"show_line_column": "enabled",
disable
+ custom plugin = any format
Always happy to get a new ST release! I hope there are continued improvements to the line/col number presentation though - this implementation feels slightly underwhelming. I think the biggest QOL improvements would come from (as others have already mentioned):
- Setting the line/col number to a static position more rightward in the status bar (maybe just to the left of file encoding).
- Exposing more control over the formatting of the line/col number.
In particular, the compact
option somehow doesn't look right to my eyes - seeing 45, 23
just feels like two random numbers floating there. Maybe it will grow on me. Something like 45:23
at least gives a hint that this is some kind of special notation, although I suppose it could also be mistaken for a time in certain situations.
Oh no it's already 93:75
I'm like SO late for work right now :) .
Edit: @eugenesvk has pointed out over in #3377 that it may already be possible to provide your own fully custom line/col number format by using disabled
and then writing a little plug-in.
- Setting the line/col number to a static position more rightward in the status bar (maybe just to the left of file encoding).
that would be great, though ideally this should be an option available to anything in the status bar, not just the line numbers, there is so much wasted potential in that tiny bar :)
couldn't find an open feature request for this, so opened it myself https://github.com/sublimehq/sublime_text/issues/5624
disable + custom plugin = any format
I've just made a simple plugin for custom status message. https://github.com/jfcherng-sublime/ST-CustomStatusMessage But the position of the custom status message is not good :(
This feature was added in build 4138 with the "show_line_column"
setting.