summaryrefslogtreecommitdiff
path: root/examples/create-window/main.go
diff options
context:
space:
mode:
authorLenni <[email protected]>2021-03-07 09:23:33 +0100
committerLenni <[email protected]>2021-03-07 09:23:33 +0100
commit257276cd70a8423fbe4283c6d7a6b99a0c3d23eb (patch)
treee1a9d943043c18ff8fc3e71a542d543d11ff1a16 /examples/create-window/main.go
parent3577bf0f9657fa3b9edd77a71b15b8a09634461a (diff)
minor fixes
Diffstat (limited to 'examples/create-window/main.go')
-rw-r--r--examples/create-window/main.go10
1 files changed, 7 insertions, 3 deletions
diff --git a/examples/create-window/main.go b/examples/create-window/main.go
index ef7d98a..9d1784c 100644
--- a/examples/create-window/main.go
+++ b/examples/create-window/main.go
@@ -113,7 +113,7 @@ func main() {
// and reacts to it accordingly. All events are defined in the xproto subpackage.
switch ev.(type) {
case xproto.KeyPressEvent:
- // See https://pkg.go.dev/github.com/jezek/[email protected]/xproto#KeyPressEvent
+ // See https://pkg.go.dev/github.com/jezek/xgb/xproto#KeyPressEvent
// for documentation about a key press event.
kpe := ev.(xproto.KeyPressEvent)
fmt.Printf("Key pressed: %d", kpe.Detail)
@@ -129,7 +129,7 @@ func main() {
// desktop environment).
//
// If that's the case for your environment, closing this example's window
- // will also call the underlying Go program (because closing the X
+ // will also close the underlying Go program (because closing the X
// connection gives a nil event and EOF error).
//
// Consider how a single application might have multiple windows
@@ -137,7 +137,11 @@ func main() {
//
// With other DEs, the X connection will still stay open even after the
// X window is closed. For these DEs (e.g. i3) we have to check whether
- // the WM sent us a DestroyNotifyEvent and close our program:
+ // the WM sent us a DestroyNotifyEvent and close our program.
+ //
+ // For more information about closing windows while maintaining
+ // the X connection see
+ // https://github.com/jezek/xgbutil/blob/master/_examples/graceful-window-close/main.go
return
}
}