[SOLVED] Line gutter covers the cursor


Hi everyone,

I’m having problems with the line gutter in the editor.
Sometimes the cursor, when positioned at the beginning of the line, gets under line gutter.
It’s really annoying as it gets lost when I’m moving from line to line.
I have made a gif that shows the problem. As you can see resizing the width of the tree panel on the left somehow fixes it, but I still have to find the perfect width.



Does this happen when you start Atom from the command line with atom --safe?


No, it doesn’t. Could it be that some plugin or theme that interact with the gutter make it so it overlaps the cursor at the beginning of the line?


I don’t know what’s happening, but if it doesn’t happen in safe mode, that means that you should be able to fix it by disabling some aspect of your local configuration. You will have to do some hunting.


Ok, I think I’ve made it. I’ve tried to compare the syntax theme I use, one-dark and monokai (my current). It seems the latter has the cursor with border-left only 1px, which on some atom width it goes under the gutter.
The gutter also almost eats the indent lines as well.
I see it’s a pixel perfect race every time you move the pane, so I get it might not be easy to fix on atom.

As a workaround I’ve edited my style.less with the following rules, which can be used either or both.

// this also adds a tiny gap between selected lines and the line numbers
atom-text-editor .lines {
    padding-left: 1px;

// this also enlarge the cursor (but as much as the one-dark syntax cursor)
atom-text-editor .cursor {
    border-left-width: 2px;