clipboard

package
v1.7.39 Latest Latest
Warning

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

Go to latest
Published: Apr 20, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CopyResult

type CopyResult struct {
	Method    string // How the content was copied (e.g., "pbcopy", "xclip", "osc52")
	ByteSize  int    // Number of bytes copied
	LineCount int    // Number of lines in the content
}

CopyResult contains metadata about a successful clipboard copy operation.

func Copy

func Copy(text string, supportsOSC52 bool) (*CopyResult, error)

Copy copies text to the system clipboard using platform-appropriate methods. The fallback chain is: native clipboard tool → OSC 52 escape sequence. supportsOSC52 should come from tmux.GetTerminalInfo().SupportsOSC52.

Jump to

Keyboard shortcuts

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