6

I'm using vim-perl6 for syntax highlighting, but I'd like to adjust the color of variable sigils so that they are less standout. Perhaps, make them look pale or something. How do I do that? Thanks.

Christopher Bottoms
  • 11,218
  • 8
  • 50
  • 99
cowbaymoo
  • 1,202
  • 5
  • 14
  • 2
    What did you try? – romainl Jun 02 '18 at 18:12
  • 2
    A vim syntax file will typically just identify different parts of the language syntax (eg, `Keyword`, `Number`, `Constant`, or for variables, probably `Identifier`). It is then the job of your colorscheme file to color those different things... So you probably want to change something in your colorscheme file, not in the vim-perl6's syntax file. – elcaro Jun 03 '18 at 10:33
  • You'll need a modified (or additional) syntax file as well, since `perl6.vim` links `p6BareSigil` to `p6Variable`, which itself is linked to `Identifer`. You'll want to undo the link of `p6BareSigil` so that your colorscheme can colorscheme can color it specifically, or link it to something appropriate that your color scheme already colors the way you want. – chepner Jun 03 '18 at 14:15
  • Just tried out @chepner 's suggestion, and it seems to do what I want now. Here's what I did: 1) comment out the line: `HiLink p6Variable Identifier` in `perl6.vim` 2) Modify the colorscheme file I use, and add `hi p6Variable ctermfg=darkgrey` and `hi p6Variable guifg=darkgrey` Thanks! – cowbaymoo Jun 04 '18 at 00:48
  • @cowbaymoo You should post that as an answer; it is allowed (even encouraged!) to provide an answer to your own question. – chepner Jun 04 '18 at 13:20

1 Answers1

4
  1. Comment out the line: HiLink p6Variable Identifier in perl6.vim
  2. Modify the colorscheme file I use (in my case, on MacOS, I copied it from /usr/share/vim/vim80/colors/ to ~/.vimrc/colors/), and add to it:
    • hi p6Variable ctermfg=darkgrey
    • hi p6Variable guifg=darkgrey
cowbaymoo
  • 1,202
  • 5
  • 14