Skip to content

Theme

A theme is a file of its own under ~/.config/moonswing/themes/. config.toml picks one by its filename without .toml:

theme = "dracula"

Seven themes ship with the shell:

Name Looks like
glassy Cool translucent islands floating over the wallpaper. The default.
forest A carved oak beam on mossy capstones, overgrown with ivy and ferns; menus grow out of it like bark-rimmed trunks.
autumn Forest in October: a chestnut beam, turning leaves in the top corners, pumpkins along a bottom bar.
dracula The Dracula palette.
midnight Indigo, one type size up, with cards that glow instead of casting a shadow.
carbon Flat, square graphite; bar menus grow out of the bar on a flared join.
classic95 The 1995 desktop: grey taskbar, raised square menus, teal desktop. The only light theme.

Each comes with its own wallpaper, shown while the Theme default wallpaper is selected — see The theme’s wallpaper.

  • The easy way in is Settings › Shell › Theme: pick a theme (applies at once), edit any key live, or New theme….
  • The shipped themes are read-only. The shell rewrites their files on every start, so hand edits to dracula.toml are lost. Editing one in Settings makes a copy (Duplicate to edit); your own files are never touched.
  • If theme is missing, names no file, or names a file that does not parse, you get glassy. A single bad value inside a theme costs only that key.
  • Switching themes blends the colours and font_size over a moment; everything else (geometry, fonts, icons, animations, materials and their tints) changes at once. Editing a key applies immediately.
  • An old inline [theme] table in config.toml is ignored and gives you glassy. To keep it, move its contents (without the [theme] line) into themes/mine.toml and set theme = "mine".

A theme file is a flat table with no section header. Every key is optional.

~/.config/moonswing/themes/gruvbox.toml
name = "Gruvbox"
font = "Ubuntu Sans"
font_size = 13.0
icon_pack = "font_awesome"
accent = "#458588"
foreground = "#EBDBB2"
surface_hover = "#504945"
surface_pressed = "#3C3836"
workspace_background = "#3C3836"
popup_background = "#282828"
popup_foreground = "#EBDBB2"
control_surface = "#504945"
slider_track = "#504945"
muted = "#928374"
divider = "#33EBDBB2"
scrim = "#88282828"
panel_background = "#EE282828"
panel_gradient = "accent"
panel_margin = 0
panel_radius = 0.0
panel_border = "#33EBDBB2"
panel_border_width = 0.0
popup_radius = 8.0
popup_gap = 0.0
popup_border = "#33EBDBB2"
popup_border_width = 1.0
popup_shadow_color = "#66000000"
popup_animation = "slide"
overlay_radius = 12.0
overlay_animation = "scale"

Colours are #RRGGBB or #AARRGGBB (AA is alpha: "#33FFFFFF" is white at ~20%). Alpha is how a theme becomes translucent; there is no blur key.

Key Type Default Description
name string the filename Name shown in the theme picker
font string Ubuntu Sans Font family for all shell text (any fontconfig family)
font_size float 13.0 Body text size in logical pixels; the whole type scale follows it. 6–32
icon_pack enum font_awesome Interface icon font; see below
wallpaper string "" The theme’s wallpaper; see The theme’s wallpaper
accent colour #853953 Focused workspace, slider fill, selections, charts
foreground colour #F3F4F4 Text and icons on the bar
surface_hover colour #853953 Button background on hover
surface_pressed colour #612D53 Button background when pressed; middle of the accent gradient
workspace_background colour #2C2C2C The workspaces pod
popup_background colour #2C2C2C Popups, menus, the OSD and the overview
popup_foreground colour #F3F4F4 Text and icons in popups
control_surface colour #39393D Cards, inputs and tiles in popups and Settings
slider_track colour #612D53 Unfilled part of sliders and usage bars
muted colour #C4A8B2 Secondary text: headers, timestamps, units
divider colour #33F3F4F4 Separator lines, and the fill of quiet rows — give it enough alpha to read as a surface
notification_badge colour #F2B441 Unread notifications: the floating badge, the bell’s count, the unread dot
notification_badge_foreground colour #2C1218 Text on notification_badge
scrim colour #882C2C2C Wash over the screen behind a full-screen overlay

Notes:

  • accent is a fill colour. Where the shell writes text in the accent (a checked row, the current tab, today’s date), it lightens it as far as needed to read on popup_background. There is nothing to set.
  • font_size scales text only — in the bar, popups, overlays and desktop widgets. Bar thickness is [panels.<name>] height; raise it with a much larger font. Icons keep their size.
  • notification_badge is meant to be louder than the rest of the palette; the shipped themes use a hue they use nowhere else.

