DEV Community

Heiker
Heiker

Posted on

Rubber themes for vim

A collection of color schemes (just two for now) with minimal amount of highlighting for Vim.

Inspiration

Inspired by the same principles of the alabaster color scheme for Sublime Text:

  • Doesn’t highlight standard language keywords (if, else, function, etc). They are usually the most obvious part of any program.

  • Highlights comments. Most schemes try to dim comments by using low-contrast greys. If the code is complex enough that it deserves an explanation then it’s that explanation then we should see and read it first. It would be a crime to hide it.

  • Doesn’t use font variations. It’s hard to scan code when it jumps between normal, bold and italics all the time. Also, not all fonts provide bold/italics variants.

  • Minimal amount of rules means you can consciously use them to look for the exact piece of information you need. You can remember easily all the rules, e.g. if you need to look for a string you know that you’re looking for a green token. And all the strings really pop out because there are not many other things highlighted.

  • Only highlight things that parser could identify reliably. When it’s not reliable, your brain spends precious brain cycles to re-check everything it sees on the screen.

How does it look like

rubber

A port of rubber-theme for VSCode.

preview rubber

rubber-owl

Same thing, but using the color palette from Sarah Drasner's Night Owl.

preview rubber-owl

Get it now

GitHub logo VonHeikemen / rubber-themes.vim

Collection of color schemes with minimal amount of highlighting for Vim.

Rubber themes

A collection of color schemes with minimal amount of highlighting for Vim. Based on rubber-theme for VSCode.

Inspired by the same premise of the alabaster color scheme for Sublime Text it defines just four classes:

  • Strings
  • Known constants (numbers, symbols, booleans)
  • Comments
  • Functions

Getting Started

Available themes

  • rubber
  • rubber-owl

Installation

Using vim-plug

Plug 'VonHeikemen/rubber-themes.vim'
Enter fullscreen mode Exit fullscreen mode

Activation

" For vim > 8
if (has("termguicolors"))
 set termguicolors
endif

" For Neovim 0.1.3 and 0.1.4
let $NVIM_TUI_ENABLE_TRUE_COLOR=1

syntax enable
colorscheme rubber
Enter fullscreen mode Exit fullscreen mode

Screenshots

  • rubber

background: #21252B

base colors for terminal

preview rubber

  • rubber-owl

background: #011627

base colors for terminal

preview rubber-owl




Top comments (0)