Documentation ¶
Overview ¶
author: Balazs Nyiro, balazs.nyiro.ca@gmail.com
Copyright (c) 2023, Balazs Nyiro All rights reserved.
This source code (all file in this repo) is licensed under the Apache-2 style license found in the LICENSE file in the root directory of this source tree.
author: Balazs Nyiro, balazs.nyiro.ca@gmail.com
Copyright (c) 2023, Balazs Nyiro All rights reserved.
This source code (all file in this repo) is licensed under the Apache-2 style license found in the LICENSE file in the root directory of this source tree.
author: Balazs Nyiro, balazs.nyiro.ca@gmail.com
Copyright (c) 2023, Balazs Nyiro All rights reserved.
This source code (all file in this repo) is licensed under the Apache-2 style license found in the LICENSE file in the root directory of this source tree.
Index ¶
- Variables
- func Int2Str(i int) string
- func IntMax(a, b int) int
- func NewLine() string
- func OsDetect() string
- func ScreenLayerDisplay(screenLayer ScreenLayer_CharMatrix, newlineSeparator string)
- func ScreenLayersDisplayAll(layers ScreenLayers, newlineSeparator string, loopCounter int)
- func Str2Int(txt string) int
- func StrDoubleSpacesRemove(txt string) string
- func StrListRemoveEmptyElems(list []string, useTrim bool) []string
- func TerminalDimensionsSttySize() (int, int)
- func TerminalDimensionsWithSyscall() (int, int)
- func TimeSleep(interval_millisec int)
- func UserInterfaceExit()
- func UserInterfaceStart(ch_data_input chan MessageAndCharactersForWindowsUpdate, ...)
- type Char
- type LineChars
- type MessageAndCharactersForWindowsUpdate
- type ScreenColumn
- type ScreenLayer_CharMatrix
- type ScreenLayers
- type Window
- type Windows
Constants ¶
This section is empty.
Variables ¶
var Digits = "0123456789"
var TimeIntervalTerminalSizeDetectMillisec = 100 // 100 is the prod value
var TimeIntervalUserInterfaceRefreshTimeMillisec = 1000 // 10 is the prod value
Functions ¶
func ScreenLayerDisplay ¶
func ScreenLayerDisplay(screenLayer ScreenLayer_CharMatrix, newlineSeparator string)
func ScreenLayersDisplayAll ¶
func ScreenLayersDisplayAll(layers ScreenLayers, newlineSeparator string, loopCounter int)
func StrDoubleSpacesRemove ¶
func StrListRemoveEmptyElems ¶
func TerminalDimensionsSttySize ¶
https://stackoverflow.com/questions/263890/how-do-i-find-the-width-height-of-a-terminal-window https://stackoverflow.com/questions/16569433/get-terminal-size-in-go TESTED MANUALLY, can't detect terminal size from 'go test'
func TerminalDimensionsWithSyscall ¶
https://stackoverflow.com/questions/16569433/get-terminal-size-in-go TESTED MANUALLY
func UserInterfaceExit ¶
func UserInterfaceExit()
func UserInterfaceStart ¶
func UserInterfaceStart(ch_data_input chan MessageAndCharactersForWindowsUpdate, dataInputLineSeparator string)
Types ¶
type Char ¶
type Char struct {
// contains filtered or unexported fields
}
Char is the smallest object. Future: a complex obj with foreground/bg colors, display attributes
type MessageAndCharactersForWindowsUpdate ¶
type MessageAndCharactersForWindowsUpdate struct {
// contains filtered or unexported fields
}
type ScreenColumn ¶
type ScreenColumn []Char
type ScreenLayer_CharMatrix ¶
type ScreenLayer_CharMatrix struct {
// contains filtered or unexported fields
}
func ScreenLayerBorderRender ¶
func ScreenLayerBorderRender(screen ScreenLayer_CharMatrix, winParent Window) ScreenLayer_CharMatrix
func ScreenLayerCreate ¶
func ScreenLayerCreate(xLeft, yTop, width, height int, txtLayerDefault string, layerId string) ScreenLayer_CharMatrix
a screenLayer is a matrix of characters. A displayed unit. I always tried to pass a simple window instead of parameters here, but don't do that. you need to create ScreenLayers without a window
func ScreenLayerEmtpyIfWeHaveErrors ¶
func ScreenLayerEmtpyIfWeHaveErrors() ScreenLayer_CharMatrix
TESTED
type ScreenLayers ¶
type ScreenLayers []ScreenLayer_CharMatrix
func ScreenLayersRenderFromWindows ¶
func ScreenLayersRenderFromWindows(windowsRO Windows, terminalSize [2]int) ScreenLayers