Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

All of a sudden all the text in my vi editor is highlighted.I have no idea how this happened. Please help.

share|improve this question
add comment

2 Answers

up vote 5 down vote accepted

Type /asdfjhanlskfh or something similar that starts with a slash.

Chances are you have searched for a character (/.) and are using vim instead of vi.

share|improve this answer
    
Thank you that worked for me!! But I'm using vi and not vim. It's on Fedora –  Pavitar Mar 31 '11 at 12:51
2  
@Pavitar: try vi --version from the command line, or follow the symlinks of `which vi` –  MattBianco Mar 31 '11 at 12:54
    
Ohh yea..My vi is set as an alias for vim.thank you. +1 –  Pavitar Mar 31 '11 at 13:00
add comment

This could be a variety of things. Its most likely because you are visual select mode (which you get to by pressing the 'v' key in command mode). Try pressing Esc twice to see if that gets you out of it. Another clue on this would be that it would say -- VISUAL -- in the status line.

If that's not it, giving us a bit more info would be in order, such as what you were doing at the time, if closing the file and reopening fixes it, etc.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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