1

I was modifying an email template and I noticed that when moving the cursor over a piece of code it changed.

Here is a screenshot from before:

enter image description here

and after:

enter image description here

Vim version is 7.4 on Ubuntu 16.04. Any idea what would make something like this happen?

1
  • This looks like a problem in your terminal emulator. Which terminal are you using? What's the TERM environment variable set to? You can also try following these steps, to make sure it's not a plugin or something in your vimrc. May 19, 2017 at 15:01

1 Answer 1

1

Your terminal window isn't configured to display colors properly.

You can test whether this is the case by disabling color in vim and see if the problem goes away.

Disables color features in vim:

:syntax off
:set nohlsearch
:set t_Co=0

If this fixes it but you want color support, the next step I suggest is to check your terminal emulator and shell configuration for ANSI support.

3
  • it displays the colors properly, the photos are from when trying to replicate the behavior and ubuntu probably didn't recognized the code because i named the file test instead of test.php May 19, 2017 at 14:56
  • but if i disable color features like you said it seems to work properly May 19, 2017 at 15:02
  • try this before starting vim: export TERM=xterm
    – Jim U
    May 19, 2017 at 15:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.