• Stars
    star
    739
  • Rank 59,139 (Top 2 %)
  • Language
    Emacs Lisp
  • Created over 12 years ago
  • Updated 7 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

The Solarized colour theme, ported to Emacs.

License GPL 3 MELPA MELPA Stable Join the chat at https://gitter.im/bbatsov/solarized-emacs

Solarized for Emacs

Solarized for Emacs is an Emacs 24bit theme making use of of the Solarized palette, developed by Ethan Schoonover.

You can find several screenshots of Solarized for Emacs here.

Solarized for Emacs supports officially Emacs 24+, but should be working under Emacs 23 as well. The theme is implemented in terms of customisations and deftheme and does not require the color-theme-package.

Installation

Solarized for Emacs is available for installation via the MELPA using package.el. Assuming you've set it up you can install Solarized like this:

M-x package-install solarized-theme

This package will install two variants of the theme; solarized-light-theme and solarized-dark-theme. You can load one of the theme variants with M-x load-theme.

To load it automatically on Emacs startup add this to your init file:

(load-theme 'solarized-light t)

or

(load-theme 'solarized-dark t)

Alternative Palettes

The intent of this theme will always be that Solarized-dark/light will give you the best possible experience. Palettes other than Solarized will never have influence over theming decisions, they are complementary.

You should not expect the complementary themes to be fully accurate or the most suitable versions of how to apply those palettes into an emacs theme. The important aspect is that the color usage should be about the same as they are with the default Solarized palette.

Colors stand out with varying amounts depending on which palette is used. This theme aims for a very soft look, violet is one of the most pronounced accent colors in the Solarized palette and that is one reason why it's rarely used by the theme. Violet in another palette might stand out less and therefore be used more often if the theme was specifically designed with that palette in mind.

The original Zenburn palette doesn't have an violet it is created by blending blue and magenta to get it to fit into the theme so it's tilted towards translating into what this theme has decided.

TLDR; While solarized-gruvbox-light might be good complement for users of solarized-light, another theme not contained in this package (gruvbox-light or whatever) might be more finely tuned in relation to the Gruvbox palette.

Customisations

Theme-specific settings

If you don't like low-contrast modeline or fringe, you can customize them either by doing M-x customize-group solarized or setting the values using elisp code:

;; make the fringe stand out from the background
(setq solarized-distinct-fringe-background t)

;; Don't change the font for some headings and titles
(setq solarized-use-variable-pitch nil)

;; make the modeline high contrast
(setq solarized-high-contrast-mode-line t)

;; Use less bolding
(setq solarized-use-less-bold t)

;; Use more italics
(setq solarized-use-more-italic t)

;; Use less colors for indicators such as git:gutter, flycheck and similar
(setq solarized-emphasize-indicators nil)

;; Don't change size of org-mode headlines (but keep other size-changes)
(setq solarized-scale-org-headlines nil)

;; Change the size of markdown-mode headlines (off by default)
(setq solarized-scale-markdown-headlines t)

;; Avoid all font-size changes
(setq solarized-height-minus-1 1.0)
(setq solarized-height-plus-1 1.0)
(setq solarized-height-plus-2 1.0)
(setq solarized-height-plus-3 1.0)
(setq solarized-height-plus-4 1.0)

Note that these need to be set before load-theme is invoked for Solarized.

Underline position setting for X

If you are using Emacs under X you might like the following setting which puts the underline below the font bottomline instead of the baseline.

Imho it enhances the general readability and also it fits well with the default solarized-high-contrast-mode-line setting which uses an slightly emphazised underline for the modeline to create one horizontal window border in the same manner as the vertical border.

(setq x-underline-at-descent-line t)

Create theme using color palette

The Solarized Face settings consist of a palette of colors with eight accents in addition to the darkest and brightest colors. Recent changes allow you to freely create theme files using different palettes instead of the Solarized color palette. It consists of two steps:

  • creating a theme file
  • loading a theme

Creating/Loading Theme Files

Select the darkest and lightest colors and the eight accents to pass to the function. This creates a theme file in .emacs.d/themes/. If you need to make minor modifications, you can override Face individually by specifying a free Sexp as the fourth argument.

Once you have a theme file, you can load it with load-theme, like solarized.

;; inspired vim's jellybeans color-theme
(solarized-create-theme-file-with-palette 'light 'solarized-jellybeans-light
  '("#202020" "#ffffff"
    "#ffb964" "#8fbfdc" "#a04040" "#b05080" "#805090" "#fad08a" "#99ad6a" "#8fbfdc"))

(load-theme 'solarized-jellybeans-light t)
;; inspired emacs's mesa color-theme
(solarized-create-theme-file-with-palette 'light 'solarized-mesa-light
  '("#000000" "#faf5ee"
    "#3388dd" "#ac3d1a" "#dd2222" "#8b008b" "#00b7f0" "#1388a2" "#104e8b" "#00688b"))

(load-theme 'solarized-mesa-light t)
;; inspired emacs's solarized color-theme
(solarized-create-theme-file-with-palette 'light 'solarized-solarized-light
  '("#002b36" "#fdf6e3"
    "#b58900" "#cb4b16" "#dc322f" "#d33682" "#6c71c4" "#268bd2" "#2aa198" "#859900"))

(load-theme 'solarized-solarized-light t)
;; wombat color-theme with misc face definition
(solarized-create-theme-file-with-palette 'dark 'solarized-wombat-dark
  '("#2a2a29" "#f6f3e8"
    "#e5c06d" "#ddaa6f" "#ffb4ac" "#e5786d" "#834c98" "#a4b5e6" "#7ec98f" "#8ac6f2")
  '((custom-theme-set-faces
     theme-name
     `(default ((,class (:foreground ,(solarized-color-blend base03 base3 0.15 2) :background ,base03))))
     `(highlight ((,class (:background ,violet))))
     `(font-lock-builtin-face ((,class (:foreground ,magenta))))
     `(font-lock-constant-face ((,class (:foreground ,blue))))
     `(font-lock-comment-face ((,class (:foreground ,base00))))
     `(mode-line
       ((,class (:foreground ,base2 :background ,(solarized-color-blend base03 base3 0.85 2)))))
     `(mode-line-inactive
       ((,class (:foreground ,base00 :background ,(solarized-color-blend base03 "black" 0.85 2)))))
     `(mode-line-buffer-id ((,class (:foreground ,base3 :weight bold))))
     `(minibuffer-prompt ((,class (:foreground ,base1))))
     `(vertical-border ((,class (:foreground ,base03)))))))

