Skip to content

skvggor/acag

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

acag icon

acag

article cover art generator

A native desktop app that generates article cover art in an Omakase / Japanese-constructivist style: five aspect ratios (square, link, wide, portrait, banner), six themes, five patterns, three layouts, a live preview, exported up to 4K PNG (plus the source SVG).

the acag app: controls on the left, live preview on the right

editorial layout, terracotta theme bloco layout, sumi theme ma layout, ai theme

a 1.91:1 link / Open Graph cover, the format LinkedIn and other platforms use for shared articles

The idea

Built around Omakase (お任せ, "I leave it to you", the sushi chef's choice) and the geometry of traditional Japanese patterns (wagara, 和柄), tempered with bold, structural, constructivist typography. The result is calm but assertive: a huge Montserrat Black title, a lot of Ma (negative space), and a quiet wave "seal".

The Japanese identity comes only from geometry and color; there are deliberately no Japanese glyphs in the artwork. It shares its design language (themes, wagara, the sumi-ê palette) with skvggor.dev and waka-readme.

Features

  • 6 sumi-ê themes: terracotta 赤土 · sumi 墨 · matcha 抹茶 · washi 和紙 · ai 藍 · sakura
  • 5 wagara patterns: seigaiha (waves) · shippo (interlocking circles) · kikko (tortoiseshell) · yabane (arrow feathers) · asanoha (hemp leaf)
  • 3 layouts: editorial (asymmetric), bloco (constructivist color block), ma (negative space)
  • 5 formats: 1:1 square, 1.91:1 link/Open Graph (LinkedIn, Facebook, X, Slack), 16:9 wide (native LinkedIn article, YouTube), 4:5 portrait, 2:1 banner; the layouts adapt to each ratio
  • Live preview: every control updates the preview instantly
  • Adjustable film grain and pattern strength sliders, shown live in the preview
  • Omakase button: randomizes the visual style and lets the house plate it for you
  • Named presets: save any number of looks as TOML and load/delete any of them (~/.config/article-cover-art-generator/presets/ on Linux, %APPDATA%\article-cover-art-generator\presets\ on Windows)
  • WCAG AAA: all readable text is forced to ≥ 7:1 contrast against its background
  • Montserrat Black / Bold / Regular, embedded in the binary (no system fonts needed)
  • Export: 2K or 4K (longest edge) PNG at each format's exact dimensions, plus the resolution-independent source SVG; a non-blocking save (spinner while it rasterizes) and optional open-after-export
  • Native: Rust + slint + resvg, running directly on Wayland (no web view, no Node)

Only the title is required; category, date, number and brand are optional, keeping the cover generic enough for any platform (blog, dev.to, LinkedIn, X, OG image, thumbnail…).

Download

Prebuilt binaries are attached to each GitHub release. No Rust toolchain or system dependencies required.

  • Linux: acag-*-x86_64.AppImage (self-contained: chmod +x and run), or acag-*-linux-x86_64.tar.gz (raw binary).
  • Windows: acag-*-windows-x86_64.zip (standalone acag.exe, no Visual C++ runtime needed).

Rendering backend

By default the app uses Slint's software (CPU) renderer, so it runs everywhere, including headless VMs and RDP sessions without a usable OpenGL driver. For this form-plus-preview UI the difference is imperceptible. To opt into GPU rendering:

SLINT_BACKEND=winit-femtovg acag

Build from source

Requires a recent stable Rust toolchain. On Linux, Slint also needs a few system libraries for the windowing/build:

# Debian / Ubuntu
sudo apt install build-essential pkg-config \
  libxkbcommon-dev libwayland-dev wayland-protocols \
  libxcb1-dev libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev \
  libfontconfig1-dev libgl1-mesa-dev
# Arch Linux
sudo pacman -S --needed base-devel \
  libxkbcommon wayland wayland-protocols \
  libxcb fontconfig mesa
cargo run --release

Covers are saved to ~/Pictures/article-covers/ on Linux and %USERPROFILE%\Pictures\article-covers\ on Windows (named from the title). Set ACAG_OUTPUT_DIR to write them somewhere else.

Install on Omarchy / Hyprland

cargo build --release
install -Dm755 target/release/acag ~/.local/bin/acag
install -Dm644 assets/icons/icon-512.png \
  ~/.local/share/icons/hicolor/512x512/apps/article-cover-art-generator.png
install -Dm644 assets/article-cover-art-generator.desktop \
  ~/.local/share/applications/article-cover-art-generator.desktop

It will then show up in the app launcher (walker/rofi). Run it from a terminal with acag.

Usage

  1. Type a title (the only required field).
  2. Fill in optional category / date / number / brand.
  3. Pick a theme, pattern, layout and format (1:1 … 2:1); tune the pattern strength and film grain sliders.
  4. Hit Omakase to shuffle the style, or set it by hand; name and Save a preset, then Load or Delete any saved one.
  5. Choose 2K or 4K, then Export PNG or Export SVG (enable Open after export to view it).

How it works

A single pure function, render_cover_svg(&CoverConfig) -> String, is the source of truth. The live preview and both exports rasterize the same SVG with resvg/tiny-skia, so the preview is exactly the file you get. Titles are auto-wrapped and auto-sized using the real Montserrat glyph metrics (ttf-parser).

src/
  design/   themes · wagara patterns · WCAG contrast
  cover/    config · format (aspect ratios) · typesetting · render · layouts
  raster.rs SVG → Pixmap/PNG by longest edge (resvg + embedded Montserrat)
  export.rs save SVG / PNG (2K or 4K)
  preset.rs save/load named presets as TOML
  main.rs   slint GUI wiring (background export + spinner)
ui/app.slint  the editor + live preview

Development

cargo test                 # unit tests
cargo run --example gallery  # regenerate docs/samples
cargo run --example icon     # regenerate the app icon

Credits

  • Montserrat by Julieta Ulanovsky et al., under the SIL Open Font License.
  • resvg / tiny-skia and slint for native rendering and UI.
  • Design language shared with skvggor.dev and waka-readme.

License

MIT.

About

A native desktop app that generates article cover art in an Omakase / Japanese-constructivist style — five aspect ratios (square, link, wide, portrait, banner), six themes, five patterns, three layouts, a live preview, exported up to 4K PNG (plus the source SVG).

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors