Package wm

import "github.com/BurntSushi/wingo-conc/wm"
Overview
Index

Overview ▾

package wm is a Wingo specific package that maintains the global state of Wingo.

Index ▾

Variables
func AddClient(c Client)
func AddWorkspace(name string) error
func ClientMouseSetup(c Client)
func FYI(format string, vals ...interface{})
func FocusFallback()
func FrameMouseSetup(c Client, frameId xproto.Window)
func FramePieceMouseSetup(c Client, piece string, pieceid xproto.Window)
func Initialize(x *xgbutil.XUtil, cmdEnv *gribble.Environment, hacks CommandHacks)
func PopupError(format string, vals ...interface{})
func RemoveClient(c Client)
func RemoveWorkspace(wrk *workspace.Workspace) error
func RenameWorkspace(wrk *workspace.Workspace, newName string) error
func RootGeomChangeFun() xevent.ConfigureNotifyFun
func SetWorkspace(wrk *workspace.Workspace, greedy bool)
func ShowCycleClient(keyStr string, activeWrk, visible, iconified bool)
func ShowSelectClient(tabComp int, activeWrk, visible, iconified bool, data interface{})
func ShowSelectWorkspace(tabComp int, data interface{})
func Workspace() *workspace.Workspace
func WorkspaceToHead(headIndex int, wrk *workspace.Workspace)
type AllPrompts
type Client
    func FindManagedClient(id xproto.Window) Client
    func LastFocused() Client
type ClientList
    func (cls ClientList) Get(i int) heads.Client
    func (cls ClientList) Len() int
type CommandHacks
type Configuration
type ThemeBorders
    func (tb ThemeBorders) FrameTheme() *frame.BordersTheme
type ThemeConfig
type ThemeFull
    func (tf ThemeFull) FrameTheme() *frame.FullTheme
type ThemePrompt
    func (tp ThemePrompt) CycleTheme() *prompt.CycleTheme
    func (tp ThemePrompt) InputTheme() *prompt.InputTheme
    func (tp ThemePrompt) MessageTheme() *prompt.MessageTheme
    func (tp ThemePrompt) SelectTheme() *prompt.SelectTheme
type ThemeSlim
    func (ts ThemeSlim) FrameTheme() *frame.SlimTheme

Package files

bindings_key.go bindings_mouse.go client.go command_hacks.go config.go config_theme_setters.go doc.go ewmh.go prompt.go state.go theme.go

Variables

var (
    X         *xgbutil.XUtil
    Root      *xwindow.Window
    Startup   bool
    Clients   ClientList
    Heads     *heads.Heads
    Prompts   AllPrompts
    Config    *Configuration
    Theme     *ThemeConfig
    StickyWrk *workspace.Sticky

    ShapeExt bool
    Restart  bool
)
var (
    MouseClientClicked xproto.Window
)

MouseClientClicked is a terrible hack to inject state into commands. Basically, if a command is given with "::mouse::" as the argument for a client parameter, this variable will be checked and its value will be used.

func AddClient

func AddClient(c Client)

func AddWorkspace

func AddWorkspace(name string) error

func ClientMouseSetup

func ClientMouseSetup(c Client)

func FYI

func FYI(format string, vals ...interface{})

func FocusFallback

func FocusFallback()

func FrameMouseSetup

func FrameMouseSetup(c Client, frameId xproto.Window)

func FramePieceMouseSetup

func FramePieceMouseSetup(c Client, piece string, pieceid xproto.Window)

func Initialize

func Initialize(x *xgbutil.XUtil,
    cmdEnv *gribble.Environment, hacks CommandHacks)

func PopupError

func PopupError(format string, vals ...interface{})

func RemoveClient

func RemoveClient(c Client)

func RemoveWorkspace

func RemoveWorkspace(wrk *workspace.Workspace) error

func RenameWorkspace

func RenameWorkspace(wrk *workspace.Workspace, newName string) error

