Stefan Monnier writes: > So maybe a simple fix is the patch below, but I'm not sure it's always > the right thing to do (and the width won't be automatically updated when > the (line-number-display-width) changes). [...] > - (ncols (/ window-width font-width))) > + (ncols (- (/ window-width font-width) (line-number-display-width)))) I tried this patch in Emacs 28, and it didn't seem to help much. To test emacs -Q M-x global-display-line-numbers-mode RET M-x term RET RET emacs -Q -nw