package miaou-core

  1. Overview
  2. Docs
Miaou core/widgets (no drivers, no SDL)

Install

dune-project
 Dependency

Authors

Maintainers

Sources

v0.5.2.tar.gz
md5=60a3b9f181f24572a06a9492532bfdda
sha512=fcc35a275066be2900e6201782faf47503076fa4640f08cf78067835a6f447b74613009e55b2ac799adb7ca46f1bffa261fc5971753f2cc3c6bef327511c7ef6

doc/miaou-core.style/Miaou_style/Builtin_themes/index.html

Module Miaou_style.Builtin_themesSource

Built-in themes inspired by popular color schemes.

These themes are embedded directly in the library for easy access without requiring external files. Themes can be listed with list_builtin and loaded with get_builtin.

Available themes:

  • Dark: catppuccin-mocha, dracula, nord, gruvbox-dark, tokyonight, opencode, oled
  • Light: catppuccin-latte, nord-light, gruvbox-light, tokyonight-day

The opencode and oled themes use borderless style (default_border_style: "None") for a clean, minimal look. The oled theme features true black background (#000000) with soft pastel colors, optimized for OLED screens to save battery and reduce eye strain.

Sourcetype builtin_theme = {
  1. id : string;
    (*

    Unique identifier (e.g., "catppuccin-mocha")

    *)
  2. name : string;
    (*

    Display name (e.g., "Catppuccin Mocha")

    *)
  3. description : string;
    (*

    Short description

    *)
  4. dark_mode : bool;
    (*

    Whether this is a dark theme

    *)
  5. borderless : bool;
    (*

    Whether this theme uses no borders

    *)
}

Theme descriptor with metadata

Theme Discovery

Sourceval list_builtin : unit -> builtin_theme list

List all available built-in themes with metadata

Sourceval list_builtin_ids : unit -> string list

List just the theme IDs (for quick iteration)

Sourceval get_info : string -> builtin_theme option

Get theme info by ID

Sourceval is_builtin : string -> bool

Check if a theme ID is a built-in theme

Theme Loading

Sourceval get_builtin : string -> Theme.t option

Load a built-in theme by ID. Returns None if the ID doesn't match a built-in theme.

Example:

  match Builtin_themes.get_builtin "dracula" with
  | Some theme -> Style_context.set_theme theme
  | None -> (* fallback to default *)
Sourceval get_json : string -> string option

Get the raw JSON string for a built-in theme (for debugging/export)