browser

package
v0.1.17 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 9, 2026 License: MIT Imports: 4 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package browser connects Forma themes to the optional standalone CEF host. Import it explicitly; ordinary Forma components do not depend on Chromium. This is not an embedded ui.Element.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Launch

func Launch(ctx context.Context, opts chromium.Options, theme *ui.Theme) (*chromium.Browser, error)

Launch opens a standalone browser using a snapshot of the selected theme. Custom shell themes currently require macOS and chromium.StyleAlloy.

func SetTheme

func SetTheme(ctx context.Context, b *chromium.Browser, theme *ui.Theme) error

SetTheme applies a changed Forma theme without relaunching the browser. Call when the theme changes, outside the rendering loop.

func Theme

func Theme(t *ui.Theme) chromium.Theme

Theme converts a Forma (or core UI) theme to a browser shell snapshot. The shell limits typography to 10–20 DIP to keep its address bar usable.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL