Skip to content

v0.0.0-alpha.16

Pre-release
Pre-release

Choose a tag to compare

@lrstanley lrstanley released this 26 Nov 13:07
v0.0.0-alpha.16
37ba2a3

Highlights

Programs that paint the screen their own colors can now tell bloom what those colors are, so fades, dims, selections, and border effects blend toward the right background.

  • Root.SetColors(fg, bg) sets the colors effects blend with. A cell with no color of its own shows the screen's colors. Bloom used to learn them only from the terminal's reports, so a program that set the view's BackgroundColor and ForegroundColor had no way to keep bloom on them. The terminal's first report replaced them, and a report sent before the paint reached the terminal described the terminal's own colors. Call SetColors when your theme changes, instead of sending the root fake color messages. Pass nil for either color to use the terminal's own.
  • WithColors now holds from the start. It sets the same colors SetColors does, rather than standing in only until the first report.
  • Terminal reports still count. Init still asks the terminal for its colors and Update still records the reports. A report never replaces a color the program set, and is used once that color is set back to nil. Colors that neither the program nor the terminal gave are light gray on black, as before.
  • Bubble Tea v2.2.0, along with the latest x/ansi and ultraviolet.

Breaking: canvas.Env.Profile is removed, and the root no longer handles tea.ColorProfileMsg; nothing read either. Programs that sent the root fake tea.BackgroundColorMsg or tea.ForegroundColorMsg to keep it on their theme should call SetColors instead, because reports no longer override colors the program set.

Changelog

⚠️ Breaking Changes

🧹 Misc

1 change

📦 Dependency Updates

1 change

Full changelog: v0.0.0-alpha.15...v0.0.0-alpha.16

📦 Install

go get bloomfx.dev/bloom@v0.0.0-alpha.16

Docs: bloomfx.dev/bloom

💬 What to do next?