Skip to content

Auto legend - #3225

Merged
texodus merged 2 commits into
masterfrom
auto-legend
Sep 1, 2026
Merged

Auto legend#3225
texodus merged 2 commits into
masterfrom
auto-legend

Conversation

@texodus

@texodus texodus commented Sep 1, 2026

Copy link
Copy Markdown
Member

This PR adds legend_mode: "auto", the default (now) for the just added legend_mode plugin config setting, which chooses via heuristic which legend mode to choose.

  • legend_mode: "auto" (new default): "floating" when every entry fits without scrolling (≤ 7 rows; continuous gradient legends always qualify), "sidebar" otherwise, so a long list gets dedicated scrollable space instead of occluding the plot. Treemap and Hetmap overrides the default to "sidebar" (as they are full-panel always).

  • legend_size_mode: "auto" | "fixed" (new, default "auto", floating mode only) sizes the panel to its content

Drive-by fixes: this PR also fixes support for Int8, UInt8, Int16, UInt16 to the View::with_typed_arrays method (only used by charts), which was uncovered by legend testing.

@texodus texodus added the enhancement Feature requests or improvements label Sep 1, 2026
Signed-off-by: Andrew Stein <steinlink@gmail.com>
Signed-off-by: Andrew Stein <steinlink@gmail.com>
@texodus
texodus merged commit 91d3940 into master Sep 1, 2026
34 of 35 checks passed
@texodus
texodus deleted the auto-legend branch September 1, 2026 20:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement Feature requests or improvements

Development

Successfully merging this pull request may close these issues.

1 participant