Documentation ¶
Overview ¶
forked from: https://github.com/charmbracelet/bubbles/blob/master/viewport/viewport.go
Index ¶
- func ViewDown(m Viewport, lines []string) tea.Cmd
- func ViewUp(m Viewport, lines []string) tea.Cmd
- type Viewport
- func (m Viewport) AtBottom() bool
- func (m Viewport) AtTop() bool
- func (m *Viewport) GotoBottom() (lines []string)
- func (m *Viewport) GotoTop() (lines []string)
- func (m *Viewport) HalfViewDown() (lines []string)
- func (m *Viewport) HalfViewUp() (lines []string)
- func (m Viewport) Init() tea.Cmd
- func (m *Viewport) LineDown(n int) (lines []string)
- func (m *Viewport) LineUp(n int) (lines []string)
- func (m Viewport) PastBottom() bool
- func (m Viewport) ScrollPercent() float64
- func (m *Viewport) SetContent(s string)
- func (m *Viewport) SetYOffset(n int)
- func (m Viewport) Update(msg tea.Msg) (Viewport, tea.Cmd)
- func (m Viewport) View() string
- func (m *Viewport) ViewDown() []string
- func (m *Viewport) ViewUp() []string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Viewport ¶
type Viewport struct { Width int Height int KeyMap keymap.KeyMap MouseWheelEnabled bool MouseWheelDelta int YOffset int YPosition int Style lipgloss.Style // contains filtered or unexported fields }
func NewViewport ¶
func (*Viewport) GotoBottom ¶
func (*Viewport) HalfViewDown ¶
func (*Viewport) HalfViewUp ¶
func (Viewport) PastBottom ¶
func (Viewport) ScrollPercent ¶
func (*Viewport) SetContent ¶
func (*Viewport) SetYOffset ¶
Click to show internal directories.
Click to hide internal directories.