>> Would you be satisfied with changing the background color for >>spaces? Step 1: > > Ah, that's an idea. Just "/ " to search for spaces (assumes > highlighting's turned on), and they'll all be highlighted. He wants to > turn off highlighting, just "/qqq" or something. > > > Else maybe tweak the font to change space to · or something. > Thing is, change the font to something else, and that goes away, and > he'd have to tweak the font for that as well. > > Eg, if he's using Lucida console 10pt, make a copy of the font, rename > to something else ("Lucidaspace" or whatever), edit the font to change > the space char, then when you want visispaces, just font your way to > that. Want invisispaces again, change back to the normal Lucida font.
I prefer "/;;" to turn off highlighting. the keys are right next to each other and never happen in any languages I use. For spaces, maybe not exactly the same thing, but I have a .vim to color every three out of four leading spaces as magenta underline (in a non-expandtab file). The file also points out a lot of other spacing issues. Activate this anywhere that doesn't have a strict real-tab rule and you'll see all the inconsistancies light up. The blue underlines between words are ok and just there to help line up widely spaced tables. I should probably add something to ignore the two spaces between sentences in prose. odd_space.vim: syn match newtab "[\t]\+$" containedin=ALL syn match spacereturn "[ ]$" containedin=ALL syn match spacetab "[ ]\t"me=e-1 containedin=ALL syn match tabspace "\t[ ]\+"lc=1 containedin=ALL syn match tabtab "[ -'*-Z^-z|~]\t\t\t*[ -'*-.0-Z^-z|~]"lc=1,me=e-1 containedin=ALLBUT,cComment syn match leadspace "[ ][ ]"lc=1 contained syn match pairspace "[ ][ ]"hs=s+1 contained nextgroup=pairspace,leadspace syn match quadspace "[ ][ ][ ][ ]"hs=s+1 contained nextgroup=quadspace,pairspace,leadspace syn match pairstart "^[ ][ ]"hs=s+1 nextgroup=quadspace,pairspace,leadspace syn match quadstart "^[ ][ ][ ][ ]"hs=s+1 nextgroup=quadspace,pairspace,leadspace syn match spaces "[^ ][ ]\{2,}"lc=1 hi spacetab ctermfg=Red guifg=red gui=underline cterm=underline hi tabspace ctermfg=Red guifg=red gui=underline cterm=underline hi spacereturn ctermfg=Red guifg=red gui=underline cterm=underline hi newtab ctermfg=Blue guifg=#8888FF gui=underline cterm=underline hi tabtab ctermfg=Blue guifg=#444488 gui=underline cterm=underline if &expandtab == 0 hi quadspace ctermfg=Magenta guifg=#440044 gui=underline cterm=underline else hi link quadspace Normal endif hi link pairstart pairspace hi link quadstart quadspace hi spaces ctermfg=DarkRed guifg=#550000 gui=underline cterm=underline hi pairspace ctermfg=Yellow guifg=#FFFF00 gui=underline cterm=underline hi link leadspace pairspace -- _ ( \ _ \ /_ / _ _ Jason Weber Glendale, CA \|(\/)())) \/\/(-/_)(-/( http://www.imonk.com/baboon [EMAIL PROTECTED] // [EMAIL PROTECTED] (/