window

package
v0.0.0-...-eb6d389 Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2016 License: MIT, MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(p Profile) error

Types

type DefaultProfile

type DefaultProfile struct {
}

func (DefaultProfile) End

func (p DefaultProfile) End()

func (DefaultProfile) EventFocus

func (p DefaultProfile) EventFocus(w *glfw.Window, focused bool)

func (DefaultProfile) EventKey

func (p DefaultProfile) EventKey(w *glfw.Window, key glfw.Key, scancode int, action glfw.Action, mods glfw.ModifierKey)

func (DefaultProfile) EventMouseKey

func (p DefaultProfile) EventMouseKey(w *glfw.Window, key glfw.MouseButton, act glfw.Action, mod glfw.ModifierKey)

func (DefaultProfile) EventMousePos

func (p DefaultProfile) EventMousePos(w *glfw.Window, x float64, y float64)

func (DefaultProfile) EventRune

func (p DefaultProfile) EventRune(w *glfw.Window, char rune)

func (DefaultProfile) InitialSize

func (p DefaultProfile) InitialSize() (int, int)

func (DefaultProfile) InitialTitle

func (p DefaultProfile) InitialTitle() string

func (DefaultProfile) PreCreation

func (p DefaultProfile) PreCreation() error

func (DefaultProfile) Swap

func (p DefaultProfile) Swap(w *glfw.Window) error

type Profile

type Profile interface {
	InitialSize() (width int, height int)
	InitialTitle() string
	PreCreation() error
	PostCreation(w *glfw.Window) error
	EventFocus(w *glfw.Window, focused bool)
	EventResize(w *glfw.Window, width int, height int)
	EventMousePos(w *glfw.Window, x float64, y float64)
	EventMouseKey(w *glfw.Window, button glfw.MouseButton, action glfw.Action, mods glfw.ModifierKey)
	EventKey(w *glfw.Window, key glfw.Key, scancode int, action glfw.Action, mods glfw.ModifierKey)
	EventRune(w *glfw.Window, char rune)
	Draw(w *glfw.Window) error
	Swap(w *glfw.Window) error
	End()
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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