How to print VIM current color scheme?
Asked Answered
L

3

28

My color file is quite complicated. I think it detects my term and generates color values on the fly.

Is there any way I can print out the generated colors?

Luna answered 19/7, 2012 at 3:6 Comment(0)
M
29

This command will open a new window containing all highlight group names, displayed in their own colour:

:so $VIMRUNTIME/syntax/hitest.vim

or

:runtime syntax/hitest.vim

Then this command will turn it into an equivalent HTML file (note capital Tee Oh)

:TOhtml

Save the file and print it out in the usual way from your favourite browser.

Monotype answered 20/7, 2012 at 16:4 Comment(2)
Thanks! This is even better than last answer ;)Luna
BTW: An easier command to use is :runtime syntax/hitest.vimCarey
T
52
  • Type :color to view current color-scheme.
  • Type :hi to list all color groups.
  • Type :hi Statement to view color definations for Statement. (change Statement to what you want)
Truism answered 19/7, 2012 at 3:42 Comment(1)
To know the value of Statement, see Revealing Syntax Groups section in this vimcasts.org/episodes/creating-colorschemes-for-vim.Fini
M
29

This command will open a new window containing all highlight group names, displayed in their own colour:

:so $VIMRUNTIME/syntax/hitest.vim

or

:runtime syntax/hitest.vim

Then this command will turn it into an equivalent HTML file (note capital Tee Oh)

:TOhtml

Save the file and print it out in the usual way from your favourite browser.

Monotype answered 20/7, 2012 at 16:4 Comment(2)
Thanks! This is even better than last answer ;)Luna
BTW: An easier command to use is :runtime syntax/hitest.vimCarey
C
1

I have Vim 8 you use :colo, :color or :colorscheme

Consciousness answered 18/5, 2020 at 21:47 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.