Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/charmbracelet/bubbletea
/ functions
Functions
806 in github.com/charmbracelet/bubbletea
⨍
Functions
806
◇
Types & classes
231
Function
RequestTerminalVersion
RequestTerminalVersion is a command that queries the terminal for its version using XTVERSION. Note that some terminals may not support this command.
xterm.go:21
Function
RequestWindowSize
RequestWindowSize is a command that queries the terminal for its current size. It delivers the results to Update via a [WindowSizeMsg]. Keep in mind t
commands.go:173
Method
Run
()
renderer_park_test.go:200
Function
SetPrimaryClipboard
SetPrimaryClipboard produces a command that sets the primary clipboard using OSC52. Primary clipboard selection is a feature present in X11 and Waylan
clipboard.go:55
Method
SetStderr
SetStderr sets stderr on the underlying exec.Cmd to the given io.Writer.
exec.go:94
Method
SetStderr
(io.Writer)
renderer_park_test.go:203
Method
SetStdin
SetStdin sets stdin on underlying exec.Cmd to the given io.Reader.
exec.go:78
Method
SetStdin
(io.Reader)
renderer_park_test.go:201
Method
SetStdout
SetStdout sets stdout on underlying exec.Cmd to the given io.Writer.
exec.go:86
Method
SetStdout
(io.Writer)
renderer_park_test.go:202
Method
ShortHelp
Additional short help entries. This satisfies the help.KeyMap interface and is entirely optional.
examples/list-fancy/delegate.go:60
Method
ShortHelp
ShortHelp returns keybindings to be shown in the mini help view. It's part of the key.Map interface.
examples/help/main.go:27
Method
Spacing
()
examples/list-simple/main.go:45
Method
String
String returns the capability content as a string.
termcap.go:47
Method
String
String returns the string representation of the clipboard message.
clipboard.go:20
Method
String
String returns the terminal name as a string.
xterm.go:9
Method
String
String returns the hex representation of the color.
color.go:42
Method
String
String returns the hex representation of the color.
color.go:74
Method
String
String returns the pasted content as a string.
paste.go:10
Method
String
String returns a string representation of the mouse click message.
mouse.go:86
Method
String
String returns a string representation of the mouse release message.
mouse.go:101
Method
String
String returns a string representation of the mouse wheel message.
mouse.go:116
Method
String
String returns a string representation of the mouse motion message.
mouse.go:131
Method
String
String implements [fmt.Stringer] and is quite useful for matching key events. For details, on what this returns see [Key.String].
key.go:195
Method
String
String implements [fmt.Stringer] and is quite useful for matching key events. For details, on what this returns see [Key.String].
key.go:228
Method
SupportsAllKeysAsEscapeCodes
SupportsAllKeysAsEscapeCodes returns whether the terminal supports reporting all keys as escape codes.
keyboard.go:51
Method
SupportsAlternateKeys
SupportsAlternateKeys returns whether the terminal supports reporting alternate key codes.
keyboard.go:45
Method
SupportsAssociatedText
SupportsAssociatedText returns whether the terminal supports reporting associated text with key events.
keyboard.go:57
Method
SupportsKeyDisambiguation
SupportsKeyDisambiguation returns whether the terminal supports key disambiguation (e.g., distinguishing between different modifier keys).
keyboard.go:33
Function
Suspend
Suspend is a special command that tells the Bubble Tea program to suspend.
tea.go:601
Function
TestBatch
(t *testing.T)
commands_test.go:30
Function
TestClearMsg
(t *testing.T)
screen_test.go:164
Function
TestCursedRendererDrawsChangedEmptyAndTallViews
(t *testing.T)
cursed_renderer_test.go:105
Function
TestCursedRendererEnablesUnicodeModeForGraphemeWidth
(t *testing.T)
cursed_renderer_test.go:15
Function
TestCursedRendererReportsQueries
The renderer's keyboard enhancements query counts as a query.
tty_drain_test.go:181
Function
TestCursedRendererResumeRestoresUnicodeMode
(t *testing.T)
cursed_renderer_test.go:60
Function
TestCursedRendererSkipsUnchangedEmptyAndTallViews
(t *testing.T)
cursed_renderer_test.go:132
Function
TestCursedRendererSkipsUnchangedView
(t *testing.T)
cursed_renderer_test.go:90
Function
TestCursedRendererWcWidthDoesNotEnableUnicodeMode
(t *testing.T)
cursed_renderer_test.go:30
Function
TestCursedRenderer_insertAboveAfterLeavingAltScreen
Fixes: https://github.com/charmbracelet/bubbletea/issues/1881
cursed_renderer_test.go:639
Function
TestCursedRenderer_insertAboveBeforeEnteringAltScreen
(t *testing.T)
cursed_renderer_test.go:669
Function
TestCursedRenderer_insertAboveBeforeFirstFlush
(t *testing.T)
cursed_renderer_test.go:447
Function
TestCursedRenderer_insertAboveFlushesQueuedView
(t *testing.T)
cursed_renderer_test.go:604
Function
TestCursedRenderer_insertAboveLineBoundaries
(t *testing.T)
cursed_renderer_test.go:556
Function
TestCursedRenderer_insertAboveUsesActiveWidthMethod
Fixes: https://github.com/charmbracelet/bubbletea/issues/1802 insertAbove must measure wrapped lines with the active screen buffer's width method. Wh
cursed_renderer_test.go:520
Function
TestCursedRenderer_mouseVsFlush
Fixes: https://github.com/charmbracelet/bubbletea/issues/1690
cursed_renderer_test.go:181
Function
TestCursedRenderer_programStatus
(t *testing.T)
programstatus_test.go:12
Function
TestCursedRenderer_resizeStaleFrame
Fixes: https://github.com/charmbracelet/bubbletea/issues/1780
cursed_renderer_test.go:470
Function
TestCursedRenderer_restoresKittyKeyboardStack
(t *testing.T)
cursed_renderer_test.go:340
Function
TestCursedRenderer_uncomparableViewColors
Fixes: https://github.com/charmbracelet/bubbletea/issues/1848
cursed_renderer_test.go:243
Function
TestCursedRenderer_updatesKittyKeyboardFlagsInPlace
(t *testing.T)
cursed_renderer_test.go:407
Function
TestCursedRenderer_viewColorChanges
Colors are compared by value: the same color, whatever its type, doesn't redraw the view, while a different color or a reset does.
cursed_renderer_test.go:269
Function
TestDrainQueryReplies
Replies to queries that arrive after the input reader is canceled must not be left in the tty input for the next reader, such as an exec'd process.
tty_drain_test.go:83
Function
TestDrainQueryRepliesNoPendingQuery
Without outstanding queries there is nothing to drain, and no DA1 request is sent.
tty_drain_test.go:159
Function
TestDrainQueryRepliesOldQuery
The reply to a query sent long ago has been read by the input reader already, so there's nothing to drain.
tty_drain_test.go:170
Function
TestEvery
(t *testing.T)
commands_test.go:8
Function
TestExecProcessAltscreenNoLeak
TestExecProcessAltscreenNoLeak verifies the #431 fix also holds in alt screen mode and that the program leaves the terminal in a clean state. The fix
exec_test.go:224
Function
TestExecProcessDoesNotLeakViewOutput
TestExecProcessDoesNotLeakViewOutput is a regression test for #431: when ExecProcess runs a subprocess, the renderer must not flush the last View() to
exec_test.go:194
Function
TestFallbackDimensions
(t *testing.T)
tty_test.go:31
Function
TestHandleSignalsCatchesSecondSignalDuringShutdown
TestHandleSignalsCatchesSecondSignalDuringShutdown is a regression test for https://github.com/charmbracelet/bubbletea/issues/1849: after a quit messa
signals_test.go:64
Function
TestHandleSignalsReturnsAfterContextCancelDuringPendingSend
TestHandleSignalsReturnsAfterContextCancelDuringPendingSend is a regression test for the signal-goroutine deadlock on shutdown: a signal arriving whil
signals_test.go:18
Function
TestIsPlausibleWindowSize
(t *testing.T)
screen_test.go:212
Function
TestKillDuringStartupRace
(t *testing.T)
tea_test.go:252
Function
TestLogToFile
(t *testing.T)
logging_test.go:11
Function
TestLogToFileWithPrefixSpacing
(t *testing.T)
logging_test.go:32
Function
TestOptions
(t *testing.T)
options_test.go:11
Function
TestProgramCanceledInput
(t *testing.T)
shutdown_input_test.go:181
Function
TestProgramClosesTraceFile
(t *testing.T)
tea_test.go:97
Function
TestProgramNonTTYDimensions
(t *testing.T)
tty_test.go:125
Function
TestProgramPrintAfterExit
(t *testing.T)
tea_test.go:588
Function
TestProgramQuitBeforeRunPreservesMessages
(t *testing.T)
quit_lifecycle_test.go:67
Function
TestProgramQuitDuringInitialization
(t *testing.T)
quit_lifecycle_test.go:100
Function
TestProgramQuitRespectsFilter
(t *testing.T)
quit_lifecycle_test.go:142
Function
TestProgramQuitUnstarted
(t *testing.T)
quit_lifecycle_test.go:41
Function
TestProgramSendBeforeRunStillWaits
(t *testing.T)
quit_lifecycle_test.go:189
Function
TestProgressBarStateStringOutOfRange
TestProgressBarStateStringOutOfRange is a regression test for https://github.com/charmbracelet/bubbletea/issues/1711: String panicked with an index-ou
tea_test.go:1033
Function
TestReleaseRestoreTerminalClosesCancelReader
Every ReleaseTerminal/RestoreTerminal cycle (Exec, suspend) replaces the input cancel reader. The replaced reader must be closed, or its epoll file de
tty_linux_test.go:50
Function
TestReleaseTerminalDeliversQueryReplies
Releasing the terminal hands the replies it read to the program.
tty_drain_test.go:117
Function
TestReleaseTerminalWithNilInputDoesNotWait
(t *testing.T)
exec_test.go:141
Function
TestRendererQuitWhileParked
(t *testing.T)
renderer_park_test.go:254
Function
TestRendererStopsTickingWhenIdle
(t *testing.T)
renderer_park_test.go:205
Function
TestRendererWakes
Every way of giving the renderer work must wake it.
renderer_park_test.go:220
Function
TestSequence
(t *testing.T)
commands_test.go:35
Function
TestShutdownClosesInputOnce
A reader that shutdown closed must not be closed again when a later run replaces it: closing a cancel reader closes raw file descriptors, so a second
shutdown_input_test.go:106
Function
TestShutdownDefersCloseAfterInputTimeout
(t *testing.T)
shutdown_input_test.go:62
Function
TestShutdownDrainsQueryReplies
A program that quits right after it starts sends its queries during shutdown. Their replies must be read before the terminal is handed back to the she
tty_drain_test.go:140
Function
TestShutdownInputFallbacks
(t *testing.T)
shutdown_input_test.go:128
Function
TestShutdownWaitsForCancelableInput
(t *testing.T)
shutdown_input_test.go:24
Function
TestTeaBatchMsg
(t *testing.T)
tea_test.go:452
Function
TestTeaContext
(t *testing.T)
tea_test.go:355
Function
TestTeaContextBatchDeadlock
(t *testing.T)
tea_test.go:416
Function
TestTeaContextImplodeDeadlock
(t *testing.T)
tea_test.go:389
Function
TestTeaExec
(t *testing.T)
exec_test.go:62
Function
TestTeaExecWithNilInput
(t *testing.T)
exec_test.go:123
Function
TestTeaGoroutinePanic
(t *testing.T)
tea_test.go:742
Function
TestTeaKill
(t *testing.T)
tea_test.go:322
Function
TestTeaModel
(t *testing.T)
tea_test.go:74
Function
TestTeaNestedSequenceMsg
(t *testing.T)
tea_test.go:541
Function
TestTeaNoCapabilityQueryWithoutInput
TestTeaNoCapabilityQueryWithoutInput is a regression test for https://github.com/charmbracelet/gum/issues/1118: programs without input can't read the
tea_test.go:886
Function
TestTeaNoRun
(t *testing.T)
tea_test.go:631
← previous
next →
401–500 of 806, ranked by callers