I had a look through the code to see how it manages not to use a pile of C libraries with cgo like other Go GUI libraries.
The answer is platform dependent:
Windows loads the relevant DLLs by hand and calls them. This is a well established technique in Go programs and due to the super stable DLL interface works well.
Linux has an x11 and Wayland backends and these implement (through a library) the wire protocols directly in Go which is nice and will make cross compilation and distribution easy.
macOS does appear to use cgo to access the cocoa libraries. macOS doesn't like statically linked Go programs anyway though as they don't use system name resolution so this isn't a bad compromise, but will mean macOS stuff needs to be built on macOS I think.
I didn't see Android or iOS support.
A nice innovative approach to GUI building. Since the lowest common denominator for the backends is an RGBA buffer, this will bypass all accessibility things the OS provides.
The above gleaned after a few minutes reading the source so may not be 100% accurate.
Theres is another new project which does NOT rely on CGO https://github.com/gogpu/ui Its basically the whole WebGPU implemented in Go. Theres also Gio, but not sure if its still active. CGO is a huge painโฆ
> Mobile is under consideration (no decision yet). If it is supported, it will be limited to utility-style apps โ not games or rich multi-touch experiences.
https://judi.systems/shirei/
No Multiple Windows so even desktop apps will be limited to "utility-style apps".
I compiled and ran the process_monitor example on linux: it works, compiles fast and is about 10mb. Also cross-built for windows and it's 8.4mb. Can't build for macos/arm64
(Under wine the windows exe doesn't render text. weird.)
examples/process_monitor$ GOOS=darwin GOARCH=arm64 go build
# go.hasen.dev/shirei/cocoabackend
../../../gopath/pkg/mod/go.hasen.dev/shirei@v0.5.0/cocoabackend/
perf_darwin.go:198:11: undefined: softRenderer
../../../gopath/pkg/mod/go.hasen.dev/shirei@v0.5.0/cocoabackend/
perf_darwin.go:208:22: undefined: softRenderer