import "fyne.io/fyne/v2"
  

Usage

type ShortcutHandler

  type ShortcutHandler struct {
}
  

ShortcutHandler is a default implementation of the shortcut handler for [CanvasObject].

func (*ShortcutHandler) AddShortcut

  func (sh *ShortcutHandler) AddShortcut(shortcut Shortcut, handler func(shortcut Shortcut))
  

AddShortcut register a handler to be executed when the shortcut action is triggered

func (*ShortcutHandler) RemoveShortcut

  func (sh *ShortcutHandler) RemoveShortcut(shortcut Shortcut)
  

RemoveShortcut removes a registered shortcut

func (*ShortcutHandler) TypedShortcut

  func (sh *ShortcutHandler) TypedShortcut(shortcut Shortcut)
  

TypedShortcut handle the registered shortcut