Theming

Every Debug MD surface is styled by USS. Swap the colors and sizing with a single stylesheet - no prefabs to edit, and the same theme applies on device and in the editor window.

Built-in themes

The panel ships with its default look, Slate, plus five alternates: Dracula, Nord, Solarized Light, Bubble and Phosphor.

Players of your development builds - and you - switch themes from the panel's About page. The choice is saved per device and reapplies on the next launch, overriding whatever the build shipped with. A theme that no longer exists in a later build falls back to the default silently.

Screenshot pending - the About page's theme picker open, with the built-in themes listed
Theme selection lives on the panel's About page; no code involved.

Applying a theme from code

DMD.SetTheme applies a stylesheet on top of the built-in panel styles. It takes effect immediately on every Debug MD surface - the panel, pinned widgets, picker overlays and the editor window:

ApplyTheme.cs
using UnityEngine;
using UnityEngine.UIElements;

// Assigned in the inspector.
[SerializeField] StyleSheet _theme;

DMD.SetTheme(_theme);

// Later: back to the default look.
DMD.SetTheme(null);

Use this when the theme should follow game state - for example a build flavor or an internal A/B setup. For everything else the About page picker is enough, and a theme picked there persists on its own.

Writing your own theme

A theme is a plain .uss file. The built-in styles expose their palette and sizing as --dmd-* custom properties; override those and every widget follows. Set the variables on the Debug MD root classes so the panel, overlays and pinned widgets all pick them up:

Assets/YourGame/Themes/CrimsonNight.uss
.dmd-panel-host,
.dmd-panel-backdrop,
.dmd-tap-feedback-layer,
.dmd-pinned,
.dmd-picker,
.dmd-lock {
    --dmd-color-bg: rgba(28, 16, 22, 0.96);
    --dmd-color-surface: rgb(52, 30, 40);
    --dmd-color-accent: rgb(255, 121, 152);
    --dmd-color-text: rgb(244, 236, 240);
    --dmd-color-text-dim: rgb(158, 138, 148);
    --dmd-color-warning: rgb(235, 203, 139);
}

The full variable set covers background, surface, accent, text, log-severity and profiler-graph colors plus base font sizes and spacing (--dmd-font-size-base, --dmd-font-size-title, --dmd-spacing). Sub tab levels take their colors from --dmd-color-tab-1, --dmd-color-tab-2 and --dmd-color-tab-3; the top-level bar uses the accent, and the Edit Mode tab uses --dmd-color-tab-edit-mode. The shipped themes under DebugMD/UI/Themes/ are short, readable references - Nord is a good file to copy from. A theme is not limited to variables: it loads after the base styles, so it may restyle any panel rule when you want deeper changes than a palette swap.

Adding it to the picker

Keep the file anywhere in your project, then add it to Additional Themes in Window › Debug MD › Settings, under Panel Appearance. You never edit the Debug MD package to add themes. The theme appears in the About page's picker, named after the asset with camel-case split into words (CrimsonNight becomes "Crimson Night"). A sample, MidnightSample.uss, ships in DebugMD/UI/Themes/ as a starting point - copy it rather than editing it in place.

Screenshot pending - the panel restyled by a custom user theme next to the default Slate look
A palette-only theme: six variable overrides, everything restyled.

What theming does and doesn't touch

  • Themes restyle Debug MD only. Your game's UI - uGUI or UI Toolkit - is untouched.
  • The editor panel window is themed too, so the docked panel matches what testers see on device.
  • Fonts and UI scale are not part of a theme: they come from the panel's PanelSettings asset (see Window › Debug MD › Settings › Panel Appearance), where Unity resolves text assets and scaling per platform.