We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a5dde31 commit 9936b7eCopy full SHA for 9936b7e
README.md
@@ -19,7 +19,12 @@ triggers the desired hotkey. A hotkey must be a combination of modifiers
19
and a single key.
20
21
```go
22
-func main() { mainthread.Init(fn) } // not necessary when use in Fyne, Ebiten or Gio.
+import (
23
+ "golang.design/x/hotkey"
24
+ "golang.design/x/hotkey/mainthread"
25
+)
26
+
27
+func main() { mainthread.Init(fn) } // Not necessary when use in Fyne, Ebiten or Gio.
28
func fn() {
29
hk := hotkey.New([]hotkey.Modifier{hotkey.ModCtrl, hotkey.ModShift}, hotkey.KeyS)
30
err := hk.Register()
0 commit comments