hadalized color theme build
Python package with CLI to build hadalized-style application themes.
Introduction
The application can build any theme conforming to the hadalized Palette
schema for any application with a BuildConfig and appropriate theme
template.
The builtin hadalized color palettes
are defined as oklch color values. Application theme templates are rendered
with the appropriate color type (e.g., hex values for neovim). Under the hood
the coloraide python package is used to transform between colorspaces and fit
to gamuts.
Creating a theme builder arises from the desire to use the OKLCH color space as the basis for any application color theme. When developing the palette, it quickly becomes tedius to manually convert oklch values to their hex equivalents.
The builder primarily targets the neovim colorscheme files in hadalized.nvim, as that is the editor we primarily use.
Installation
We recommend installing the cli application via uv
uv tool install hadalized
Example CLI Usage
Assuming uv is installed,
uv run --exact hadalized build --out="build"
will produce rendered theme files for all builtin applications in ./build.
If the tool is installed via uv tool install or if the virtualenv is activated
# To build neovim color themes
uv build neovim --out=colors # -> colors/hadalized*.lua
# To build all color themes, with outputs to `./build`
uv build
Development
Assuming uv and just are installed
uv sync --locked
source .venv/bin/activate
# make changes
just fmt
just check
just test
# commit changes
Roadmap / TODOs
- Consider removing the "in-memory" cache functionality.
- (A) Add ability to map named colors such as
redto an abstracted name such ascolor1, similar tobase16. Use these abstracted names color theme templates. This might be painful to work with in practice, as one has to keep the mapping in their head. - (B) As an extension of (A), consider lightweight pandoc inspired features
where an intermediate and generic theme can be defined and referenced in
editor templates. For example, allow a user to define
integer = "blue"and referencetheme.integerto color neovimIntegerhighlight groups.
Metadata
Release files for hadalized 0.6.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| hadalized-0.6.0-py3-none-any.whl | Python 3 | none | any | Details |
Release files / hadalized-0.6.0-py3-none-any.whl
| Download URL | hadalized-0.6.0-py3-none-any.whl |
|---|---|
| Size | 49.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c007490050d6ef302a77ac95f94eb9a1781ea419ecd64fc8756a4c202ff5f3ed
|
|
BLAKE2b-256 checksum How to use checksums |
ff9db80834b07a63c0021544f10a97eee8ced0e47addde0e0e8e0bbdea67158c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.9.30 {"installer":{"name":"uv","version":"0.9.30","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|