icon_pack values:

Value Pack Look
font_awesome Font Awesome Free Solid, heavy glyphs. The default and every pack’s fallback
material_rounded Material Symbols Rounded Rounded corners and ends
material_outlined Material Symbols Outlined Outlined, crisp corners
material_sharp Material Symbols Sharp Square corners and ends (classic95 uses it)
lucide Lucide Thin, even strokes, no filled forms
remix Remix Icon Neutral line icons, filled for “on” states

An icon a pack lacks (brand logos under Material Symbols and Lucide, for example) is drawn from Font Awesome. Icons keep the same size under every pack. Application, tray and file icons come from your desktop icon theme, and weather pictures are their own; neither changes with this key.

These keys shape every bar. All of them apply live.

Key Type Default Description
panel_background colour #EE2C2C2C The bar’s fill; its alpha is the whole bar’s opacity
panel_gradient enum accent none (flat), accent (fade from accent) or corners (a colour per corner)
panel_gradient_top_left colour #EE853953 Top-left colour under corners
panel_gradient_top_right colour #EE612D53 Top-right colour under corners
panel_gradient_bottom_right colour #EE2C2C2C Bottom-right colour under corners
panel_gradient_bottom_left colour #EE612D53 Bottom-left colour under corners
panel_margin int or table 0 Gap between the bar and the screen edges, 0–256; see Floating the bar
panel_radius float or table 0.0 Corner rounding, 0–64
panel_corners string or list auto Which corners round: auto, all, none, or a list of top_left, top_right, bottom_right, bottom_left
panel_square_flush_corners bool false Keep square every corner that touches a screen edge with no margin
panel_border colour #33F3F4F4 Rim colour
panel_border_width float 0.0 Rim thickness, 0–16; 0 is no rim
panel_join_radius float 0.0 Fillet where two bars meet, 0–64; see Where two bars meet
panel_join bool false Join all bars into one frame; see Where two bars meet
  • accent gradient: fades from accent at the bar’s start (left of a top bar, top of a side bar) through surface_pressed to panel_background, every stop at panel_background’s alpha. panel_background = "#402C2C2C" makes the whole bar 25% opaque. true/false from older themes read as accent/none.

  • corners gradient: each colour keeps its own alpha and they blend across the bar. Corners are the screen’s, so every bar is lit from the same side. Matching the two left and the two right corners gives a left-to-right fade:

    panel_gradient = "corners"
    panel_gradient_top_left = "#EE853953"
    panel_gradient_bottom_left = "#EE853953"
    panel_gradient_top_right = "#EE2C2C2C"
    panel_gradient_bottom_right = "#EE2C2C2C"
  • Rim: width is the switch, not alpha. The rim is left off any side flush against the screen edge. A 1px rim helps a translucent bar stand out from a busy wallpaper.

  • A translucent bar shows the shell’s own wallpaper ([background]); without one, whatever the compositor paints (often black).

panel_margin moves each bar off the screen edges it is anchored to (glassy uses 8). The gap is real: windows do not tile into it, and clicks there reach the desktop. Reserved space grows with the margin — a 32px bar with an 8px margin keeps windows 40px from the edge.

A table gives each side its own margin; a side left out is 0:

# Every bar's far end stops 8px short; everything else is flush.
panel_margin = { top = 0, right = 8, bottom = 0, left = 0 }

Sides are named in the bar’s own frame. A side bar is a top bar turned a quarter turn anticlockwise:

Key Top or bottom bar Left or right bar
right right end top end
left left end bottom end
top top side side towards the screen’s left
bottom bottom side side towards the screen’s right

So right is always the far end. Only the side against the screen edge and the two ends are read; the side facing the screen’s middle is ignored.

Corners use the same frame: top_right is where the bar’s top side meets its right end. panel_radius takes one number or a table:

panel_radius = { top_left = 0, top_right = 12, bottom_right = 12, bottom_left = 4 }
panel_corners = ["top_right", "bottom_right"] # round only the far end
  • auto (Settings: Automatic) rounds the two corners facing the screen’s middle, and a corner on the screen edge only where the bar floats off the display’s own corner there. A bar floating on every side rounds all four; a flush one rounds only the inner two.
  • A list (Settings: Chosen), all or none applies to every bar as written. A corner with radius 0 stays square either way.
  • Where two bars join, the inside corner stays square.

