settings

package
v1.5.34 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2023 License: GPL-3.0 Imports: 10 Imported by: 0

README

Style

Defines terminal interface styles.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	SliverDefault = table.Style{
		Name: "SliverDefault",
		Box: table.BoxStyle{
			BottomLeft:       " ",
			BottomRight:      " ",
			BottomSeparator:  " ",
			Left:             " ",
			LeftSeparator:    " ",
			MiddleHorizontal: "=",
			MiddleSeparator:  " ",
			MiddleVertical:   " ",
			PaddingLeft:      " ",
			PaddingRight:     " ",
			Right:            " ",
			RightSeparator:   " ",
			TopLeft:          " ",
			TopRight:         " ",
			TopSeparator:     " ",
			UnfinishedRow:    "~~",
		},
		Color: table.ColorOptions{
			IndexColumn:  text.Colors{},
			Footer:       text.Colors{},
			Header:       text.Colors{},
			Row:          text.Colors{},
			RowAlternate: text.Colors{},
		},
		Format: table.FormatOptions{
			Footer: text.FormatDefault,
			Header: text.FormatTitle,
			Row:    text.FormatDefault,
		},
		Options: table.Options{
			DrawBorder:      false,
			SeparateColumns: true,
			SeparateFooter:  false,
			SeparateHeader:  true,
			SeparateRows:    false,
		},
	}
)

Functions

func GetAutoAdult

func GetAutoAdult(con *console.SliverConsoleClient) bool

GetAutoAdult - Get the current auto adult setting

func GetPageSize

func GetPageSize() int

GetPageSize - Page size for tables

func GetTableStyle

func GetTableStyle(con *console.SliverConsoleClient) table.Style

GetTableStyle - Get the current table style

func GetTableWithBordersStyle

func GetTableWithBordersStyle(con *console.SliverConsoleClient) table.Style

GetTableWithBordersStyle - Get the table style with borders

func IsUserAnAdult

func IsUserAnAdult(con *console.SliverConsoleClient) bool

IsUserAnAdult - This should be called for any dangerous (OPSEC-wise) functions

func PagesOf

func PagesOf(renderedTable string) [][]string

PagesOf - Return the pages of a table

func PaginateTable

func PaginateTable(tw table.Writer, skipPages int, overflow bool, interactive bool, con *console.SliverConsoleClient)

PaginateTable - Render paginated table to console

func SettingsAlwaysOverflow

func SettingsAlwaysOverflow(ctx *grumble.Context, con *console.SliverConsoleClient)

SettingsAlwaysOverflow - Toggle always overflow

func SettingsAutoAdultCmd

func SettingsAutoAdultCmd(ctx *grumble.Context, con *console.SliverConsoleClient)

SettingsAutoAdultCmd - The client settings command

func SettingsBeaconsAutoResultCmd

func SettingsBeaconsAutoResultCmd(ctx *grumble.Context, con *console.SliverConsoleClient)

SettingsBeaconsAutoResultCmd - The client settings command

func SettingsCmd

func SettingsCmd(ctx *grumble.Context, con *console.SliverConsoleClient)

SettingsCmd - The client settings command

func SettingsSaveCmd

func SettingsSaveCmd(ctx *grumble.Context, con *console.SliverConsoleClient)

SettingsSaveCmd - The client settings command

func SettingsSmallTerm

func SettingsSmallTerm(ctx *grumble.Context, con *console.SliverConsoleClient)

SettingsSmallTerm - Modify small terminal width value

func SettingsTablesCmd

func SettingsTablesCmd(ctx *grumble.Context, con *console.SliverConsoleClient)

SettingsTablesCmd - The client settings command

Types

This section is empty.

Jump to

Keyboard shortcuts

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