Documentation ¶
Index ¶
- type IView
- type UI
- func (ui *UI) ActiveViewName() string
- func (ui *UI) Close()
- func (ui *UI) GetGocui() *gocui.Gui
- func (ui *UI) MainLoop() error
- func (ui *UI) SetBgColor(bgColor gocui.Attribute)
- func (ui *UI) SetCursor(enabled bool)
- func (ui *UI) SetFgColor(fgColor gocui.Attribute)
- func (ui *UI) SetHighlight(enabled bool)
- func (ui *UI) SetInputEsc(enabled bool)
- func (ui *UI) SetManagerFunc(fn func() error)
- func (ui *UI) SetMouse(enabled bool)
- func (ui *UI) SetView(view interface{}, x, y, w, h int) error
- func (ui *UI) SetViewOnBottom(view interface{}) error
- type View
- func (view *View) Backing() *gocui.View
- func (view *View) Clear() error
- func (view *View) Cursor() (int, int)
- func (view *View) CursorX() int
- func (view *View) CursorY() int
- func (view *View) HasBacking() bool
- func (view *View) Height() int
- func (view *View) Name() string
- func (view *View) Origin() (int, int)
- func (view *View) OriginX() int
- func (view *View) OriginY() int
- func (view *View) Read(b []byte) (int, error)
- func (view *View) Rewind() error
- func (view *View) SetBacking(gocuiView *gocui.View)
- func (view *View) SetBgColor(color gocui.Attribute)
- func (view *View) SetCursor(x, y int) error
- func (view *View) SetEditable(enabled bool) error
- func (view *View) SetFgColor(color gocui.Attribute)
- func (view *View) SetFrame(enabled bool) error
- func (view *View) SetHighlight(enabled bool) error
- func (view *View) SetOrigin(x, y int) error
- func (view *View) SetSelBgColor(color gocui.Attribute)
- func (view *View) SetSelFgColor(color gocui.Attribute)
- func (view *View) SetWrap(enabled bool) error
- func (view *View) Size() (int, int)
- func (view *View) Update(content string) error
- func (view *View) Width() int
- func (view *View) Write(content string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type UI ¶
type UI struct {
// contains filtered or unexported fields
}
UI is the UI view struct
func (*UI) ActiveViewName ¶
ActiveViewName returns the name of the active view
func (*UI) SetBgColor ¶
SetBgColor sets the background color
func (*UI) SetFgColor ¶
SetFgColor sets the foreground color
func (*UI) SetHighlight ¶
SetHighlight enables the highlight active state
func (*UI) SetManagerFunc ¶
SetManagerFunc sets the function to call for rendering UI
func (*UI) SetViewOnBottom ¶
SetViewOnBottom sets the view to the bottom layer
type View ¶
type View struct {
// contains filtered or unexported fields
}
View is a view sruct
func (*View) HasBacking ¶
HasBacking returns the true if this view has a gocui backing
func (*View) SetBacking ¶
SetBacking sets the backing gocui view
func (*View) SetBgColor ¶
SetBgColor sets the background color
func (*View) SetEditable ¶
SetEditable makes the view editable
func (*View) SetFgColor ¶
SetFgColor sets the foreground color
func (*View) SetHighlight ¶
SetHighlight enables the highlight color for the view
func (*View) SetSelBgColor ¶
SetSelBgColor sets the background color for selection
func (*View) SetSelFgColor ¶
SetSelFgColor sets the foreground color for selection