desktops

package
v0.0.0-...-0caaa62 Latest Latest
Warning

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

Go to latest
Published: Sep 1, 2017 License: GPL-3.0-or-later Imports: 1 Imported by: 0

Documentation

Overview

Package desktops manages and get desktop and screens info.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CurrentDesktop

func CurrentDesktop() int

CurrentDesktop returns the current desktop number.

func CurrentViewportX

func CurrentViewportX() int

CurrentViewportX returns the current horizontal viewport number.

func CurrentViewportY

func CurrentViewportY() int

CurrentViewportY returns the current vertical viewport number.

func Cycle

func Cycle(up, loop bool)

Cycle switches to an adjacent desktop.

func HeightAll

func HeightAll() int

HeightAll returns the desktop total height.

func NbDesktops

func NbDesktops() int

NbDesktops returns the number of desktops.

func NbScreens

func NbScreens() int

NbScreens returns the number of desktop screens.

func NbViewportX

func NbViewportX() int

NbViewportX returns the number of horizontal viewports.

func NbViewportY

func NbViewportY() int

NbViewportY returns the number of vertical viewports.

func ScreenPosition

func ScreenPosition(i int) (int, int)

ScreenPosition returns the desktop screen position.

func SetCurrent

func SetCurrent(numDesktop, numViewportX, numViewportY int)

SetCurrent sets the desktop number displayed.

func WidthAll

func WidthAll() int

WidthAll returns the desktop total width.

Types

type Screen

type Screen struct {
	ID int
}

Screen defines a desktop screen.

func Screens

func Screens() []Screen

Screens returns the list of desktop screens.

func (Screen) Height

func (s Screen) Height() int

Height returns the height of a desktop screen.

func (Screen) Width

func (s Screen) Width() int

Width returns the width of a desktop screen.

Jump to

Keyboard shortcuts

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