Subject: How to turn off all colors - Vim Tips Wiki (fwd) Below is a recipe which might work. I have removed stuff that is irrelevant. Note, web page address appears in headers. The marker for suppressed material is "< ... />". oo--JS. ---------- Forwarded message ---------- Subject: How to turn off all colors - Vim Tips Wiki X-URL: http://vim.wikia.com/wiki/How_to_turn_off_all_colors #Edit Vim Tips Wiki (en) copyright Vim Tips Wiki Atom feed < ... /> Vim Tips Wiki Vim Tips Wiki Navigation * Community portal * To do * Recently updated [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] + VimTip1669 + Searching for files in a directory listing + Change font + Setting the font in the GUI + Folding + Indent text object + Preserve missing end-of-line at end of text files * Popular tips [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] + Search and replace + Best Vim Tips + File format + Indenting source code + Open vimrc file + Change the color scheme + Converting tabs to spaces [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] Random Page [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] Wiki Activity Watchlist Recent changes [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] * 0 Talk * How to turn off all colors Edit [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] * History Please review this tip: * This tip was imported from vim.org and needs general review. * You might clean up comments or merge similar tips. * Add suitable categories so people can find the tip. * Please avoid the discussion page (use the Comments section below for notes). * If the tip contains good advice for current Vim, remove the {{review}} line. Tip 675 Printable Monobook Previous Next created March 12, 2004 =B7 complexity intermediate =B7 author mdmiller= =B7 version 6.0 __________________________________________________________________ If you're like me, you don't want a colorful editor. I spent hours looking for a "turn off all those colors right now!!" command and I couldn't find any help. After some poking around for a while, I found the commands you need. Just put these at the end of your vimrc file. syntax off set nohlsearch set t_Co=3D0 If you don't have a vimrc file, simply create one in your home directory. Comments [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] Edit If you want coloring sometimes but want an easy way to turn it off occasionally (while editing) type :set syntax=3D __________________________________________________________________ What's wrong with :syntax off __________________________________________________________________ With "syntax off" alone Vim will still use colored highlighting when you search for things. For those who simply think colors are yucky, that's reason enough. For me, there's also the fact that I usually los= e interest in a search term a few minutes after I find it. (i.e. find where a variable is used, examine the use of that variable, then move on to something unrelated.) I find it disconcerting to have something highlighted when it is no longer important to me. Yes, I know there is a way to turn off the highlight from the previous search, but it takes more keystrokes than I want to mess with. And I could simply search fo= r something that isn't in the file I'm editing, but such a kluge of an answer disturbs me. So the next thing I tried was "syntax off" + "set t_Co=3D0", and that made vim comepletely colorless, but search result highlighting was accomplished through alternate means - I believe bold or italics or some such thing. To clarify what I wrote in the previous paragraph, th= e emphasis of a currently uninteresting search result is the thing I dislike, not the means of the emphasis. So this option was not good enough for me. I also tried "syntax off" + "set nohlsearch". This option is nice most of the time, but vim still used colors to emphasize some of its error messages. By the time I discovered this, I was so frustrated with vim that I wanted to beat it into submission. I wanted no colors, no emphasized text, nothing that looked at all different than traditional vi. (I know, this is a silly emotional reaction. But when you use technology all day, it needs to be comfortable. And "comfort" is a wor= d that can only be completely defined in an emotional context.) For my purposes, "syntax off" + "set nohlsearch" + "set t_Co=3D0" is t= he only satisfying option. Leaving out any ingredient gives me something that is not good enough. Given that "syntax off" + "set t_Co=3D0" will produce a colorless vim, perhaps I did not choose the best title for m= y tip, but people seem to be enjoying it, so I have no regrets. Now you know what is wrong (from my personal point of view) with just typing "syntax off". __________________________________________________________________ Read more * Suppose the filetype is en. Then, write a file ~/.vim/syntax/en.vi= m with contents as follows: syn re Highlight special filetype docs * Sometimes (especially when programming in lisp dialects) it's useful to easily find matching parenth Highlight text inside matching parentheses * For some scripts it might be useful to detect, whether a specific position in a buffer is inside of Check for comments independent of filetype Retrieved from "http://vim.wikia.com/wiki/How_to_turn_off_all_colors" Related Categories Categories: Review | VimTip | Syntax [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] Add category < ... /> Pages on Vim Tips Wiki [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] Add a Page 1,594pages on this wiki < ... /> Recent Wiki Activity * [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] Searching for files in a directory listing edited by Fritzophrenic 12 hours ago * [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] Change font edited by Fritzophrenic 13 hours ago * [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] Setting the font in the GUI edited by Fritzophrenic 13 hours ago * [yH5BAEAAAEALAAAAAABAAEAQAICTAEAOw%3D%3D] Folding edited by AccoladeA 18 hours ago < ... /> Wikia Inc Navigation < ... /> Subject: Linux Commando: How to disable vim syntax highlighting and coloring (fwd) And more, and i have not yet gone to the source, the vim page ;) In the comments a fellow member of the No Colorization League shouts a plangent thanks. oo--JS. ---------- Forwarded message ---------- Subject: Linux Commando: How to disable vim syntax highlighting and coloring X-URL: http://linuxcommando.blogspot.com/2008/05/how-to-disable-vim-syntax-highlighting.html #Linux Commando - Atom Linux Commando - RSS Linux Commando - Atom < ... /> Linux Commando This blog is about the Linux Command Line Interface (CLI), with an occasional foray into graphical user interface territory. Instead of just giving you information like some man page, I hope to illustrate each command in real-life scenarios. < ... /> Saturday, May 31, 2008 How to disable vim syntax highlighting and coloring Syntax highlighting is my top annoyance in using vi/vim. Syntax highlighting is just a fancy term meaning that the text editor will auto-color parts of a text file according to some rules that makes sense to it, using some default color scheme. To be precise, only vim, not vi, has syntax highlighting. vi has a 2 color scheme only: background and foreground. Yet, on my Centos 4 system (and many other distros), the vi command is just a soft link to vim. Syntax highlighting is useful, and usually nothing to complain about. However, I find the default vim color scheme to be an eye-killer for me. If you are already in vi/m, you can disable it by typing :syntax off (and press the return key). To re-enable coloring, type :syntax on (and press the return key). If you want to permanently disable syntax highlighting, insert this in your ~/.vimrc file: syntax off Note that even with vim, there can be different versions. On my Debian Etch system, the vim is vim.tiny, and it does not support syntax highlighting. So, you don't need to explicitly disable syntax highlighting. StumbleUpon Toolbar Posted by Peter Leung at 4:55 PM 4 comments: Sync said... Turns out there's an inordinate amount of bogus crap that goes on in vim in this regard, and "syntax off" is insufficient to disable it all. Try these in your .vimrc as well: syntax off let g:loaded_matchparen=1 set nocp set noincsearch set nohlsearch set noshowmatch These will turn off the annoying highlighting behaviors with matching brackets, search matches, and the horrendous "interactive" search. vi wasn't broke, I don't know why they insist on the feeping creaturism in this monster called "vim" or what made them think it was sufficient to replace the original vi. July 24, 2008 11:31 PM [icon_delete13.gif] Anonymous said... HURRAH!!! No more bleeding eyes and cursing at the screen, and best of all, I can use vi on Linux again, instead of having to bail for (insert different editor here)! Thank you, thank you, thank you! August 19, 2009 11:35 AM [icon_delete13.gif] SWD said... The advice in this blog posting is very helpful. But I'm still having a problem with line numbering. If I do ":set number" the line numbers are almost illegible. Given that there must be many people who, like me, have difficulty distinguishing certain colors, I'm surprised there isn't a overarching accessibility setting to tell vi/vim to use just one color. August 26, 2009 6:01 AM [icon_delete13.gif] Nerdmaster said... You know, you can change color schemes pretty easily.... Syntax highlighting (for me) is too critical to drop just because the default scheme isn't what I want. September 3, 2009 2:46 PM [icon_delete13.gif] < ... /> CONTACT ME: commandolinux@gmail.com Feedjit Live Blog Stats Blog Archive * |> 2010 (1) + |> April (1) o How to insert a file at a specific line and column... * |> 2009 (9) + |> November (1) o Fun with Date Arithmetic + |> July (2) o How to move print jobs from one printer queue to a... o Search and replace line feeds using emacs + |> June (1) o loook: A light-weight text search tool for OpenOff... + |> May (5) o Is PHP supported on my Web Server? o More on Inserting Arguments from Previous Commands... o Open a file from the command line using its defaul... o Find all (non-)empty files in a directory o A surefire shortcut to Insert the Last Argument of... * v 2008 (51) + |> December (1) o Auto Start Applications at Login to GNOME Desktop + |> November (3) o How to increase number of disk mounts before next ... o How to open and close the CD DVD tray o Two additional ways to tail a log file + |> October (1) o How to disable SSH host key checking + |> September (3) o Upgrade individual packages for Debian-based syste... o How to get the process start date and time o How to find and delete all hard links to a file + |> August (3) o How I repaired a corrupted grub menu.lst config fi... o How to show apt log history o Learn more about a command when no man info page i... + |> July (3) o Pondus: A personal weight management software o How to do reverse DNS lookup o How to count number of files in a directory + |> June (7) o Dual pane Linux file managers: mc and emelfm o Run emacs in batch mode to byte-compile elisp file... o Create File of a Given Size ... with random conten... o Smart case-insensitive, incremental search using v... o How to find a file and cd to its dirname using com... o Show progress during dd copy o How to number each line in a text file on Linux + v May (12) o How to disable vim syntax highlighting and colorin... o Use the OR operator in grep to search for words an... o Root edit a file using emacs in the same session o Delete Windows/DOS carriage return characters from... o Run ifconfig as non-root user for read-only access... o Ping or nmap to identify machines on the LAN o How to indent lines in text files using sed, awk, ... o How to convert text files to all upper or lower ca... o How to prevent Linux man pages from clearing after... o bash quicksand 2: Quotes needed in string tests o How to Display Routing Table o Compare Directories using Diff in Linux + |> April (5) o Using awk to extract lines in a text file o Fast way to execute sequential commands from the c... o Quick hex / decimal conversion using CLI o Extracting columns and fields from a text file o Use sed or perl to extract every nth line in a tex... + |> March (7) o bash quicksand 1: whitespaces in variable assignme... o Trick grep not to report itself in a process searc... + |> February (5) + |> January (1) * |> 2007 (21) + |> December (3) + |> November (8) + |> October (10) < ... />