explaingit

chiply/svg-line

Analysis updated 2026-05-18

39Emacs LispAudience · developerComplexity · 3/5LicenseSetup · easy

TLDR

An Emacs package that replaces the plain-text tab bar, tab line, header line, and mode line with SVG images, allowing wrapping, alignment, and clickable elements.

Mindmap

mindmap
  root((svg-line))
    What it does
      Renders bars as SVG
      Multi-row wrapping
      Clickable segments
    Tech stack
      Emacs Lisp
      SVG
    Use cases
      Custom multi-row mode-line
      Wrapping tab bar
      Interactive header line
    Audience
      Emacs users
      Emacs config authors

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Replace a plain-text Emacs mode-line with an SVG bar that has independent left, center, and right alignment.

USE CASE 2

Make an overflowing tab bar wrap onto multiple rows instead of scrolling or truncating.

USE CASE 3

Add click actions, right-click menus, and hover tooltips to mode-line or header-line segments.

What is it built with?

Emacs Lisp

How does it compare?

chiply/svg-linenohzafk/emacs-workspace-hudjxs/editorconfig-emacs
Stars3917
LanguageEmacs LispEmacs LispEmacs Lisp
Last pushed2017-09-12
MaintenanceDormant
Setup difficultyeasyhardeasy
Complexity3/53/52/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 30min

Requires Emacs 29.1 or newer and graphical mode, does not work in a terminal.

You can use and modify this freely, but any software you build with it and distribute must also be released as open source under the same license.

In plain English

svg-line is an Emacs package that replaces the text-based bars Emacs draws for its tab bar, tab line, header line, and mode line with SVG images instead. Emacs normally renders those areas as laid-out text, which limits what they can look like and how they behave. By switching to SVG, the package removes several restrictions: bars can be any height, tabs can wrap onto multiple rows instead of being cut off or scrolled horizontally, and each row in a bar can have independent left, center, and right alignment. The package also adds interactivity to all four bar types. Any segment in a bar can have a left-click action, a right-click context menu, and hover tooltip text. This is notable for the tab bar in particular, which the README describes as otherwise uncooperative for those kinds of interactions. svg-line is a rendering engine only. It ships no content and no colors of its own. You define what each bar shows by providing a content function that returns a list of rows, where each row specifies what text or widgets appear on the left, center, and right. Colors and fonts can be literal values or functions that are re-evaluated on every render, which lets them respond to theme changes automatically. Inline SVG bar charts and pie charts are available as built-in segment types. The package requires Emacs 29.1 or newer and only works in graphical mode, not in a terminal. Installation is available through elpaca, straight.el, or by manually adding the file to the load path. The license is GPL-3.0.

Copy-paste prompts

Prompt 1
Install svg-line with elpaca and set up a basic mode-line
Prompt 2
Write a :content function for svg-line that shows the buffer name and line number
Prompt 3
How do I add a clickable segment with a right-click menu using svg-line-seg?
Prompt 4
Explain the difference between the lines and wrap layouts in svg-line

Frequently asked questions

What is svg-line?

An Emacs package that replaces the plain-text tab bar, tab line, header line, and mode line with SVG images, allowing wrapping, alignment, and clickable elements.

What language is svg-line written in?

Mainly Emacs Lisp. The stack also includes Emacs Lisp.

What license does svg-line use?

You can use and modify this freely, but any software you build with it and distribute must also be released as open source under the same license.

How hard is svg-line to set up?

Setup difficulty is rated easy, with roughly 30min to a first successful run.

Who is svg-line for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.