fix line highlight in terminal mode