Giter Club home page Giter Club logo

snow's Introduction

snow

a blue-tinted winter vimscape


screenshot of the snow vim theme, light version


screenshot of the snow vim theme, dark version

background
snowy noon
name
icewine red-purple
background
snowy midnight
highlight
snowy day
type
poinsettia red
highlight
snowy night
comment
snowy dusk
special
lichen gold
comment
snowy dusk
text
snowy twilight
statement
conifer green
text
snowy evening
cursor
snowy night
meta-statement
iceberg green-blue
cursor
snowy day
search
light lichen
constant
frost blue
search
dark icewine

because red is the color of life, reddish text is for...

     names, which give life to abstractions (like variables and functions)

     types ("meta-names" ), such as variable type (int, char...) or storage class (static, register...)


because gold is a special color, gold text is for...

     specials (elements that unlock special features), such as delimiters and debug statements


because green is the color of proceeding with action, greenish text is for...

     statements (the magic "action words" of code), such as conditions (if, then...) or loops (for, do...)

     meta-statements ("meta-actions", or "meta-magic" ), such as macros and "include module" statements


because blue is the calm color of sea and sky, evoking enduring constancy, blue text is for...

     constants (values that are fixed in place), such as booleans, integers, and strings

installation

If you don’t have a preferred plugin helper, consider trying vim-plug, which can be installed (on Unix-like systems) with:

curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
  https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim

Having installed vim-plug, snow can be installed by adding the following to the top of your vimrc...

call plug#begin('~/.vim/plugged')
Plug 'nightsense/snow'
call plug#end()

...then restarting vim, followed by running :PlugUpdate (at the vim command line).

activation

For a snow day, add the following to vimrc:

colorscheme snow
set background=light

For a snowy evening:

colorscheme snow
set background=dark

To set the background automatically based on the time at which vim is launched:

colorscheme snow
if strftime('%H') >= 7 && strftime('%H') < 19
  set background=light
else
  set background=dark
endif

...which activates the light version of snow during the day (defined here as 7AM-7PM), dark version at night.

The night-and-day plugin can switch themes and/or backgrounds automatically, using absolute or sun-relative time.

status line themes

snow comes with themes for airline and lightline, which can be activated with the following vimrc code:

airline lightline
light let g:airline_theme='snow_light' let g:lightline = { 'colorscheme': 'snow_light' }
dark let g:airline_theme='snow_dark' let g:lightline = { 'colorscheme': 'snow_dark' }

Status line themes can be added to the time-based snippet above:

colorscheme snow
if strftime('%H') >= 7 && strftime('%H') < 19
  set background=light
  let g:lightline = { 'colorscheme': 'snow_light' }
else
  set background=dark
  let g:lightline = { 'colorscheme': 'snow_dark' }
endif

terminal vim

colors

Terminals/multiplexers with true-color support (see list) can display the exact snow colors.

In most cases, the only vimrc setting you need is:

set termguicolors

In some cases you'll also need:

let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum"
let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum"

If termguicolors is not set, terminal vim will fall back to an xterm-color approximation of snow.

cursor shape

To set mode-specific cursor shapes in terminal vim, see the Vim Tips Wiki.

For instance, to set cursor shapes in vte-compatible terminals, you could add to vimrc:

let &t_SI = "\<Esc>[6 q"
let &t_SR = "\<Esc>[4 q"
let &t_EI = "\<Esc>[2 q"

...which sets the cursor to a vertical line for insert mode, underline for replace mode, and block for normal mode.


released under the MIT license
generated with Colortemplate
snowflake macrophoto by Olga & Alexey (CC BY-NC 2.0)

snow's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.