func RootGeomChangeFun

func RootGeomChangeFun() xevent.ConfigureNotifyFun

func SetWorkspace

func SetWorkspace(wrk *workspace.Workspace, greedy bool)

func ShowCycleClient

func ShowCycleClient(keyStr string, activeWrk, visible, iconified bool)

func ShowSelectClient

func ShowSelectClient(tabComp int, activeWrk, visible, iconified bool,
    data interface{})

func ShowSelectWorkspace

func ShowSelectWorkspace(tabComp int, data interface{})

func Workspace

func Workspace() *workspace.Workspace

func WorkspaceToHead

func WorkspaceToHead(headIndex int, wrk *workspace.Workspace)

type AllPrompts

type AllPrompts struct {
    Cycle   *prompt.Cycle
    Slct    *prompt.Select
    Input   *prompt.Input
    Message *prompt.Message
    // contains filtered or unexported fields
}

type Client

type Client interface {
    Id() xproto.Window
    Frame() frame.Frame
    IsMapped() bool
    Iconified() bool
    IsSkipPager() bool
    IsSkipTaskbar() bool
    Workspace() workspace.Workspacer
    ImminentDestruction() bool
    IsMaximized() bool
    Remaximize()

    CycleItem() *prompt.CycleItem
    SelectItem() *prompt.SelectItem

    DragMoveBegin(rx, ry, ex, ey int) bool
    DragMoveStep(rx, ry, ex, ey int)
    DragMoveEnd(rx, ry, ex, ey int)

    DragResizeBegin(direction uint32, rx, ry, ex, ey int) (bool, xproto.Cursor)
    DragResizeStep(rx, ry, ex, ey int)
    DragResizeEnd(rx, ry, ex, ey int)
}

func FindManagedClient

func FindManagedClient(id xproto.Window) Client

func LastFocused

func LastFocused() Client

type ClientList

type ClientList []Client

func (ClientList) Get

func (cls ClientList) Get(i int) heads.Client

func (ClientList) Len

func (cls ClientList) Len() int

type CommandHacks

type CommandHacks struct {
    MouseResizeDirection     func(cmdStr string) (string, error)
    CycleClientRunWithKeyStr func(keyStr, cmdStr string) (func(), error)
}

type Configuration

type Configuration struct {
    ConfirmKey, CancelKey string
    BackspaceKey          string
    TabKey, RevTabKey     string

    Ffm                 bool
    FfmFocus            bool
    FfmRaise            bool
    FfmStartupFocus     bool
    FfmHead             bool
    Workspaces          []string
    DefaultLayout       string
    PopupTime           int
    ShowFyi, ShowErrors bool
    Shell               string
    AudioProgram        string
    // contains filtered or unexported fields
}

type ThemeBorders

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

func (ThemeBorders) FrameTheme

func (tb ThemeBorders) FrameTheme() *frame.BordersTheme

type ThemeConfig

type ThemeConfig struct {
    DefaultIcon *xgraphics.Image
    Full        ThemeFull
    Borders     ThemeBorders
    Slim        ThemeSlim
    Prompt      ThemePrompt
}

type ThemeFull

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

func (ThemeFull) FrameTheme

func (tf ThemeFull) FrameTheme() *frame.FullTheme

type ThemePrompt

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

func (ThemePrompt) CycleTheme

func (tp ThemePrompt) CycleTheme() *prompt.CycleTheme

func (ThemePrompt) InputTheme

func (tp ThemePrompt) InputTheme() *prompt.InputTheme

func (ThemePrompt) MessageTheme

func (tp ThemePrompt) MessageTheme() *prompt.MessageTheme

func (ThemePrompt) SelectTheme

func (tp ThemePrompt) SelectTheme() *prompt.SelectTheme

type ThemeSlim

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

func (ThemeSlim) FrameTheme

func (ts ThemeSlim) FrameTheme() *frame.SlimTheme