Documentation ¶
Index ¶
- Constants
- Variables
- func AppsLoop()
- func B(c gocui.Attribute) string
- func DlgAddressAdd(addr string, signer string, path string) *gocui.Popup
- func DlgAddressEdit(name string) *gocui.Popup
- func DlgBlockchain(chain_id int) *gocui.Popup
- func DlgConfirm(title string, text string, action func() bool) *gocui.Popup
- func DlgLP_V3_add(b *cmn.Blockchain, address string, name string, url string) *gocui.Popup
- func DlgLP_V3_edit(b *cmn.Blockchain, address string, name string, url string) *gocui.Popup
- func DlgSend(b *cmn.Blockchain, t *cmn.Token, from *cmn.Address, to string, amount string) *gocui.Popup
- func DlgSignerAdd(t string, name string) *gocui.Popup
- func DlgSignerEdit(name string) *gocui.Popup
- func DlgTokenEdit(t *cmn.Token) *gocui.Popup
- func DlgWaletCreate() *gocui.Popup
- func DlgWaletOpen(name string) *gocui.Popup
- func F(c gocui.Attribute) string
- func FB(fg, bg gocui.Attribute) string
- func FastEstimateLines(p Pane, w int) int
- func Flush()
- func HidePane(p Pane)
- func Init()
- func LP_V3Loop()
- func Layout(g *gocui.Gui) error
- func Loop()
- func OnAutocompleteMouseDown(g *gocui.Gui, v *gocui.View) error
- func PrintErrorf(format string, a ...interface{})
- func Printf(format string, a ...interface{})
- func ProcessOnClickHotspot(v *gocui.View, hs *gocui.Hotspot)
- func ProcessOnOverHotspot(v *gocui.View, hs *gocui.Hotspot)
- func ResetColors()
- func SetKeybindings() error
- func SetTheme(theme string)
- func ShowPane(p Pane)
- func StatusLoop()
- type ACOption
- type AppPane
- type AuxPane
- type BottomPane
- type HailPaneType
- func (p *HailPaneType) EstimateLines(w int) int
- func (p *HailPaneType) GetDesc() *PaneDescriptor
- func (p *HailPaneType) IsOn() bool
- func (p *HailPaneType) SetOn(on bool)
- func (p *HailPaneType) SetView(x0, y0, x1, y1 int, overlap byte)
- func (p *HailPaneType) UpdateSubtitle(left_map map[int]time.Duration)
- type LP_V3Pane
- type NotificationPane
- func (n *NotificationPane) Hide()
- func (p *NotificationPane) SetView(g *gocui.Gui)
- func (n *NotificationPane) Show(text string)
- func (n *NotificationPane) ShowError(text string)
- func (n *NotificationPane) ShowErrorf(format string, args ...interface{})
- func (n *NotificationPane) ShowEx(text string, err_flag bool)
- func (n *NotificationPane) Showf(format string, args ...interface{})
- type Orientation
- type Pane
- type PaneDescriptor
- type PaneFlow
- type StatusPane
- type TerminalPane
- func (p *TerminalPane) EstimateLines(w int) int
- func (p *TerminalPane) GetDesc() *PaneDescriptor
- func (p *TerminalPane) HideAutocomplete()
- func (p *TerminalPane) IsOn() bool
- func (t *TerminalPane) SetCommandPrefix(prefix string)
- func (p *TerminalPane) SetInputView(x0, y0, x1, y1 int)
- func (p *TerminalPane) SetOn(on bool)
- func (p *TerminalPane) SetPrefixView(x0, y0, x1, y1 int)
- func (p *TerminalPane) SetScreenView(x0, y0, x1, y1 int)
- func (p *TerminalPane) SetView(x0, y0, x1, y1 int, overlap byte)
- func (t *TerminalPane) ShowAutocomplete(title string, options *[]ACOption, highlite string)
- type ThemeStruct
Constants ¶
View Source
const DEFAULT_COMMAND_PREFIX = "w3p"
View Source
const NOTIFICATION_TIME = 3
Variables ¶
View Source
var ActiveRequest *bus.Message
View Source
var AuxP_Id int
View Source
var DarkTheme = ThemeStruct{ Name: "dark", BgColor: gocui.GetColor("#090300"), FgColor: gocui.GetColor("#A5A2A2"), FrameColor: gocui.GetColor("#a7a7a7"), SelBgColor: gocui.GetColor("#090300"), SelFgColor: gocui.GetColor("#f3f3f3"), SelFrameColor: gocui.GetColor("#7FFFD4"), ActionBgColor: gocui.GetColor("#FFD700"), ActionFgColor: gocui.GetColor("#0000cc"), ActionSelBgColor: gocui.ColorCyan, ActionSelFgColor: gocui.ColorBlack, ErrorFgColor: gocui.GetColor("#ff0000"), EmFgColor: gocui.ColorCyan, HelpFgColor: gocui.GetColor("#f1f1f1"), HelpBgColor: gocui.GetColor("#028002"), InputBgColor: gocui.GetColor("#292320"), }
View Source
var Gui *gocui.Gui
View Source
var HQMutex = &sync.Mutex{}
View Source
var HailQueue []*bus.Message
View Source
var Is_ready = false
View Source
var Is_ready_wg sync.WaitGroup
View Source
var LightTheme = ThemeStruct{ Name: "light", BgColor: gocui.GetColor("#f1f1f1"), FgColor: gocui.ColorBlack, FrameColor: gocui.ColorBlack, SelBgColor: gocui.ColorCyan, SelFgColor: gocui.ColorBlack, SelFrameColor: gocui.ColorCyan, ActionBgColor: gocui.ColorCyan, ActionFgColor: gocui.GetColor("#ffff00"), ActionSelBgColor: gocui.ColorCyan, ActionSelFgColor: gocui.ColorBlack, ErrorFgColor: gocui.GetColor("#ff0000"), EmFgColor: gocui.ColorCyan, HelpFgColor: gocui.GetColor("#f1f1f1"), HelpBgColor: gocui.GetColor("#013220"), InputBgColor: gocui.GetColor("#717171"), }
View Source
var RUNES = []rune{'─', '│', '┌', '┐', '└', '┘', '├', '┤', '┬', '┴', '┼'}
View Source
var Themes = map[string]ThemeStruct{ DarkTheme.Name: DarkTheme, LightTheme.Name: LightTheme, }
View Source
var TopLeftFlow = NewFlow( FlowVertical, []Pane{ &Status, }, &PaneDescriptor{ MinWidth: 45, MinHeight: 1, })
Functions ¶
func DlgAddressEdit ¶
func DlgBlockchain ¶
chain_id = 0 means add new custom blockchain
func DlgLP_V3_add ¶
func DlgLP_V3_edit ¶
func DlgSignerEdit ¶
func DlgTokenEdit ¶
name == "" mreans add new custom blockchain
func DlgWaletCreate ¶
func DlgWaletOpen ¶
func FastEstimateLines ¶
func PrintErrorf ¶
func PrintErrorf(format string, a ...interface{})
func ResetColors ¶
func ResetColors()
func SetKeybindings ¶
func SetKeybindings() error
func StatusLoop ¶
func StatusLoop()
Types ¶
type AppPane ¶
type AppPane struct { PaneDescriptor On bool }
var App AppPane = AppPane{ PaneDescriptor: PaneDescriptor{ MinWidth: 45, MinHeight: 1, MaxHeight: 20, SupportCachedHightCalc: true, }, }
func (*AppPane) EstimateLines ¶
func (*AppPane) GetDesc ¶
func (p *AppPane) GetDesc() *PaneDescriptor
type AuxPane ¶
type AuxPane struct { PaneDescriptor On bool Id int Title string ViewName string }
func NewAuxPane ¶
func (*AuxPane) EstimateLines ¶
func (*AuxPane) GetDesc ¶
func (p *AuxPane) GetDesc() *PaneDescriptor
type BottomPane ¶
var Bottom *BottomPane = &BottomPane{
MinWidth: 0,
MinHeight: 1,
}
func (*BottomPane) Printf ¶
func (p *BottomPane) Printf(format string, args ...interface{})
func (*BottomPane) SetView ¶
func (p *BottomPane) SetView(g *gocui.Gui)
type HailPaneType ¶
type HailPaneType struct { PaneDescriptor On bool }
var HailPane HailPaneType = HailPaneType{ PaneDescriptor: PaneDescriptor{ MinWidth: 50, MinHeight: 1, SupportCachedHightCalc: false, // contains filtered or unexported fields }, }
func (*HailPaneType) EstimateLines ¶
func (p *HailPaneType) EstimateLines(w int) int
func (*HailPaneType) GetDesc ¶
func (p *HailPaneType) GetDesc() *PaneDescriptor
func (*HailPaneType) IsOn ¶
func (p *HailPaneType) IsOn() bool
func (*HailPaneType) SetOn ¶
func (p *HailPaneType) SetOn(on bool)
func (*HailPaneType) SetView ¶
func (p *HailPaneType) SetView(x0, y0, x1, y1 int, overlap byte)
func (*HailPaneType) UpdateSubtitle ¶
func (p *HailPaneType) UpdateSubtitle(left_map map[int]time.Duration)
type LP_V3Pane ¶
type LP_V3Pane struct { PaneDescriptor On bool }
var LP_V3 LP_V3Pane = LP_V3Pane{ PaneDescriptor: PaneDescriptor{ MinWidth: 90, MinHeight: 2, MaxHeight: 30, SupportCachedHightCalc: true, }, }
func (*LP_V3Pane) EstimateLines ¶
func (*LP_V3Pane) GetDesc ¶
func (p *LP_V3Pane) GetDesc() *PaneDescriptor
type NotificationPane ¶
var Notification *NotificationPane = &NotificationPane{}
func (*NotificationPane) Hide ¶
func (n *NotificationPane) Hide()
func (*NotificationPane) SetView ¶
func (p *NotificationPane) SetView(g *gocui.Gui)
func (*NotificationPane) Show ¶
func (n *NotificationPane) Show(text string)
func (*NotificationPane) ShowError ¶
func (n *NotificationPane) ShowError(text string)
func (*NotificationPane) ShowErrorf ¶
func (n *NotificationPane) ShowErrorf(format string, args ...interface{})
func (*NotificationPane) ShowEx ¶
func (n *NotificationPane) ShowEx(text string, err_flag bool)
func (*NotificationPane) Showf ¶
func (n *NotificationPane) Showf(format string, args ...interface{})
type PaneDescriptor ¶
type PaneDescriptor struct { MinWidth int MinHeight int MaxHeight int MaxWidth int View *gocui.View SupportCachedHightCalc bool // contains filtered or unexported fields }
func (*PaneDescriptor) GetTemplate ¶
func (d *PaneDescriptor) GetTemplate() string
func (*PaneDescriptor) SetTemplate ¶
func (d *PaneDescriptor) SetTemplate(t string)
type PaneFlow ¶
type PaneFlow struct { PaneDescriptor Orientation Orientation Panes []Pane }
func NewFlow ¶
func NewFlow(o Orientation, panes []Pane, descr *PaneDescriptor) *PaneFlow
func (*PaneFlow) EstimateLines ¶
func (*PaneFlow) GetDesc ¶
func (p *PaneFlow) GetDesc() *PaneDescriptor
func (*PaneFlow) RemovePane ¶
type StatusPane ¶
type StatusPane struct { PaneDescriptor On bool }
var Status StatusPane = StatusPane{ PaneDescriptor: PaneDescriptor{ MinWidth: 45, MinHeight: 1, SupportCachedHightCalc: true, }, }
func (*StatusPane) EstimateLines ¶
func (p *StatusPane) EstimateLines(w int) int
func (*StatusPane) GetDesc ¶
func (p *StatusPane) GetDesc() *PaneDescriptor
func (*StatusPane) IsOn ¶
func (p *StatusPane) IsOn() bool
func (*StatusPane) SetOn ¶
func (p *StatusPane) SetOn(on bool)
func (*StatusPane) SetView ¶
func (p *StatusPane) SetView(x0, y0, x1, y1 int, overlap byte)
type TerminalPane ¶
type TerminalPane struct { PaneDescriptor Screen *gocui.View Input *gocui.View Prefix *gocui.View AutoComplete *gocui.View AutoCompleteOn bool ACOptions *[]ACOption // autocomplete options ACTitle string //autocomplete title ACHighlite string //autocomplete highlite CommandPrefix string FormattedPrefix string AutoCompleteFunc func(string) (string, *[]ACOption, string) History []string On bool }
var Terminal TerminalPane = TerminalPane{ CommandPrefix: DEFAULT_COMMAND_PREFIX, History: []string{}, ACOptions: &[]ACOption{}, AutoCompleteOn: false, On: true, PaneDescriptor: PaneDescriptor{ MinWidth: 10000, MinHeight: 1, SupportCachedHightCalc: false, }, }
func (*TerminalPane) EstimateLines ¶
func (p *TerminalPane) EstimateLines(w int) int
func (*TerminalPane) GetDesc ¶
func (p *TerminalPane) GetDesc() *PaneDescriptor
func (*TerminalPane) HideAutocomplete ¶
func (p *TerminalPane) HideAutocomplete()
func (*TerminalPane) IsOn ¶
func (p *TerminalPane) IsOn() bool
func (*TerminalPane) SetCommandPrefix ¶
func (t *TerminalPane) SetCommandPrefix(prefix string)
func (*TerminalPane) SetInputView ¶
func (p *TerminalPane) SetInputView(x0, y0, x1, y1 int)
func (*TerminalPane) SetOn ¶
func (p *TerminalPane) SetOn(on bool)
func (*TerminalPane) SetPrefixView ¶
func (p *TerminalPane) SetPrefixView(x0, y0, x1, y1 int)
func (*TerminalPane) SetScreenView ¶
func (p *TerminalPane) SetScreenView(x0, y0, x1, y1 int)
func (*TerminalPane) SetView ¶
func (p *TerminalPane) SetView(x0, y0, x1, y1 int, overlap byte)
func (*TerminalPane) ShowAutocomplete ¶
func (t *TerminalPane) ShowAutocomplete(title string, options *[]ACOption, highlite string)
type ThemeStruct ¶
type ThemeStruct struct { Name string BgColor, FgColor, FrameColor gocui.Attribute SelBgColor, SelFgColor, SelFrameColor gocui.Attribute ActionBgColor, ActionFgColor, ActionSelBgColor, ActionSelFgColor gocui.Attribute ErrorFgColor gocui.Attribute EmFgColor gocui.Attribute InputBgColor gocui.Attribute HelpFgColor, HelpBgColor gocui.Attribute }
var Theme *ThemeStruct
Source Files ¶
- ansi.go
- bottom.go
- dlg_address_add.go
- dlg_address_edit.go
- dlg_blockchain.go
- dlg_confirm.go
- dlg_lp_v3_add.go
- dlg_lp_v3_edit.go
- dlg_send.go
- dlg_sigher_add.go
- dlg_signer_edit.go
- dlg_wallet_create.go
- dlg_wallet_open.go
- glg_token_edit.go
- layout.go
- notification.go
- pane.go
- pane_LP_V3.go
- pane_app.go
- pane_aux.go
- pane_flow.go
- pane_hail.go
- pane_status.go
- pane_terminal.go
- popup.go
- theme.go
- ui_server.go
Click to show internal directories.
Click to hide internal directories.