Skip to content

Give the doctor and dashboard a visual language - #2131

Merged
bbatsov merged 1 commit into
masterfrom
feature/report-faces
Jul 27, 2026
Merged

Give the doctor and dashboard a visual language#2131
bbatsov merged 1 commit into
masterfrom
feature/report-faces

Conversation

@bbatsov

@bbatsov bbatsov commented Jul 27, 2026

Copy link
Copy Markdown
Owner

Both buffers were plain text, with all the structure carried by ASCII rules and
column padding. The doctor's findings were the worst of it - severity is exactly
what color is for, and ok, warn and info all rendered identically grey.

Section headers, field labels, the project's identity (root, type) and the
findings are now faced by meaning. Findings are also sorted warn-first, since a
report is read top-down and a lone warning shouldn't sit buried among a dozen
ok lines.

Three constraints shaped it:

  • Every face only :inherits from a standard one (success, warning,
    shadow, font-lock-*), so themes style them without knowing Projectile
    exists, and a terminal without colors degrades to exactly what you saw before.
  • The buffer text stays plain ASCII. The ---- rules are still text rather than
    an underline face, so a yanked report reads like the rendered one.
  • The rules are dimmed rather than faced like their titles - the first pass had
    them in the section face and the bright underlines competed with the headers.

And since a doctor report's usual destination is an issue, projectile-report-copy
(w in either buffer) makes that explicit: the buffer goes onto the kill ring
with faces and buttons stripped, so nothing drags Emacs text properties along.

Both buffers grew a dimmed footer listing their keys, which is also how w
becomes discoverable.

Both buffers were plain text with the structure carried entirely by
ASCII rules and column padding, which made them hard to skim - the
doctor's findings in particular, where severity is exactly the thing
color exists for.

Section headers, labels, the project's identity and the findings are now
faced by meaning, and the findings are sorted so a warning can't hide
among a dozen ok lines. Every face only inherits from a standard one, so
themes get it right for free and a terminal without colors renders what
it always did.

The characters stay plain ASCII, so a yanked report reads like the
rendered one - and projectile-report-copy makes that explicit by putting
the buffer on the kill ring without faces or buttons, which is what
pasting a report into an issue actually wants.
@bbatsov
bbatsov merged commit 268a7fe into master Jul 27, 2026
9 of 10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant