gui

package
v1.9.25 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 25, 2021 License: Unlicense Imports: 56 Imported by: 1

Documentation

Index

Constants

View Source
const Break1 = 48
View Source
const ZeroAddress = "1111111111111111111114oLvT2"

Variables

View Source
var F, E, W, I, D, T logg.LevelPrinter = logg.GetLogPrinterSet(subsystem)

Functions

func Main added in v0.4.14

func Main(cx *pod.State, c *cli.Context) (e error)

Types

type AddressEntry added in v0.4.14

type AddressEntry struct {
	Address  string     `json:"address"`
	Message  string     `json:"message,omitempty"`
	Label    string     `json:"label,omitempty"`
	Amount   amt.Amount `json:"amount"`
	Created  time.Time  `json:"created"`
	Modified time.Time  `json:"modified"`
	TxID     string     `json:txid,omitempty'`
}

type BoolMap added in v1.9.16

type BoolMap map[string]*gui.Bool

type CategoryFilter added in v0.4.14

type CategoryFilter struct {
	Send     bool
	Generate bool
	Immature bool
	Receive  bool
	Unknown  bool
}

CategoryFilter marks which transactions to omit from the filtered transaction list

func (*CategoryFilter) Filter added in v0.4.14

func (c *CategoryFilter) Filter(s string) (include bool)

type CheckableMap added in v1.9.16

type CheckableMap map[string]*gui.Checkable

type ClickableMap added in v1.9.16

type ClickableMap map[string]*gui.Clickable

type Console added in v0.4.14

type Console struct {
	*gui.Window
	// contains filtered or unexported fields
}

func (*Console) Fn added in v0.4.14

func (c *Console) Fn(gtx l.Context) l.Dimensions

func (*Console) JSONWidget added in v0.4.14

func (c *Console) JSONWidget(color string, j []byte) (out []l.Widget)

type IncDecMap added in v1.9.16

type IncDecMap map[string]*gui.IncDec

type Inputs added in v1.9.23

type Inputs map[string]*gui.Input

type JSONElement added in v0.4.14

type JSONElement struct {
	// contains filtered or unexported fields
}

type JSONElements added in v0.4.14

type JSONElements []JSONElement

func GetJSONElements added in v0.4.14

func GetJSONElements(in map[string]interface{}) (je JSONElements)

func (JSONElements) Len added in v0.4.14

func (je JSONElements) Len() int

func (JSONElements) Less added in v0.4.14

func (je JSONElements) Less(i, j int) bool

func (JSONElements) Swap added in v0.4.14

func (je JSONElements) Swap(i, j int)

type ListMap added in v1.9.16

type ListMap map[string]*gui.List

type Marshalled added in v0.4.14

type Marshalled struct {
	LastUpdated        time.Time
	BestBlockHeight    int32
	BestBlockHash      chainhash.Hash
	Balance            float64
	BalanceUnconfirmed float64
	AllTxs             []btcjson.ListTransactionsResult
	Filter             CategoryFilter
	ReceivingAddress   string
	ActivePage         string
	ReceiveAddressBook []AddressEntry
	SendAddressBook    []AddressEntry
}

func (*Marshalled) Unmarshal added in v0.4.14

func (m *Marshalled) Unmarshal(s *State)

type Passwords added in v1.9.23

type Passwords map[string]*gui.Password

type ReceivePage added in v1.9.16

type ReceivePage struct {
	// contains filtered or unexported fields
}

func (*ReceivePage) AddressbookHeader added in v1.9.16

func (rp *ReceivePage) AddressbookHeader() l.Widget

func (*ReceivePage) AmountInput added in v1.9.16

func (rp *ReceivePage) AmountInput() l.Widget

func (*ReceivePage) Fn added in v1.9.16

func (rp *ReceivePage) Fn(gtx l.Context) l.Dimensions

func (*ReceivePage) GetAddressbookHistoryCards added in v1.9.16

func (rp *ReceivePage) GetAddressbookHistoryCards(bg string) (widgets []l.Widget)

func (*ReceivePage) GetQRText added in v1.9.16

func (rp *ReceivePage) GetQRText() string

func (*ReceivePage) InputMessage added in v1.9.20

func (rp *ReceivePage) InputMessage() l.Widget

func (*ReceivePage) MediumList added in v1.9.16

func (rp *ReceivePage) MediumList(gtx l.Context) l.Dimensions

func (*ReceivePage) MessageInput added in v1.9.16

func (rp *ReceivePage) MessageInput() l.Widget

func (*ReceivePage) QRButton added in v1.9.16

func (rp *ReceivePage) QRButton() l.Widget

func (*ReceivePage) QRMessage added in v1.9.16

func (rp *ReceivePage) QRMessage() l.Widget

func (*ReceivePage) RegenerateButton added in v1.9.16

func (rp *ReceivePage) RegenerateButton() l.Widget

func (*ReceivePage) SmallList added in v1.9.16

func (rp *ReceivePage) SmallList(gtx l.Context) l.Dimensions

func (*ReceivePage) Spacer added in v1.9.16

func (rp *ReceivePage) Spacer() l.Widget

type SendPage added in v1.9.16

type SendPage struct {
	// contains filtered or unexported fields
}

func (*SendPage) AddressInput added in v1.9.16

func (sp *SendPage) AddressInput() l.Widget

func (*SendPage) AddressbookHeader added in v1.9.16

func (sp *SendPage) AddressbookHeader() l.Widget

func (*SendPage) AmountInput added in v1.9.16

func (sp *SendPage) AmountInput() l.Widget

func (*SendPage) Fn added in v1.9.16

func (sp *SendPage) Fn(gtx l.Context) l.Dimensions

func (*SendPage) GetAddressbookHistoryCards added in v1.9.16

func (sp *SendPage) GetAddressbookHistoryCards(bg string) (widgets []l.Widget)

func (*SendPage) InputMessage added in v1.9.20

func (sp *SendPage) InputMessage() l.Widget

func (*SendPage) MediumList added in v1.9.16

func (sp *SendPage) MediumList(gtx l.Context) l.Dimensions

func (*SendPage) MessageInput added in v1.9.16

func (sp *SendPage) MessageInput() l.Widget

func (*SendPage) PasteButton added in v1.9.16

func (sp *SendPage) PasteButton() l.Widget

func (*SendPage) SaveButton added in v1.9.16

func (sp *SendPage) SaveButton() l.Widget

func (*SendPage) SendButton added in v1.9.16

func (sp *SendPage) SendButton() l.Widget

func (*SendPage) SmallList added in v1.9.16

func (sp *SendPage) SmallList(gtx l.Context) l.Dimensions

type State added in v0.4.14

type State struct {
	// contains filtered or unexported fields
}

func GetNewState added in v0.4.14

func GetNewState(params *chaincfg.Params, activePage *uberatomic.String) *State

func (*State) ActivePage added in v0.4.14

func (s *State) ActivePage() string

func (*State) Balance added in v0.4.14

func (s *State) Balance() float64

func (*State) BalanceUnconfirmed added in v0.4.14

func (s *State) BalanceUnconfirmed() float64

func (*State) BestBlockHash added in v0.4.14

func (s *State) BestBlockHash() *chainhash.Hash

func (*State) BestBlockHeight added in v0.4.14

func (s *State) BestBlockHeight() int32

func (*State) BumpLastUpdated added in v0.4.14

func (s *State) BumpLastUpdated()

func (*State) Goroutines added in v0.4.14

func (s *State) Goroutines() []l.Widget

func (*State) IsReceivingAddress added in v1.9.16

func (s *State) IsReceivingAddress() bool

func (*State) LastUpdated added in v0.4.14

func (s *State) LastUpdated() time.Time

func (*State) Load added in v0.4.14

func (s *State) Load(filename string, pass *string) (e error)

func (*State) Marshal added in v0.4.14

func (s *State) Marshal() (out *Marshalled)

func (*State) Save added in v0.4.14

func (s *State) Save(filename string, pass *string) (e error)

func (*State) SetActivePage added in v0.4.14

func (s *State) SetActivePage(page string)

func (*State) SetAllTxs added in v0.4.14

func (s *State) SetAllTxs(atxs []btcjson.ListTransactionsResult)

func (*State) SetBalance added in v0.4.14

func (s *State) SetBalance(total float64)

func (*State) SetBalanceUnconfirmed added in v0.4.14

func (s *State) SetBalanceUnconfirmed(unconfirmed float64)

func (*State) SetBestBlockHash added in v0.4.14

func (s *State) SetBestBlockHash(h *chainhash.Hash)

func (*State) SetBestBlockHeight added in v0.4.14

func (s *State) SetBestBlockHeight(height int32)

func (*State) SetGoroutines added in v0.4.14

func (s *State) SetGoroutines(gr []l.Widget)

func (*State) SetReceivingAddress added in v1.9.16

func (s *State) SetReceivingAddress(addr btcaddr.Address)

type WalletGUI

type WalletGUI struct {
	State *State

	ChainMutex, WalletMutex   sync.Mutex
	ChainClient, WalletClient *rpcclient.Client
	WalletWatcher             qu.C
	*gui.Window
	Size    *int
	MainApp *gui.App

	RecentTxsWidget, TxHistoryWidget l.Widget

	// ReceiveAddressbook l.Widget
	// SendAddressbook    l.Widget
	ReceivePage *ReceivePage
	SendPage    *SendPage
	// contains filtered or unexported fields
}

func (*WalletGUI) Advertise added in v1.9.24

func (wg *WalletGUI) Advertise() (e error)

func (*WalletGUI) ChainNotifications added in v0.4.14

func (wg *WalletGUI) ChainNotifications() *rpcclient.NotificationHandlers

func (*WalletGUI) ConsolePage added in v0.4.14

func (wg *WalletGUI) ConsolePage() *Console

func (*WalletGUI) CreateWalletPage added in v0.4.14

