Documentation
¶
Overview ¶
Movement and window related funcs
Index ¶
- Variables
- func ApplyBg(color string, style tcell.Style) tcell.Style
- func ApplyTheme(name string)
- func BufferReloadFile(buf *Buffer) error
- func CmdAppendLine(ctx Context)
- func CmdAutocompleteTrigger(ctx Context)
- func CmdBackwardChar(ctx Context) func(Context)
- func CmdBackwardWord(ctx Context)
- func CmdBufferCycle(ctx Context)
- func CmdChangeBefore(_ Context) func(Context)
- func CmdChangeEndOfLine(ctx Context)
- func CmdChangeInsideBlock(ctx Context)
- func CmdChangeLine(ctx Context)
- func CmdChangeTo(_ Context) func(Context)
- func CmdChangeWORD(ctx Context)
- func CmdChangeWord(ctx Context)
- func CmdCursorBeginningOfTheLine(ctx Context)
- func CmdCursorCenter(ctx Context)
- func CmdCursorFirstNonBlank(ctx Context)
- func CmdCursorLeft(ctx Context)
- func CmdCursorLineDown(ctx Context)
- func CmdCursorLineUp(ctx Context)
- func CmdCursorRight(ctx Context)
- func CmdDeleteBefore(ctx Context) func(Context)
- func CmdDeleteCharBackward(ctx Context)
- func CmdDeleteCharForward(ctx Context)
- func CmdDeleteEndOfLine(ctx Context)
- func CmdDeleteLine(ctx Context)
- func CmdDeleteTo(_ Context) func(Context)
- func CmdDeleteWord(ctx Context)
- func CmdEnsureCursorVisible(ctx Context)
- func CmdEnterInsertMode(ctx Context)
- func CmdEnterInsertModeAppend(ctx Context)
- func CmdExit(ctx Context)
- func CmdExitInsertMode(ctx Context)
- func CmdForwardBeforeChar(_ Context) func(Context)
- func CmdForwardToChar(_ Context) func(Context)
- func CmdForwardWord(ctx Context)
- func CmdGotoLine0(ctx Context)
- func CmdGotoLineEnd(ctx Context)
- func CmdGotoLineEndOfFile(ctx Context)
- func CmdIndentOrComplete(ctx Context)
- func CmdJoinNextLine(ctx Context)
- func CmdJumpBack(ctx Context)
- func CmdJumpForward(ctx Context)
- func CmdKillBuffer(ctx Context)
- func CmdLineOpenAbove(ctx Context)
- func CmdLineOpenBelow(ctx Context)
- func CmdMacroPlay(ctx Context) func(Context)
- func CmdMacroRecord(ctx Context) func(Context)
- func CmdMacroRepeat(ctx Context)
- func CmdNewBuffer(ctx Context)
- func CmdNormalMode(ctx Context)
- func CmdRedo(ctx Context)
- func CmdReplaceChar(ctx Context) func(Context)
- func CmdSaveFile(ctx Context)
- func CmdScrollDown(ctx Context)
- func CmdScrollUp(ctx Context)
- func CmdSearchNext(ctx Context)
- func CmdSearchPrev(ctx Context)
- func CmdSelectionChange(ctx Context)
- func CmdSelectionDelete(ctx Context)
- func CmdToggleComment(ctx Context)
- func CmdUndo(ctx Context)
- func CmdVisualLineMode(ctx Context)
- func CmdVisualMode(ctx Context)
- func CmdWindowClose(ctx Context)
- func CmdWindowCloseAndKillBuffer(ctx Context)
- func CmdWindowNext(ctx Context)
- func CmdWindowToggleLayout(ctx Context)
- func CmdWindowVSplit(ctx Context)
- func CmdYank(ctx Context)
- func CmdYankEol(ctx Context)
- func CmdYankPut(ctx Context)
- func CmdYankPutBefore(ctx Context)
- func Color(color string) tcell.Style
- func CursorChClass(buf *Buffer) chClass
- func CursorChar(buf *Buffer) rune
- func CursorDec(buf *Buffer) (moved bool)
- func CursorInc(buf *Buffer) (moved bool)
- func CursorNumByLine(buf *Buffer, lookie *Element[Line]) int
- func HandleInsertKey(ctx Context, ev *tcell.EventKey)
- func HighlighterAdaptEditInput(event EventTextChange) (r sitter.EditInput)
- func HighlighterEditTree(event EventTextChange)
- func HighlighterGo(e *Editor)
- func HighlighterInitBuffer(e *Editor, buf *Buffer)
- func IndentGetNumber(line []rune, indentUnit []rune) int
- func MergeStyles(base tcell.Style, color string) tcell.Style
- func NodeToColor(node *Element[TreeSitterRangeNode]) tcell.Style
- func SearchNext(ctx Context, pattern string)
- func SearchPrev(ctx Context, pattern string)
- func SelectionCursorInRange(sel *Selection, c Cursor) bool
- func SelectionDelete(ctx Context)
- func SelectionStart(buf *Buffer)
- func SelectionStop(buf *Buffer)
- func SelectionToString(buf *Buffer, sel *Selection) string
- func SnippetProcessString(s string) (str string, cursorPos int)
- func TextDelete(buf *Buffer, selection *Selection)
- func TextInsert(buf *Buffer, line *Element[Line], pos int, text string)
- func TextObjectBlock(buf *Buffer, ch rune, include bool) (found bool, sel *Selection, cur Cursor)
- func TextObjectWord(buf *Buffer, bigword bool) (start, end int)
- func WithSelection(fn func(Context)) func(Context)
- type AutocompleteFn
- type Buffer
- func (b *Buffer) Append(s string)
- func (b *Buffer) GetName() string
- func (buf *Buffer) GetRootRir() string
- func (b *Buffer) Mode() Mode
- func (b *Buffer) ResetLines()
- func (b *Buffer) Save() error
- func (buf *Buffer) SetMode(m Mode)
- func (b *Buffer) String() string
- func (b *Buffer) TxEnd()
- func (b *Buffer) TxStart() (started bool)
- type CompletionItems
- type Context
- type Cursor
- type Driver
- type EditDiff
- type Editor
- func (e *Editor) ActiveBuffer() *Buffer
- func (e *Editor) ActiveWindow() *Window
- func (e *Editor) BufferFindByFilePath(fp string, create bool) *Buffer
- func (e *Editor) EchoMessage(msg string)
- func (e *Editor) EnsureBufferIsVisible(b *Buffer)
- func (e *Editor) HandleInput(ev *tcell.EventKey)
- func (e *Editor) LogError(err error, echo ...bool)
- func (e *Editor) LogMessage(msg string)
- func (e *Editor) NewContext() Context
- func (e *Editor) OpenFile(path string) *Buffer
- func (e *Editor) PopUi()
- func (e *Editor) PushUi(c UiComponent)
- func (e *Editor) Redraw()
- func (e *Editor) RuntimeDir(elems ...string) string
- func (e *Editor) ScreenSync()
- func (e *Editor) SetActiveWindow(w *Window)
- type Element
- type Event
- type EventBufferModeChange
- type EventTextChange
- type EventsManager
- type Highlighter
- type Jump
- type Jumps
- type KeyFallbackFn
- type KeyHandler
- func (k *KeyHandler) Fallback(fn func(ctx Context, ev *tcell.EventKey))
- func (k *KeyHandler) GetCount() int
- func (k *KeyHandler) GetFallback() KeyFallbackFn
- func (k *KeyHandler) HandleKey(editor *Editor, ev *tcell.EventKey, mode Mode)
- func (k *KeyHandler) Map(editor *Editor, mode Mode, newMappings KeyMap)
- func (k *KeyHandler) StartMacroRecording(reg string)
- func (k *KeyHandler) StopMacroRecording()
- type KeyMap
- type Layout
- type Line
- type List
- type LspManager
- func (l *LspManager) Completion(buf *Buffer) (res CompletionItems)
- func (l *LspManager) Definition(buf *Buffer, cursor Cursor) (filePath string, cur Cursor)
- func (m *LspManager) Diagnostics(buf *Buffer, lineNum int) []protocol.Diagnostic
- func (l *LspManager) DidChange(event EventTextChange)
- func (l *LspManager) DidClose(buf *Buffer)
- func (l *LspManager) DidOpen(buf *Buffer)
- func (l *LspManager) Hover(buf *Buffer, cursor Cursor) (sign string)
- func (l *LspManager) Signature(buf *Buffer, cursor Cursor) (sign string)
- type LspServerConfig
- type MacrosManager
- func (m *MacrosManager) Play(reg string)
- func (m *MacrosManager) Push(ev *tcell.EventKey)
- func (m *MacrosManager) Recording() bool
- func (m *MacrosManager) Reset()
- func (m *MacrosManager) Start(reg string)
- func (m *MacrosManager) StartRepeatRecording()
- func (m *MacrosManager) Stop()
- func (m *MacrosManager) StopRepeatRecording()
- type Mode
- type ModeKeyMap
- type Position
- type ProjectManager
- type Range
- type RenderPlane
- type Selection
- type Stack
- type Style
- type Theme
- type Transaction
- type TreeSitterNodeCursor
- type TreeSitterRangeNode
- type UiComponent
- type UndoRedo
- type View
- type Window
- type Yanks
Constants ¶
This section is empty.
Variables ¶
var EOL int = math.MinInt32
var LastSearchPattern string
Functions ¶
func ApplyTheme ¶
func ApplyTheme(name string)
func BufferReloadFile ¶
func CmdAppendLine ¶
func CmdAppendLine(ctx Context)
func CmdAutocompleteTrigger ¶
func CmdAutocompleteTrigger(ctx Context)
func CmdBackwardChar ¶
func CmdBackwardWord ¶
func CmdBackwardWord(ctx Context)
func CmdChangeBefore ¶
func CmdChangeEndOfLine ¶
func CmdChangeEndOfLine(ctx Context)
func CmdChangeInsideBlock ¶
func CmdChangeInsideBlock(ctx Context)
func CmdChangeLine ¶
func CmdChangeLine(ctx Context)
func CmdChangeTo ¶
func CmdChangeWORD ¶
func CmdChangeWORD(ctx Context)
func CmdChangeWord ¶
func CmdChangeWord(ctx Context)
func CmdCursorBeginningOfTheLine ¶
func CmdCursorBeginningOfTheLine(ctx Context)
func CmdCursorCenter ¶
func CmdCursorCenter(ctx Context)
func CmdCursorFirstNonBlank ¶
func CmdCursorFirstNonBlank(ctx Context)
func CmdCursorLeft ¶
func CmdCursorLeft(ctx Context)
func CmdCursorLineDown ¶
func CmdCursorLineDown(ctx Context)
func CmdCursorLineUp ¶
func CmdCursorLineUp(ctx Context)
func CmdCursorRight ¶
func CmdCursorRight(ctx Context)
func CmdDeleteBefore ¶
func CmdDeleteCharBackward ¶
func CmdDeleteCharBackward(ctx Context)
func CmdDeleteCharForward ¶
func CmdDeleteCharForward(ctx Context)
func CmdDeleteEndOfLine ¶
func CmdDeleteEndOfLine(ctx Context)
func CmdDeleteLine ¶
func CmdDeleteLine(ctx Context)
func CmdDeleteTo ¶
func CmdDeleteWord ¶
func CmdDeleteWord(ctx Context)
func CmdEnsureCursorVisible ¶
func CmdEnsureCursorVisible(ctx Context)
func CmdEnterInsertMode ¶
func CmdEnterInsertMode(ctx Context)
func CmdEnterInsertModeAppend ¶
func CmdEnterInsertModeAppend(ctx Context)
func CmdExitInsertMode ¶
func CmdExitInsertMode(ctx Context)
func CmdForwardBeforeChar ¶
func CmdForwardToChar ¶
func CmdForwardWord ¶
func CmdForwardWord(ctx Context)
func CmdGotoLine0 ¶
func CmdGotoLine0(ctx Context)
func CmdGotoLineEnd ¶
func CmdGotoLineEnd(ctx Context)
func CmdGotoLineEndOfFile ¶
func CmdGotoLineEndOfFile(ctx Context)
func CmdIndentOrComplete ¶
func CmdIndentOrComplete(ctx Context)
func CmdJoinNextLine ¶
func CmdJoinNextLine(ctx Context)
func CmdJumpBack ¶
func CmdJumpBack(ctx Context)
func CmdJumpForward ¶
func CmdJumpForward(ctx Context)
func CmdKillBuffer ¶
func CmdKillBuffer(ctx Context)
func CmdLineOpenAbove ¶
func CmdLineOpenAbove(ctx Context)
func CmdLineOpenBelow ¶
func CmdLineOpenBelow(ctx Context)
func CmdMacroPlay ¶
func CmdMacroRecord ¶
func CmdMacroRepeat ¶
func CmdMacroRepeat(ctx Context)
func CmdNewBuffer ¶
func CmdNewBuffer(ctx Context)
func CmdNormalMode ¶
func CmdNormalMode(ctx Context)
func CmdReplaceChar ¶
func CmdSaveFile ¶
func CmdSaveFile(ctx Context)
func CmdScrollDown ¶
func CmdScrollDown(ctx Context)
func CmdScrollUp ¶
func CmdScrollUp(ctx Context)
func CmdSearchNext ¶
func CmdSearchNext(ctx Context)
func CmdSearchPrev ¶
func CmdSearchPrev(ctx Context)
func CmdSelectionChange ¶
func CmdSelectionChange(ctx Context)
func CmdSelectionDelete ¶
func CmdSelectionDelete(ctx Context)
func CmdToggleComment ¶
func CmdToggleComment(ctx Context)
TODO: implement correct toggle comment logic: check if all lines are commented - then uncomment. else, append comment to each uncommted line.
func CmdVisualLineMode ¶
func CmdVisualLineMode(ctx Context)
func CmdVisualMode ¶
func CmdVisualMode(ctx Context)
func CmdWindowClose ¶
func CmdWindowClose(ctx Context)
func CmdWindowCloseAndKillBuffer ¶
func CmdWindowCloseAndKillBuffer(ctx Context)
func CmdWindowNext ¶
func CmdWindowNext(ctx Context)
func CmdWindowToggleLayout ¶
func CmdWindowToggleLayout(ctx Context)
func CmdWindowVSplit ¶
func CmdWindowVSplit(ctx Context)
func CmdYankEol ¶
func CmdYankEol(ctx Context)
func CmdYankPut ¶
func CmdYankPut(ctx Context)
func CmdYankPutBefore ¶
func CmdYankPutBefore(ctx Context)
func CursorChClass ¶
func CursorChClass(buf *Buffer) chClass
func HandleInsertKey ¶
func HighlighterAdaptEditInput ¶
func HighlighterAdaptEditInput(event EventTextChange) (r sitter.EditInput)
func HighlighterEditTree ¶
func HighlighterEditTree(event EventTextChange)
func HighlighterGo ¶
func HighlighterGo(e *Editor)
TODO: this must exit on editor close use context cancel()
func HighlighterInitBuffer ¶
func IndentGetNumber ¶
Get number if "indents" in provided line Indent unit can be \t, or any number of spaces. eg. 2 or 4.
func NodeToColor ¶
func NodeToColor(node *Element[TreeSitterRangeNode]) tcell.Style
func SearchNext ¶
Move cursor to the next search pattern match
func SearchPrev ¶
func SelectionCursorInRange ¶
func SelectionDelete ¶
func SelectionDelete(ctx Context)
func SelectionStart ¶
func SelectionStart(buf *Buffer)
func SelectionStop ¶
func SelectionStop(buf *Buffer)
func SelectionToString ¶
func SnippetProcessString ¶
func TextDelete ¶
func TextObjectBlock ¶
Returns selection inside '(', '{', '[' as "Selection" range. This implementation is simple and does not check if open/close symbols are "balanced".
func TextObjectWord ¶
func WithSelection ¶
Types ¶
type AutocompleteFn ¶
type Buffer ¶
type Buffer struct {
FilePath string
ScrollOffset int
Lines List[Line]
Cursor Cursor
Selection *Selection
Driver Driver
IndentCh []rune
Tx *Transaction
UndoRedo *UndoRedo
Highlighter *Highlighter
// contains filtered or unexported fields
}
func BufferReadFile ¶
func (*Buffer) GetRootRir ¶
type CompletionItems ¶
type CompletionItems struct {
IsIncomplete bool `json:"isIncomplete"`
Items []struct {
Label string `json:"label"`
Kind int `json:"kind"`
Detail string `json:"detail"`
Documentation struct {
Kind string `json:"kind"`
Value string `json:"value"`
} `json:"documentation"`
Preselect bool `json:"preselect,omitempty"`
SortText string `json:"sortText"`
FilterText string `json:"filterText,omitempty"`
InsertTextFormat int `json:"insertTextFormat"`
TextEdit struct {
NewText string `json:"newText"`
Insert struct {
Start struct {
Line int `json:"line"`
Character int `json:"character"`
} `json:"start"`
End struct {
Line int `json:"line"`
Character int `json:"character"`
} `json:"end"`
} `json:"insert"`
Replace struct {
Start struct {
Line int `json:"line"`
Character int `json:"character"`
} `json:"start"`
End struct {
Line int `json:"line"`
Character int `json:"character"`
} `json:"end"`
} `json:"replace"`
} `json:"textEdit"`
AdditionalTextEdits []struct {
Range struct {
Start struct {
Line int `json:"line"`
Character int `json:"character"`
} `json:"start"`
End struct {
Line int `json:"line"`
Character int `json:"character"`
} `json:"end"`
} `json:"range"`
NewText string `json:"newText"`
} `json:"additionalTextEdits,omitempty"`
} `json:"items"`
}
type Driver ¶
type Driver interface {
// Execute thing under cursor: line or seleciton
Exec(*Editor, *Buffer, *Element[Line])
// Execute whole buffer
ExecBuffer()
}
Driver represents anything that can run selected text. it can be sql connection, or rest client.
type Editor ¶
type Editor struct {
View View
Keys *KeyHandler
Buffers []*Buffer
Windows []*Window
UiComponents []UiComponent
ExitCh chan int
RedrawCh chan int
ScreenSyncCh chan int
Layout Layout
Yanks List[yank]
Projects ProjectManager
Message string // display in echo area
Lsp *LspManager
Events *EventsManager
AutocompleteTrigger AutocompleteFn
// contains filtered or unexported fields
}
var EditorInst *Editor
func NewEditor ¶
func NewEditor( view View, keys *KeyHandler, ) *Editor
func (*Editor) ActiveWindow ¶
func (*Editor) BufferFindByFilePath ¶
Find or create new buffer by its full file path
func (*Editor) EchoMessage ¶
func (*Editor) EnsureBufferIsVisible ¶
func (*Editor) HandleInput ¶
func (*Editor) LogMessage ¶
func (*Editor) NewContext ¶
func (*Editor) PushUi ¶
func (e *Editor) PushUi(c UiComponent)
func (*Editor) RuntimeDir ¶
func (*Editor) ScreenSync ¶
func (e *Editor) ScreenSync()
func (*Editor) SetActiveWindow ¶
type Element ¶
type Element[T any] struct { Value T // contains filtered or unexported fields }
func CursorLine ¶
type EventBufferModeChange ¶
type EventTextChange ¶
type EventsManager ¶
type EventsManager struct {
// contains filtered or unexported fields
}
func NewEventsManager ¶
func NewEventsManager() *EventsManager
func (*EventsManager) Broadcast ¶
func (e *EventsManager) Broadcast(msg any)
this is very quick and dirty implementation. we need sync processing to not mess up lsp and treesitter. TODO: rewrite.
func (*EventsManager) Subscribe ¶
func (e *EventsManager) Subscribe() <-chan Event
func (*EventsManager) Unsubscribe ¶
func (e *EventsManager) Unsubscribe(ch <-chan Event)
type Highlighter ¶
type Highlighter struct {
// contains filtered or unexported fields
}
func (*Highlighter) Build ¶
func (h *Highlighter) Build()
func (*Highlighter) Highlights ¶
func (h *Highlighter) Highlights(lineStart, lineEnd uint32)
Get syntax highlights for document range TODO: this must return array of nodes
func (*Highlighter) RootNode ¶
func (h *Highlighter) RootNode() *Element[TreeSitterRangeNode]
type Jumps ¶
func (*Jumps) JumpForward ¶
func (j *Jumps) JumpForward()
type KeyFallbackFn ¶
type KeyHandler ¶
type KeyHandler struct {
Macros *MacrosManager
// contains filtered or unexported fields
}
func NewKeyHandler ¶
func NewKeyHandler(mkeymap ModeKeyMap) *KeyHandler
func (*KeyHandler) Fallback ¶
func (k *KeyHandler) Fallback(fn func(ctx Context, ev *tcell.EventKey))
func (*KeyHandler) GetCount ¶
func (k *KeyHandler) GetCount() int
func (*KeyHandler) GetFallback ¶
func (k *KeyHandler) GetFallback() KeyFallbackFn
func (*KeyHandler) HandleKey ¶
func (k *KeyHandler) HandleKey(editor *Editor, ev *tcell.EventKey, mode Mode)
func (*KeyHandler) Map ¶
func (k *KeyHandler) Map(editor *Editor, mode Mode, newMappings KeyMap)
Map/merge keymap by selected mode
func (*KeyHandler) StartMacroRecording ¶
func (k *KeyHandler) StartMacroRecording(reg string)
func (*KeyHandler) StopMacroRecording ¶
func (k *KeyHandler) StopMacroRecording()
type List ¶
the zero value is ready to use.
type LspManager ¶
type LspManager struct {
// contains filtered or unexported fields
}
func NewLspManager ¶
func NewLspManager(e *Editor) *LspManager
func (*LspManager) Completion ¶
func (l *LspManager) Completion(buf *Buffer) (res CompletionItems)
func (*LspManager) Definition ¶
func (l *LspManager) Definition(buf *Buffer, cursor Cursor) (filePath string, cur Cursor)
func (*LspManager) Diagnostics ¶
func (m *LspManager) Diagnostics(buf *Buffer, lineNum int) []protocol.Diagnostic
TODO: return copy of diagnostics
func (*LspManager) DidChange ¶
func (l *LspManager) DidChange(event EventTextChange)
func (*LspManager) DidClose ¶
func (l *LspManager) DidClose(buf *Buffer)
func (*LspManager) DidOpen ¶
func (l *LspManager) DidOpen(buf *Buffer)
type LspServerConfig ¶
type LspServerConfig struct {
Cmd []string
}
func LspConfigByFileName ¶
func LspConfigByFileName(file string) (conf LspServerConfig, found bool)
type MacrosManager ¶
type MacrosManager struct {
Register string
// contains filtered or unexported fields
}
func NewMacrosManager ¶
func NewMacrosManager(keyHandler *KeyHandler) *MacrosManager
func (*MacrosManager) Play ¶
func (m *MacrosManager) Play(reg string)
func (*MacrosManager) Push ¶
func (m *MacrosManager) Push(ev *tcell.EventKey)
func (*MacrosManager) Recording ¶
func (m *MacrosManager) Recording() bool
func (*MacrosManager) Reset ¶
func (m *MacrosManager) Reset()
func (*MacrosManager) Start ¶
func (m *MacrosManager) Start(reg string)
func (*MacrosManager) StartRepeatRecording ¶
func (m *MacrosManager) StartRepeatRecording()
func (*MacrosManager) Stop ¶
func (m *MacrosManager) Stop()
func (*MacrosManager) StopRepeatRecording ¶
func (m *MacrosManager) StopRepeatRecording()
type ModeKeyMap ¶
type ProjectManager ¶
type ProjectManager struct {
// contains filtered or unexported fields
}
func NewProjectManager ¶
func NewProjectManager() ProjectManager
func (ProjectManager) Dir ¶
func (p ProjectManager) Dir(buf *Buffer) (dir string)
Returns Dir of current buffer or working directory if buffer has no valid file path.
func (ProjectManager) FindRoot ¶
func (p ProjectManager) FindRoot(buf *Buffer) (root string, err error)
Find project root by file path. Project root must have .git directory in it. otherwise "working directory" will be returned.
func (ProjectManager) GetRoot ¶
func (p ProjectManager) GetRoot() (root string)
TODO: this must be also base on git dir
type RenderPlane ¶
type RenderPlane int
const ( PlaneWin RenderPlane = 0 PlaneEditor RenderPlane = 1 )
type Selection ¶
func SelectionNormalize ¶
type Transaction ¶
type Transaction struct {
// contains filtered or unexported fields
}
func NewTx ¶
func NewTx(b *Buffer) *Transaction
func (*Transaction) End ¶
func (tx *Transaction) End()
func (*Transaction) Start ¶
func (tx *Transaction) Start()
type TreeSitterNodeCursor ¶
type TreeSitterNodeCursor struct {
// contains filtered or unexported fields
}
func NewColorNodeCursor ¶
func NewColorNodeCursor(rootNode *Element[TreeSitterRangeNode]) *TreeSitterNodeCursor
func (*TreeSitterNodeCursor) Seek ¶
func (c *TreeSitterNodeCursor) Seek(line, ch uint32) (node *Element[TreeSitterRangeNode], found bool)
type TreeSitterRangeNode ¶
type UiComponent ¶
type UiComponent interface {
Mode() Mode
Keymap() *KeyHandler
Render(view View)
Plane() RenderPlane
}
type UndoRedo ¶
func NewUndoRedo ¶
type Window ¶
type Window struct {
Jumps *Jumps
// contains filtered or unexported fields
}
func CreateWindow ¶
func CreateWindow() *Window
func (*Window) VisitBuffer ¶
Jump to buffer and location. Records jump history.
