events

package
v0.0.0-...-e0096d9 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2018 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func KeyboardHandler

func KeyboardHandler(event chan *KeyPressEvent, terminal vte3.Terminal)

KeyboardHandler handle events from keyboard

Types

type KeyPressEvent

type KeyPressEvent struct {
	KeyVal   int
	Modifier gdk.ModifierType
}

KeyPressEvent represents a keypress consisting of the particular key (KeyVal) and possibly a modifier (0 if no modifier is given).

func (KeyPressEvent) Equals

func (kpe KeyPressEvent) Equals(k2 KeyPressEvent) bool

Equals compare two KeyPressEvents

func (KeyPressEvent) GetKeyValue

func (kpe KeyPressEvent) GetKeyValue() int

GetKeyValue returnes the KeyVal value

func (KeyPressEvent) GetModifier

func (kpe KeyPressEvent) GetModifier() Modifier

GetModifier returns the Modifier used

type Modifier

type Modifier int

Modifier represents a key modifier

const (
	// NONE is none key
	NONE Modifier = iota

	// CTRL is Control key
	CTRL
	// FN is Function key
	FN
	// HYPER is Hyper key
	HYPER
	// META is Meta key
	META
	// SUPER is Super key
	SUPER
)

Jump to

Keyboard shortcuts

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