(load-theme 'solarized-wombat-dark t)

Note: If the theme file already exists, solorized-create-theme-file does not regenerate the file. If the file exists, it can be overwritten by setting the fifth argument to t.

Versioning Policy

  • This package uses semantic versioning

  • Master branch is to be considered unstable (which isn't an excuse to constantly break behaviour). Use MELPA Stable if you want fewer breaking changes.

  • Next stable version will be 2.0 because of API changes in the master branch. Regular load-theme usage is unaffected by changes.

Bugs & Improvements

Please, report any problems that you find on the projects integrated issue tracker. If you've added some improvements and you want them included upstream don't hesitate to send me a patch or even better - a GitHub pull request.

License

Copyright ยฉ 2011-2021 Bozhidar Batsov, Thomas Frรถssman, and contributors.

Distributed under the GNU General Public License, version 3

More Repositories

1

prelude

Prelude is an enhanced Emacs 25.1+ distribution that should make your experience with Emacs both more pleasant and more powerful.
Emacs Lisp
5,014
star
2

clojure-style-guide

A community coding style guide for the Clojure programming language
3,978
star
3

projectile

Project Interaction Library for Emacs
Emacs Lisp
3,851
star
4

emacs-lisp-style-guide

A community-driven Emacs Lisp style guide
1,053
star
5

zenburn-emacs

The Zenburn colour theme ported to Emacs
Emacs Lisp
951
star
6

crux

A Collection of Ridiculously Useful eXtensions for Emacs
Emacs Lisp
807
star
7

helm-projectile

Helm UI for Projectile
Emacs Lisp
322
star
8

super-save

Save Emacs buffers when they lose focus
Emacs Lisp
273
star
9

powerpack

Some useful extensions to the core Ruby classes
Ruby
270
star
10

emacs.d

My personal Emacs configuration
Emacs Lisp
204
star
11

persp-projectile

Projectile integration for perspective.el
Emacs Lisp
110
star
12

guru-mode

Learn to use Emacs the way it was meant to be used (the Emacs guru way)
Emacs Lisp
100
star
13

emacs-dev-kit

An advanced self-contained Emacs configuration suitable for many software developers (deprecated)
Emacs Lisp
95
star
14

beamer-torino-theme

Torino, a pretty theme for LaTex Beamer
Emacs Lisp
38
star
15

lein-annotations

Display comment annotations in your project
Clojure
12
star
16

emacsredux

Emacs Redux is a blog dedicated to the One True Editor
HTML
11
star
17

cv

My professional CV in LaTeX
TeX
10
star
18

cl-99-problems

Solutions to the 99 Lisp problems in Common Lisp
Common Lisp
10
star
19

activerecord-extra-validators

Some nice additional validators for ActiveRecord
Ruby
9
star
20

java-in-action-lectures

The lectures from the "Java in Action" programming course
9
star
21

advent-of-code2021

Advent of Code 2021, Clojure Edition
Clojure
8
star
22

legacy-octopress-blog

My personal blog
HTML
8
star
23

batsov.com

My personal blog
Ruby
7
star
24

metaredux

HTML
7
star
25

master-thesis

My Master university degree thesis
Emacs Lisp
5
star
26

zshrc

My personal zsh setup
5
star
27

docs.projectile.mx

Projectile's documentation site
Handlebars
4
star
28

hard-cider

A demo projecto to showcase CIDER
Clojure
3
star
29

slim-lint

Configurable tool for analyzing Slim templates
Ruby
3
star
30

presentations

Presentations I created for various occasions
2
star
31

blog

My personal blog
Ruby
2
star
32

emacsredux-legacy

Emacs Redux
HTML
1
star
33

praxis

Praxis makes perfect!
OCaml
1
star
34

ocaml.org

The official OCaml website.
OCaml
1
star