8000 GitHub - joshbarrass/giu: Cross platform rapid GUI framework for golang based on Dear ImGui.
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
forked from AllenDang/giu

Cross platform rapid GUI framework for golang based on Dear ImGui.

License

Notifications You must be signed in to change notification settings

joshbarrass/giu

 
 

Repository files navigation

giu

Join the chat at https://gitter.im/AllenDang-giu/community Go Report Card Build Status Godoc Card

Cross platform rapid GUI framework for golang based on Dear ImGui and the great golang binding imgui-go.

Any contribution (features, widgets, tutorials, documents and etc...) is appreciated!

Supported Platforms

giu is built upon GLFW v3.3, so idealy giu could support all platforms that GLFW v3.3 supports.

  • Windows (only tested on Windows 10 x64)
  • MacOS (only tested on MacOS v10.15)
  • Linux (thanks remeh to test it)
  • Raspberry pi 3b (thanks sndvaps to test it)

Features

Compare to other Dear ImGui golang bindings, giu has following features:

  • Live-update during the resizing of OS window (implemented on GLFW 3.3 and OpenGL 3.2).
  • Redraw only when user event occurred. Costs only 0.5% CPU usage with 60FPS.
  • Declarative UI (see examples for more detail).
  • DPI awareness (auto scale font and UI to adapte high DPI monitor).
  • Drop in usage, no need to implement render and platform.
  • Freetype font rendering support.
  • OS clipboard support.

Screenshot

Hello world

package main

import (
    "fmt"

    g "github.com/AllenDang/giu"
)

func onClickMe() {
    fmt.Println("Hello world!")
}

func onImSoCute() {
    fmt.Println("Im sooooooo cute!!")
}

func loop() {
    g.SingleWindow("hello world", g.Layout{
        g.Label("Hello world from giu"),
        g.Line(
            g.Button("Click Me", onClickMe),
            g.Button("I'm so cute", onImSoCute)),
        })
}

func main() {
    wnd := g.NewMasterWindow("Hello world", 400, 200, g.MasterWindowFlagsNotResizable, nil)
    wnd.Main(loop)
}

Here is result.

Helloworld

Document

Check Wiki

Projects using giu

PipeIt is a text transformation, conversion, cleansing and extraction tool.

PipeIt Demo

About

Cross platform rapid GUI framework for golang based on Dear ImGui.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C++ 77.4%
  • C 12.1%
  • Go 10.5%
0