panel_sections = true draws each section of a bar — the left, center and right lists of [panels.<name>.layout] — on its own island, sized to what it holds. glassy and midnight do this.

panel_background = "#00000000" # the bar itself draws nothing
panel_gradient = "none"
panel_radius = 0.0
panel_sections = true
panel_section_background = "#40121722"
panel_section_radius = 12.0
panel_section_padding = 10.0
panel_section_border = "#40FFFFFF"
panel_section_border_width = 1.0
Key Type Default Description
panel_sections bool false Draw each section as an island
panel_section_background colour #EE2C2C2C Island fill
panel_section_gradient enum none none, accent or corners, as panel_gradient (corners uses the panel_gradient_* colours)
panel_section_radius float 8.0 Corner rounding, 0–64; past half the bar’s depth it is a capsule
panel_section_padding float 8.0 Space past the first and last module, 0–64
panel_section_border colour #33F3F4F4 Island rim colour
panel_section_border_width float 0.0 Island rim thickness, 0–16; 0 is no rim
  • The bar is still drawn under the islands. To show islands alone, set panel_background’s alpha to 0, panel_gradient = "none" and panel_radius = 0, as above.
  • A section with nothing to show (say, only a battery module on a desktop) draws no island.
  • The space between islands is still the bar: it reserves space and right-clicking it opens the bar’s menu.

With bars on two adjacent edges, panel_join_radius fills the inside corner where they meet with a quarter round in the bar’s colour, so the pair reads as one frame (dracula uses 12).

  • Two bars meet only when both are flush in that corner (no margin on the three sides involved), and only when each is the only bar on its edge.
  • The fillet does not take clicks; windows still tile up to the bars. If the shell cannot set an input region, the corner stays square.
  • It continues the bar’s gradient and rim, but not panel_texture or panel_image.
  • Joined bars draw one outline: the rim between them is left out.

panel_join = true makes all bars one frame. Every top or bottom bar meets the side bars at its ends whatever the margins, and panel_join_radius rounds every inside corner.

panel_join = true
panel_margin = { bottom = 10 } # the frame stands 10px off the bottom of the screen
  • Under panel_join, panel_margin, panel_radius and panel_corners name the screen’s sides and corners. bottom = 10 lifts the bottom bar, and the side bars’ bottom ends follow it.
  • Top and bottom bars run across the corners; side bars stop against them. Keep joined bars on the same layer.

These keys style everything that floats over the bar: popups, menus, flyouts, tray menus, dialogs and the OSD.

Key Type Default Description
popup_radius float 8.0 Corner rounding, 0–64
popup_gap float 0.0 Distance from the bar, 0–64; 0 attaches the popup to the bar
popup_attach_radius float 0.0 Outward flare where an attached popup meets the bar, 0–64; gap 0 only
popup_border colour #33F3F4F4 Rim colour
popup_border_width float 1.0 Rim thickness, 0–16; 0 is no rim
popup_shadow_color colour #66000000 Shadow colour; alpha 0 turns the shadow off
popup_shadow_blur float 16.0 Blur radius, 0–64
popup_shadow_spread float 0.0 Grow (or, negative, shrink) before blurring, −32–32
popup_shadow_offset_x float 0.0 Horizontal offset, −64–64; positive is right
popup_shadow_offset_y float 6.0 Vertical offset, −64–64; positive is down
popup_animation enum slide Entrance effect, played in reverse to close
popup_animation_duration int 120 Entrance length in ms, 0–2000; the exit takes 3/4 of it
  • A bar popup opens at the bar’s inner edge, centred on its button.
  • popup_gap = 0 is attached mode: the card sits flush, squares its corners on the bar side and drops its rim and shadow there. carbon pairs it with popup_attach_radius = 12. Keep a gap with a translucent popup_background (as glassy does with 8): attached, the two translucent fills show a step in tone.
  • A rimmed bar leaves its rim out where an attached menu is open, so the outline runs round the card.
  • The shadow enlarges the popup’s window, and clicks in that margin hit the popup. On the bar side it never reaches past the gap.
  • An off-palette shadow colour with zero offsets and some spread is a glow (midnight).
  • The notification panel and the clipboard history cast the same shadow on their inner edge, using only colour, blur and spread.
  • Tooltips never attach. Menus opened at the pointer (desktop menu, category flyouts) ignore the gap. Popup sizes are not themable.

popup_animation values:

Value Effect
none No animation
fade Opacity only
slide A short slide out of the bar, with a fade (default)
scale Grows from its centre, with a fade
grow Unrolls from the bar edge
flip Swings open, hinged on the bar edge
spin Turns slightly as it scales in, with a fade
sprout Grows out of the bar like a trunk, then sways

