0

I can't find a setting to turn off that small pixel indentation when cursor is highlighting the line you're on. It makes it hard to try to type text to align when the line itself is indented a few pixels in. I want the line to be visually highlighted but with no indentation. It's really annoying that way.

Drew
  • 75,699
  • 9
  • 109
  • 225

1 Answers1

0

There is no setting to deliberately visually indent the highlighted line merely because it is highlighted. Instead it sounds like the face used during highlighting doesn’t match the face used for the rest of the document.

Use M-x customize-face to view and potentially edit the hl-line face. Make sure that it only has attributes that won’t affect the size of the text.

db48x
  • 15,741
  • 1
  • 19
  • 23
  • 1
    The `:box` setting does this on my system, so make sure your `hl-line` face doesn't have a `:box`. (see https://emacs.stackexchange.com/questions/47002/adding-box-around-text-without-changing-the-text-width) – amitp Apr 03 '22 at 04:17
  • Or you could add a transparent box around all other text :) – db48x Apr 03 '22 at 04:43