overlays

package
v0.4.8 Latest Latest
Warning

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

Go to latest
Published: May 11, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Tool

type Tool struct {
	Icon     *gdk.Pixbuf
	Drop     func(x, y float64)
	Selected func()
}

type ToolOverlay

type ToolOverlay struct {
	Tools []Tool
	// contains filtered or unexported fields
}

ToolOverlay implements a tool selection overlay.

func Toolbar

func Toolbar(selectable bool, tools []Tool) *ToolOverlay

Toolbar contructs a tool overlay from the given tools.

func (*ToolOverlay) Configure

func (o *ToolOverlay) Configure(w, h int)

Configure implements flowui.Overlay.

func (*ToolOverlay) Draw

func (o *ToolOverlay) Draw(da *gtk.DrawingArea, cr *cairo.Context)

Draw implements flowui.Overlay.

func (*ToolOverlay) HandleKeypress

func (o *ToolOverlay) HandleKeypress(keyEvent *gdk.EventKey) bool

HandleKeypress implements tab & numbering shortcuts for keypress events. The caller should invoke this function for key presses.

func (*ToolOverlay) HandleMotionEvent

func (o *ToolOverlay) HandleMotionEvent(evt *gdk.EventMotion) bool

HandleMotionEvent implements flowui.Overlay.

func (*ToolOverlay) HandlePressEvent

func (o *ToolOverlay) HandlePressEvent(event *gdk.Event, press bool) bool

HandlePressEvent implements flowui.Overlay.

Jump to

Keyboard shortcuts

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