func (wg *WalletGUI) CreateWalletPage(gtx l.Context) l.Dimensions

func (*WalletGUI) GetAppWidget added in v0.4.14

func (wg *WalletGUI) GetAppWidget() (a *gui.App)

func (*WalletGUI) GetBools added in v0.4.14

func (wg *WalletGUI) GetBools() BoolMap

func (*WalletGUI) GetButtons added in v0.4.14

func (wg *WalletGUI) GetButtons()

func (*WalletGUI) GetCheckables added in v1.9.16

func (wg *WalletGUI) GetCheckables() CheckableMap

func (*WalletGUI) GetClickables added in v0.4.14

func (wg *WalletGUI) GetClickables() ClickableMap

func (*WalletGUI) GetIncDecs added in v0.4.14

func (wg *WalletGUI) GetIncDecs() IncDecMap

func (*WalletGUI) GetInputs added in v0.4.14

func (wg *WalletGUI) GetInputs() Inputs

func (*WalletGUI) GetLists added in v0.4.14

func (wg *WalletGUI) GetLists() (o ListMap)

func (*WalletGUI) GetNewReceivingAddress added in v1.9.16

func (wg *WalletGUI) GetNewReceivingAddress()

func (*WalletGUI) GetNewReceivingQRCode added in v1.9.16

func (wg *WalletGUI) GetNewReceivingQRCode(qrText string)

func (*WalletGUI) GetPasswords added in v0.4.14

func (wg *WalletGUI) GetPasswords() (passwords Passwords)

GetPasswords returns the passwords used in the wallet GUI

func (*WalletGUI) GetReceivePage added in v1.9.16

func (wg *WalletGUI) GetReceivePage() (rp *ReceivePage)

func (*WalletGUI) GetRunUnit added in v0.4.14

func (wg *WalletGUI) GetRunUnit(name string, before, after func(), args ...string) *rununit.RunUnit

func (*WalletGUI) GetSendPage added in v1.9.16

func (wg *WalletGUI) GetSendPage() (sp *SendPage)

func (*WalletGUI) HelpPage added in v1.9.16

func (wg *WalletGUI) HelpPage() func(gtx l.Context) l.Dimensions

func (*WalletGUI) HistoryPage added in v0.4.14

func (wg *WalletGUI) HistoryPage() l.Widget

func (*WalletGUI) HistoryPageStatusFilter added in v0.4.14

func (wg *WalletGUI) HistoryPageStatusFilter() l.Widget

func (*WalletGUI) HistoryPageView added in v0.4.14

func (wg *WalletGUI) HistoryPageView() l.Widget

func (*WalletGUI) OverviewPage added in v0.4.14

func (wg *WalletGUI) OverviewPage() l.Widget

func (*WalletGUI) Page added in v0.4.14

func (wg *WalletGUI) Page(title string, widget gui.Widgets) func(gtx l.Context) l.Dimensions

func (*WalletGUI) PageTopBarButton added in v0.4.14

func (wg *WalletGUI) PageTopBarButton(
	name string, index int, ico *[]byte, onClick func(string), app *gui.App,
	highlightColor string,
) func(gtx l.Context) l.Dimensions

func (*WalletGUI) RecentTransactions added in v0.4.14

func (wg *WalletGUI) RecentTransactions(n int, listName string) l.Widget

RecentTransactions generates a display showing recent transactions

fields to use: Address, Amount, BlockIndex, BlockTime, Category, Confirmations, Generated

func (*WalletGUI) Run added in v0.4.14

func (wg *WalletGUI) Run() (e error)

func (*WalletGUI) RunStatusPanel added in v0.4.14

func (wg *WalletGUI) RunStatusPanel(gtx l.Context) l.Dimensions

func (*WalletGUI) SetNodeRunState added in v0.4.14

func (wg *WalletGUI) SetNodeRunState(b bool)

func (*WalletGUI) SetWalletRunState added in v0.4.14

func (wg *WalletGUI) SetWalletRunState(b bool)

func (*WalletGUI) ShuffleSeed added in v1.9.23

func (wg *WalletGUI) ShuffleSeed()

func (*WalletGUI) SideBarButton added in v0.4.14

func (wg *WalletGUI) SideBarButton(title, page string, index int) func(gtx l.Context) l.Dimensions

func (*WalletGUI) StatusBarButton added in v0.4.14

func (wg *WalletGUI) StatusBarButton(
	name string,
	index int,
	ico *[]byte,
	onClick func(string),
	app *gui.App,
) func(gtx l.Context) l.Dimensions

func (*WalletGUI) WalletAndClientRunning added in v0.4.14

func (wg *WalletGUI) WalletAndClientRunning() bool

func (*WalletGUI) WalletNotifications added in v0.4.14

func (wg *WalletGUI) WalletNotifications() *rpcclient.NotificationHandlers

func (*WalletGUI) Watcher added in v1.9.16

func (wg *WalletGUI) Watcher() qu.C

Watcher keeps the chain and wallet and rpc clients connected

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL