internal

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 6, 2026 License: BSD-3-Clause Imports: 10 Imported by: 0 modules, 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

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LogHint

func LogHint(reason string)

LogHint reports a developer hint that should be followed to improve their app. This does nothing unless the "hints" build flag is used.

Types

type ClipItem

type ClipItem struct {
	// contains filtered or unexported fields
}

ClipItem represents a single clip in a clip stack, denoted by a size and position.

func (*ClipItem) Intersect

func (i *ClipItem) Intersect(p geo.Position, s geo.Size) *ClipItem

Intersect returns a new clip item that is the intersection of the requested parameters and this clip.

func (*ClipItem) Rect

func (i *ClipItem) Rect() (geo.Position, geo.Size)

Rect returns the position and size parameters of the clip.

type ClipStack

type ClipStack struct {
	// contains filtered or unexported fields
}

ClipStack keeps track of the areas that should be clipped when drawing a canvas. If no clips are present then adding one will be added as-is. Subsequent items pushed will be completely within the previous clip.

func (*ClipStack) Length

func (c *ClipStack) Length() int

Length returns the number of items in this clip stack. 0 means no clip.

func (*ClipStack) Pop

func (c *ClipStack) Pop() *ClipItem

Pop removes the current top clip and returns it.

func (*ClipStack) Push

func (c *ClipStack) Push(p geo.Position, s geo.Size) *ClipItem

Push a new clip onto this stack at position and size specified. The returned clip item is the result of calculating the intersection of the requested clip and its parent.

func (*ClipStack) Top

func (c *ClipStack) Top() *ClipItem

Top returns the current clip item - it will always be within the bounds of any parent clips.

type Docs

type Docs struct {
	RootDocURI bellui.URI
}

Docs is an internal implementation of the document features of the Storage interface. It is based on top of the current `file` repository and is rooted at RootDocURI.

func (*Docs) Create

func (d *Docs) Create(name string) (bellui.URIWriteCloser, error)

Create will create a new document ready for writing, you must write something and close the returned writer for the create process to complete. If the document for this app with that name already exists a storage.ErrAlreadyExists error will be returned.

func (*Docs) List

func (d *Docs) List() []string

List returns all documents that have been saved by the current application. Remember to use `app.NewWithID` so that your storage is unique.

func (*Docs) Open

func (d *Docs) Open(name string) (bellui.URIReadCloser, error)

Open will grant access to the contents of the named file. If an error occurs it is returned instead.

func (*Docs) Remove

func (d *Docs) Remove(name string) error

Remove will delete the document with the specified name, if it exists

func (*Docs) Save

func (d *Docs) Save(name string) (bellui.URIWriteCloser, error)

Save will open a document ready for writing, you close the returned writer for the save to complete. If the document for this app with that name does not exist a storage.ErrNotExists error will be returned.

type InMemoryPreferences

type InMemoryPreferences struct {
	// contains filtered or unexported fields
}

InMemoryPreferences provides an implementation of the bellui.Preferences API that is stored in memory.

func NewInMemoryPreferences

func NewInMemoryPreferences() *InMemoryPreferences

NewInMemoryPreferences creates a new preferences implementation stored in memory

func (*InMemoryPreferences) AddChangeListener

func (p *InMemoryPreferences) AddChangeListener(listener func())

AddChangeListener allows code to be notified when some preferences change. This will fire on any update. The passed 'listener' should not try to write values.

func (*InMemoryPreferences) ChangeListenersCopy

func (p *InMemoryPreferences) ChangeListenersCopy() []func()

ChangeListenersCopy returns a thread-safe copy of the registered change listeners. Used internally during cloud provider transitions.

func (*InMemoryPreferences) ReadValues

func (p *InMemoryPreferences) ReadValues(fn func(map[string]any))

ReadValues provides read access to the underlying value map - for internal use only... You should not retain a reference to the map nor write to the values in the callback function

func (*InMemoryPreferences) RemoveValue

func (p *InMemoryPreferences) RemoveValue(key string)

RemoveValue deletes a value on the given key

func (*InMemoryPreferences) SetValue

func (p *InMemoryPreferences) SetValue(key string, value any)

SetValue saves a value for the given key.

func (*InMemoryPreferences) Value

func (p *InMemoryPreferences) Value(key string) (any, bool)

Value looks up a value for the given key.

func (*InMemoryPreferences) WriteValues

func (p *InMemoryPreferences) WriteValues(fn func(map[string]any))

WriteValues provides write access to the underlying value map - for internal use only... You should not retain a reference to the map passed to the callback function

type OverlayStack

type OverlayStack struct {
	OnChange func()
	Canvas   core.Canvas
	// contains filtered or unexported fields
}

OverlayStack allows stacking overlays on top of each other. Removing an overlay will also remove all overlays above it. All methods are safe for concurrent use.

func (*OverlayStack) Add

func (s *OverlayStack) Add(overlay core.CanvasObject)

Add puts an overlay on the stack.

func (*OverlayStack) List

func (s *OverlayStack) List() []core.CanvasObject

List returns all overlays on the stack from bottom to top.

func (*OverlayStack) ListFocusManagers

func (s *OverlayStack) ListFocusManagers() []*app.FocusManager

ListFocusManagers returns all focus managers on the stack from bottom to top.

func (*OverlayStack) Remove

func (s *OverlayStack) Remove(overlay core.CanvasObject)

Remove deletes an overlay and all overlays above it from the stack.

func (*OverlayStack) Top

func (s *OverlayStack) Top() core.CanvasObject

Top returns the top-most overlay of the stack.

func (*OverlayStack) TopFocusManager

func (s *OverlayStack) TopFocusManager() *app.FocusManager

TopFocusManager returns the app.FocusManager assigned to the top-most overlay of the stack that takes part in focus routing. Focus-transparent overlays (see widget.OverlayContainer.FocusTransparent) are skipped, so the layer beneath them keeps keyboard focus; nil is returned when no overlay participates, letting the canvas fall back to its menu/content manager.

Directories

Path Synopsis
Package accessibility builds the platform-neutral semantic tree that screen-reader backends expose to assistive technologies (#484).
Package accessibility builds the platform-neutral semantic tree that screen-reader backends expose to assistive technologies (#484).
Package async provides unbounded channel and queue structures that are designed for caching unlimited number of a concrete type.
Package async provides unbounded channel and queue structures that are designed for caching unlimited number of a concrete type.
Package build contains information about they type of build currently running.
Package build contains information about they type of build currently running.
Package clipboard provides pure-Go codecs for platform clipboard payloads: the Windows CF_HTML ("HTML Format") header block and device-independent bitmaps (CF_DIB).
Package clipboard provides pure-Go codecs for platform clipboard payloads: the Windows CF_HTML ("HTML Format") header block and device-independent bitmaps (CF_DIB).
glfw
Package glfw provides a full Bellui desktop driver that uses the system OpenGL libraries.
Package glfw provides a full Bellui desktop driver that uses the system OpenGL libraries.
mobile/app
Package app lets you write portable all-Go apps for Android and iOS.
Package app lets you write portable all-Go apps for Android and iOS.
mobile/event/composition
Package composition defines the IME composition (preedit) event used by the mobile driver to carry input-method composition state from the native platform layer to the focused widget.
Package composition defines the IME composition (preedit) event used by the mobile driver to carry input-method composition state from the native platform layer to the focused widget.
mobile/event/config
Package config defines the event that reports an in-place configuration change to the mobile driver.
Package config defines the event that reports an in-place configuration change to the mobile driver.
mobile/event/key
Package key defines an event for physical keyboard keys.
Package key defines an event for physical keyboard keys.
mobile/event/lifecycle
Package lifecycle defines an event for an app's lifecycle.
Package lifecycle defines an event for an app's lifecycle.
mobile/event/paint
Package paint defines an event for the app being ready to paint.
Package paint defines an event for the app being ready to paint.
mobile/event/size
Package size defines an event for the dimensions, physical resolution and orientation of the app's window.
Package size defines an event for the dimensions, physical resolution and orientation of the app's window.
mobile/event/textedit
Package textedit defines the committed text-edit event used by the mobile driver to carry a native IME/keyboard edit — a range replacement — from the platform layer to the focused editor through the text-input mirror seam (#771).
Package textedit defines the committed text-edit event used by the mobile driver to carry a native IME/keyboard edit — a range replacement — from the platform layer to the focused editor through the text-input mirror seam (#771).
mobile/event/touch
Package touch defines an event for touch input.
Package touch defines an event for touch input.
mobile/event/undoredo
Package undoredo defines the native undo/redo invocation event used by the mobile driver to carry a platform-initiated undo or redo — the iPad soft keyboard's undo/redo bar keys, the three-finger swipe gestures or shake-to-undo, all of which drive the first responder's NSUndoManager — from the platform layer to the focused editor (#1134).
Package undoredo defines the native undo/redo invocation event used by the mobile driver to carry a platform-initiated undo or redo — the iPad soft keyboard's undo/redo bar keys, the three-finger swipe gestures or shake-to-undo, all of which drive the first responder's NSUndoManager — from the platform layer to the focused editor (#1134).
mobile/gl
Package gl implements Go bindings for OpenGL ES 2.0 and ES 3.0.
Package gl implements Go bindings for OpenGL ES 2.0 and ES 3.0.
mobile/mobileinit
Package mobileinit contains common initialization logic for mobile platforms that is relevant to both all-Go apps and gobind-based apps.
Package mobileinit contains common initialization logic for mobile platforms that is relevant to both all-Go apps and gobind-based apps.
Package gpu defines the backend-neutral painter interfaces used by the drivers.
Package gpu defines the backend-neutral painter interfaces used by the drivers.
Package gsportal is a pure-Go client for the freedesktop org.freedesktop.portal.GlobalShortcuts D-Bus portal — the only way to register system-wide hotkeys under Wayland, where there is no client key-grab API by design.
Package gsportal is a pure-Go client for the freedesktop org.freedesktop.portal.GlobalShortcuts D-Bus portal — the only way to register system-wide hotkeys under Wayland, where there is no client key-grab API by design.
webgpu
Package webgpu will host the WebGPU implementation of the backend-neutral gpu.Painter interface (WebGPU migration, issue #198, Phase 2 / #201).
Package webgpu will host the WebGPU implementation of the backend-neutral gpu.Painter interface (WebGPU migration, issue #198, Phase 2 / #201).
preferences
Package rasterx implements a rasterizer in go.
Package rasterx implements a rasterizer in go.
settings
Package textbuf provides the editable text storage backing the lazy single-segment editing path of widget.Entry / widget.RichText (#381).
Package textbuf provides the editable text storage backing the lazy single-segment editing path of widget.Entry / widget.RichText (#381).
Package textinput defines the neutral text-input mirror seam shared by every platform's native text-editing / IME integration (#768, epic #490).
Package textinput defines the neutral text-input mirror seam shared by every platform's native text-editing / IME integration (#768, epic #490).
Package thread provides low-level goroutine identification primitives with zero dependencies on the bellui package, allowing both the root bellui package and internal packages to import it without circular dependencies.
Package thread provides low-level goroutine identification primitives with zero dependencies on the bellui package, allowing both the root bellui package and internal packages to import it without circular dependencies.
Package uidir holds an ambient, per-goroutine user-interface direction override.
Package uidir holds an ambient, per-goroutine user-interface direction override.

Jump to

Keyboard shortcuts

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