Skip to content
Jean Guyomarc'h edited this page Sep 17, 2020 · 3 revisions

A word about Edje

Edje is the theming engine of the EFL, the GUI toolkit used by Eovim. It consists in a descriptive language that is compiled into a theme file (.edj) and loaded at run-time by Eovim. Thanks to signals and scripts mechanisms, Eovim can interact with its theme, which pretty much lives as an autonomous plug-in.

Theme configuration

The theme has been designed to offer a richer user experience than what neovim offers. They are subjective, and therefore not universal. They can be enabled/disabled on demand by setting variables from your vimscript configuration. Note that they are read only when eovim starts!

Visual Bell

Neovim may send visual_bell events. Set a strictly positive value to enable:

let g:eovim_theme_bell_enabled = 1

This is disabled by default in the theme default.

React to key press

Every time you press a key, Eovim's theme will send visual indicator. Set a strictly positive value to enable:

let g:eovim_theme_react_to_key_presses = 1

This is enabled by default in the theme default.

React to caps lock

Because caps lock cause different commands to be run, it may come handy to be notified when caps lock are enabled. Set a strictly positive value to enable:

let g:eovim_theme_react_to_caps_lock = 1

This is enabled by default in the theme default.

Completion styles

Although not directly defined in an edje file, you can customize the colors used by Eovim in the completion popup directly from vimscript. You can do this by setting the following variable (below is its default value):

let g:eovim_theme_completion_styles = {
	\ 'default': 'font_weight=bold color=#ffffff',
	\ 'm': 'color=#ff00ff',
	\ 'v': 'color=#00ffff',
	\ 'f': 'color=#ffff00',
	\ 't': 'color=#0000ff',
	\ 'd': 'color=#0000ff',
	\}

The keys are related to vim's complete items. The default keys defines markup to be used to any kind. The other keys are style specific to a given kind value. All the values associated with keys presented above is EFL markup.

Changing theme

Eovim currently ships with one theme, called default. If you happen to have written a theme, you can provide it to Eovim via the --theme option.

Writing your own theme

Writing an edje theme requires some coding. You can try the EFL documentation:

After you have some knowledge of the Edje theme language, you can starting digging into Eovim's default theme:

Once your edje files are ready, you can provide the resulting compiled .edj file to Eovim via the --theme option.