daemon

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2024 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsLightMode

func IsLightMode() bool

func RemoteCall

func RemoteCall(method string, args RPCArgs) (string, error)

Types

type Daemon

type Daemon struct {
	MouseFollowsFocus bool

	Autoconfig         bool
	DefaultKeybindings bool
	Logger             *log.Logger
	// contains filtered or unexported fields
}

func (*Daemon) FocusWinID

func (d *Daemon) FocusWinID(id int) error

func (*Daemon) FocusedWindow

func (d *Daemon) FocusedWindow() types.WindowData

func (*Daemon) GetWinTreePath

func (d *Daemon) GetWinTreePath(id int) ([]*ipc.Node, error)

GetWinTreePath returns the nodes between tree root and the passed window ID, starting with the workspace

func (*Daemon) HandlerOnClose

func (d *Daemon) HandlerOnClose(func(types.WindowData))

func (*Daemon) HandlerOnFocus

func (d *Daemon) HandlerOnFocus(func(types.WindowData))

func (*Daemon) HandlerOnNew

func (d *Daemon) HandlerOnNew(func(types.WindowData))

func (*Daemon) ListSpaces

func (d *Daemon) ListSpaces(skipOutputs []string) ([]string, error)

ListSpaces returns names of the current workspaces.

func (*Daemon) ListWindows

func (d *Daemon) ListWindows() map[string]types.WindowData

func (*Daemon) MouseToOutput

func (d *Daemon) MouseToOutput(output string) error

func (*Daemon) MoveSpaceToOutput

func (d *Daemon) MoveSpaceToOutput(space, output string, focusedWinData types.WindowData) error

func (*Daemon) MoveWinToSpace

func (d *Daemon) MoveWinToSpace(winID int, space string) error

func (*Daemon) MoveWinToSpaceNum

func (d *Daemon) MoveWinToSpaceNum(winID, spaceNum int) error

func (*Daemon) PrevWindow

func (d *Daemon) PrevWindow() types.WindowData

func (*Daemon) RemoteCopy

func (d *Daemon) RemoteCopy(args RPCArgs, ret *string) error

RemoteCopy is an RPC method

func (*Daemon) RemoteExec

func (d *Daemon) RemoteExec(args RPCArgs, ret *string) error

RemoteExec is an RPC method

func (*Daemon) RemoteFZFList

func (d *Daemon) RemoteFZFList(_ RPCArgs, reply *string) error

RemoteFZFList is an RPC method

func (*Daemon) RemoteFZFListPickSpace

func (d *Daemon) RemoteFZFListPickSpace(_ RPCArgs, reply *string) error

RemoteFZFListPickSpace is an RPC method

func (*Daemon) RemoteFZFListPickWin

func (d *Daemon) RemoteFZFListPickWin(_ RPCArgs, reply *string) error

RemoteFZFListPickWin is an RPC method

func (*Daemon) RemoteFocusWinID

func (d *Daemon) RemoteFocusWinID(args RPCArgs, _ *string) error

RemoteFocusWinID is an RPC method

func (*Daemon) RemoteGetPathFiles

func (d *Daemon) RemoteGetPathFiles(args RPCArgs, ret *string) error

RemoteGetPathFiles is an RPC method

func (*Daemon) RemoteMoveSpaceToOutput

func (d *Daemon) RemoteMoveSpaceToOutput(args RPCArgs, _ *string) error

RemoteMoveSpaceToOutput is an RPC method

func (*Daemon) RemoteMoveWinToSpace

func (d *Daemon) RemoteMoveWinToSpace(args RPCArgs, _ *string) error

RemoteMoveWinToSpace is an RPC method

func (*Daemon) RemoteSetConfig

func (d *Daemon) RemoteSetConfig(args RPCArgs, _ *string) error

RemoteSetConfig is an RPC method

func (*Daemon) RemoteShouldOpen

func (d *Daemon) RemoteShouldOpen(args RPCArgs, reply *string) error

RemoteShouldOpen is an RPC method

func (*Daemon) RemoteUsrCmd

func (d *Daemon) RemoteUsrCmd(rpcArgs RPCArgs, rpcRet *string) error

RemoteUsrCmd is an RPC method

func (*Daemon) RemoteWinList

func (d *Daemon) RemoteWinList(_ RPCArgs, reply *string) error

RemoteWinList is an RPC method

func (*Daemon) RemoteWinToSpace

func (d *Daemon) RemoteWinToSpace(args RPCArgs, ret *string) error

RemoteWinToSpace is an RPC method

func (*Daemon) Start

func (d *Daemon) Start()

func (*Daemon) SwayMsg

func (d *Daemon) SwayMsg(msg string, args ...any) error

func (*Daemon) SwayMsgs

func (d *Daemon) SwayMsgs(msgs []string) error

func (*Daemon) WinMatchApp

func (d *Daemon) WinMatchApp(win types.WindowData, match string) bool

func (*Daemon) WinMatchTitle

func (d *Daemon) WinMatchTitle(win types.WindowData, match string) bool

type RPCArgs

type RPCArgs struct {
	WinID             int
	SpaceNum          int
	Workspace         string
	PID               int
	MouseFollowsFocus bool
	ExePath           string
	UsrCmd            string
	UsrArgs           string
	Clipboard         string
}

type WindowFocus

type WindowFocus []string

Jump to

Keyboard shortcuts

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