Documentation
¶
Index ¶
- func Actions() []input.Action
- type Deselect
- func (d *Deselect) DefaultEvent() string
- func (d *Deselect) Menu(context.Context) string
- func (d *Deselect) Name(context.Context) string
- func (d *Deselect) Op(ctx context.Context, b input.Binder) (input.Operation, error)
- func (d *Deselect) Type(input.Command)
- func (d *Deselect) Valid(_ context.Context, b input.Binder) error
- type End
- type Home
- func (h *Home) DefaultEvent() string
- func (h *Home) Menu(context.Context) string
- func (h *Home) Name(context.Context) string
- func (h *Home) Op(ctx context.Context, b input.Binder) (input.Operation, error)
- func (h *Home) Type(input.Command)
- func (h *Home) Valid(_ context.Context, b input.Binder) error
- type MoveCaret
- func (m MoveCaret) DefaultEvent() string
- func (m MoveCaret) Menu(context.Context) string
- func (m MoveCaret) Name(context.Context) string
- func (m MoveCaret) Op(ctx context.Context, b input.Binder) (input.Operation, error)
- func (m MoveCaret) Type(input.Command)
- func (m MoveCaret) Valid(_ context.Context, b input.Binder) error
- type MoveOnEdit
- type PageDown
- func (p *PageDown) DefaultEvent() string
- func (p *PageDown) Menu(context.Context) string
- func (p *PageDown) Name(context.Context) string
- func (h *PageDown) Op(ctx context.Context, b input.Binder) (input.Operation, error)
- func (p *PageDown) Type(input.Command)
- func (p *PageDown) Valid(_ context.Context, b input.Binder) error
- type PageStore
- type PageUp
- func (p *PageUp) DefaultEvent() string
- func (p *PageUp) Menu(context.Context) string
- func (p *PageUp) Name(context.Context) string
- func (h *PageUp) Op(ctx context.Context, b input.Binder) (input.Operation, error)
- func (p *PageUp) Type(input.Command)
- func (p *PageUp) Valid(_ context.Context, b input.Binder) error
- type SelectionSetter
- type SelectionStore
- type SelectionViewer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Deselect ¶
type Deselect struct{}
func NewDeselect ¶
func NewDeselect() *Deselect
func (*Deselect) DefaultEvent ¶
type Home ¶
type Home struct {
// contains filtered or unexported fields
}
func (*Home) DefaultEvent ¶
type MoveCaret ¶
type MoveCaret struct {
// contains filtered or unexported fields
}
MoveCaret is a command to move carets.
func NewMoveCaret ¶
NewMoveCaret returns a new MoveCaret command for the provided direction and modifier.
func (MoveCaret) DefaultEvent ¶
type MoveOnEdit ¶
type MoveOnEdit struct{}
func (MoveOnEdit) TextJustChanged ¶
func (MoveOnEdit) Type ¶
func (m MoveOnEdit) Type(input.Hook)
type PageDown ¶
type PageDown struct {
// contains filtered or unexported fields
}
func NewPageDown ¶
func (*PageDown) DefaultEvent ¶
type PageUp ¶
type PageUp struct {
// contains filtered or unexported fields
}
func (*PageUp) DefaultEvent ¶
type SelectionSetter ¶
type SelectionSetter interface { input.Action Select(caret.Selection, ...caret.Selection) input.Operation }
SelectionSetter represents an operation that can move selections.
type SelectionStore ¶
type SelectionStore interface { input.Binder // Selections should return the currently applied list of caret.Selection // values. Selections(context.Context) (caret.Selection, []caret.Selection) State(context.Context) text.State }
SelectionStore represents a type that tracks selections. It contains the information that the MoveCaret command needs in order to work properly.
Invalid pos values (e.g. negative numbers or numbers after the end of the file) should be treated as if they were constrained to valid values, e.g. -1 should be treated as 0, EOF+1 should be treated as EOF.
Click to show internal directories.
Click to hide internal directories.