stratagem

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Keystrokes

type Keystrokes []key.Key

func (Keystrokes) String

func (k Keystrokes) String() string

type Name

type Name string

type Opt

type Opt func(*Stratagems)

func WithDelay

func WithDelay(d time.Duration) Opt

func WithPressFor

func WithPressFor(pf time.Duration) Opt

func WithRandomize

func WithRandomize(r bool) Opt

func WithVerbose

func WithVerbose(v bool) Opt

type Stratagems

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

func NewStratagems

func NewStratagems(opts ...Opt) *Stratagems

func (*Stratagems) Add

func (s *Stratagems) Add(n Name, k ...key.Key)

func (*Stratagems) Call

func (s *Stratagems) Call(n Name) error

Call in that stratagem! Must hold ctrl yourself, I don't want to ruin the fun, just make my StreamDeck a tool for democracy.

func (*Stratagems) Press

func (s *Stratagems) Press(k key.Key, pressFor time.Duration)

func (*Stratagems) Print

func (s *Stratagems) Print(n Name)

func (*Stratagems) PrintAll

func (s *Stratagems) PrintAll()

Jump to

Keyboard shortcuts

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