micro review and hello gio: portable GUI code, all in Go

568 views
Skip to first unread message

Jason E. Aten

unread,
Oct 4, 2019, 1:08:27 AM10/4/19
to golang-nuts
Somehow I missed Gio ( https://gioui.org/ ) on its first announcement earlier this year.

Gio -- as a pure Go GUI framework -- really ought to be better known.

Hence I offer here a short review, and a getting started example project.


A) The micro review: 

I am impressed. Gio provides an immediate mode (read sane, no callback soup) graphics framework. Animation and rendering were smooth.

Supporting mobile, wasm, macOS desktop, iOS, android, windows desktop, and wayland linux -- with x11 linux in the works, I'm told, is a bold and stunning prospect. 

 I've verified myself that macOS and Windows work well.  The same smooth experience across platforms that we've come to expect from Go command line tools. But now in GUI form.  A game engine based on Gio cannot be far behind (anyone want a fun project?!)

One caveat on Windows -- you may need to ship along the ANGLE DLLs from Chrome that are included in hello_gio below.  Eventually, the author of Gio, Elias Naur, posted that he plans to also have Vulkan underneath, which might prove more native to Windows. But relying on the same battle hardened OpenGL translation layer DLLs that Chrome and Firefox utilize on Windows is a minor packaging addendum at worst.

While still young and evolving quickly, I appreciate the ambition of Gio. What if Go were the preferred language for writing (portable) Apps and Games of all kinds?


B) The example, starter code:

I think it is worth posting my hello world experience with Gio. Both as a demonstration of its prowess, and a guide to help 
others getting started. Should you be so inclined, hello_gio will get you drawing graphics in no time.


Any questions, raise an issue on the github issues tracker, or see the Gio mailing list https://lists.sr.ht/~eliasnaur/gio


Enjoy.

Ian Lance Taylor

unread,
Oct 4, 2019, 10:27:41 AM10/4/19
to Jason E. Aten, golang-nuts
FYI, Elias gave a talk about this project at Gophercon:
https://www.youtube.com/watch?v=9D6eWP4peYM .

Ian

Elias Naur

unread,
Oct 4, 2019, 10:45:29 AM10/4/19
to golang-nuts

FYI, Elias gave a talk about this project at Gophercon:
https://www.youtube.com/watch?v=9D6eWP4peYM .

Ian

And another at Gophercon UK:

And there will be another (+workshop) at GoLab later this month :)

Thank you for the glowing (micro) review, Jason! It
warms my heart to know my work is appreciated.

You're also spot on: I want to see Go turn into a great
(or even preferred) choice for GUI programs and games.

-- elias.
Reply all
Reply to author
Forward
0 new messages