slide, grow and flip move away from the bar the popup came from; pointer menus act as if hanging below their anchor. none is the real off switch (a duration of 0 still runs the effect, instantly). The dock’s labels and menu, and the scratchpad tooltip, never animate.

These keys say what a surface is made of and what grows on it. All are off by default, and off costs nothing. forest uses all of them; autumn is a variation.

Key Type Default Description
panel_texture enum none The bar’s material
panel_texture_color colour #6B4A2E Its tint; alpha is the material’s strength
panel_end_texture enum none A second material capping each end of the bar
panel_end_color colour #6E726B The caps’ tint; alpha is strength
panel_end_length float 0.0 How far each cap reaches along the bar, 0–256; 0 is none
panel_bevel float 0.0 Carved depth of the bar’s long edges, 0 (flat) – 1
panel_image string "" A picture tiled over the bar instead of panel_texture
panel_foliage enum none What grows off the bar’s inner edge
foliage_color colour #3E7A3A Leaf colour (in harvest, the still-green leaves)
foliage_bloom colour #E0A13A Berries and flowers (in harvest, turned leaves and pumpkins)
foliage_density float 1.0 Amount, as a multiple of the style’s own, 0–3
panel_overhang int 0 How far foliage may hang past the bar, 0–160 px
popup_texture enum none A popup card’s material, under its content
popup_texture_color colour #206B4A2E Its tint; keep the alpha low so text stays readable
popup_border_texture enum none Material for the popup rim instead of popup_border
popup_border_texture_color colour #5A4030 The rim material’s tint
popup_image string "" A picture tiled over popup cards instead of popup_texture
popup_roots float 0.0 How far roots spread along the bar from an attached popup, 0–96; gap 0 only

Materials (*_texture): none, wood (planks with grain and knots), stone (coursed blocks with mossy joints), bark (ridged plates), moss (a soft bed). They are generated, not image files, and drawn in the tint you give.

Foliage (panel_foliage): none, ivy (trailing vines), moss (fine hanging strands, the quietest), wildwood (vines, moss, ferns, leaves, and berries/flowers in foliage_bloom), harvest (autumn leaves heaped in the corners under a top or side bar; pumpkin patches along a bottom bar).

  • Plants grow away from the bar: they hang from a top bar, stand up from a bottom one. They rustle when the pointer reaches the bar or a popup opens, and are still otherwise.
  • The overhang does not take clicks and windows still tile up to the bar. If the shell cannot set an input region, nothing hangs.
  • Pictures: a path is absolute, starts with ~/, or is relative to the themes directory. Until it loads (or if it fails) the material is drawn; Settings › Shell › Theme shows why and offers Retry.
  • Roots (popup_roots) are drawn in popup_border_texture and grow as the popup opens. Pair them with popup_animation = "sprout".

The full-screen overlays are the overview (calendar, settings, board and the other tabs), the launcher, the emoji picker, the power menu, the window switcher, the authentication and input-capture prompts and the screen-share picker.

Key Type Default Description
overlay_radius float 12.0 Corner rounding of the overview, launcher, emoji picker and screen-share picker cards, 0–64
overlay_aspect float 1.5 The overview’s width over its height, 0.5–2
overlay_animation enum scale Entrance effect, played in reverse to close
overlay_animation_duration int 130 Entrance length in ms, 0–4000
overlay_animation_exit_ratio float 0.8 Exit length as a fraction of the entrance, 0–2
overlay_animation_curve enum ease_out Easing
  • The power menu, the window switcher and the prompts use popup_radius for their cards.
  • The overview stays within 88% of the screen’s height and 90% of its width, 720–1400 px wide; on a small screen it fits first and keeps its shape second.
  • The settings panel opens 1.5× slower than the other overlays, scaled from your duration.
  • none is the real off switch. The scrim only fades.
  • The notification panel and clipboard history have their own animation keys and ignore these.

overlay_animation: none, fade, scale (grows slightly from centre; default), zoom (settles back from slightly larger), rise (from below), drop (from above), unfold (vertically from its middle), flip (hinged on its horizontal middle), swing (hinged on its vertical middle, like a door), spin (turns slightly as it scales). Every effect but none also fades.

overlay_animation_curve: linear, ease_in, ease_out (default), ease_in_out, emphasized (sharp start, soft landing), overshoot (past the target and back), bounce, elastic (springs and settles; give it a longer duration than 130 ms).