https://github.com/alexballas/refyne
Cross platform GUI toolkit in Go inspired by Material Design
https://github.com/alexballas/refyne
android cross-platform go golang gui hacktoberfest ios theme toolkit
Last synced: about 1 month ago
JSON representation
Cross platform GUI toolkit in Go inspired by Material Design
- Host: GitHub
- URL: https://github.com/alexballas/refyne
- Owner: alexballas
- License: bsd-3-clause
- Created: 2026-05-28T07:23:25.000Z (about 1 month ago)
- Default Branch: main
- Last Pushed: 2026-05-28T15:28:21.000Z (about 1 month ago)
- Last Synced: 2026-05-28T16:11:27.722Z (about 1 month ago)
- Topics: android, cross-platform, go, golang, gui, hacktoberfest, ios, theme, toolkit
- Language: Go
- Size: 109 MB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Security: SECURITY.md
- Authors: AUTHORS
Awesome Lists containing this project
README
# About
Refyne is a fork of [Fyne](https://github.com/fyne-io/fyne), an easy-to-use UI toolkit and app API written in Go.
It is designed to build applications that run on desktop and mobile devices with a single codebase.
# Prerequisites
To develop apps using Refyne you will need Go version 1.17 or later, a C compiler and your system's development tools.
Using the standard go tools you can install Refyne's core library using:
go get github.com/alexballas/refyne/v2@latest
After importing a new module, run the following command before compiling the code for the first time. Avoid running it before writing code that uses the module to prevent accidental removal of dependencies:
go mod tidy
# Widget demo
To run a showcase of the features of Refyne execute the following:
go install github.com/alexballas/refyne/v2/cmd/fyne_demo@latest
fyne_demo
And you should see something like this (after you click a few buttons):
Or if you are using the light theme:
And even running on a mobile device:
# Getting Started
Refyne is designed to be really easy to code with.
If you have followed the prerequisite steps above then all you need is a
Go IDE (or a text editor).
Open a new file and you're ready to write your first app!
```go
package main
import (
"github.com/alexballas/refyne/v2/app"
"github.com/alexballas/refyne/v2/container"
"github.com/alexballas/refyne/v2/widget"
)
func main() {
a := app.New()
w := a.NewWindow("Hello")
hello := widget.NewLabel("Hello Refyne!")
w.SetContent(container.NewVBox(
hello,
widget.NewButton("Hi!", func() {
hello.SetText("Welcome :)")
}),
))
w.ShowAndRun()
}
```
And you can run that simply as:
go run main.go
> [!NOTE]
> The first compilation of Refyne on Windows _can_ take up to 10 minutes, depending on your hardware. Subsequent builds will be fast.
It should look like this:
## Run in mobile simulation
There is a helpful mobile simulation mode that gives a hint of how your app would work on a mobile device:
go run -tags mobile main.go
Another option is to use the `fyne` command, see [Packaging for mobile](#packaging-for-mobile).
# Installing
Using `go install` will copy the executable into your go `bin` dir.
To install the application with icons etc into your operating system's standard
application location you can use the `fyne` utility and the "install" subcommand.
go install github.com/alexballas/refyne/v2/cmd/fyne@latest
fyne install
# Packaging for mobile
To run on a mobile device it is necessary to package up the application.
To do this we can use the `fyne` utility "package" subcommand.
You will need to add appropriate parameters as prompted, but the basic command is shown below.
Once packaged you can install using the platform development tools or the `fyne` "install" subcommand.
fyne package -os android -appID my.domain.appname
fyne install -os android
The built Android application can run either in a real device or an Android emulator.
However, building for iOS is slightly different.
If the "-os" argument is "ios", it is built only for a real iOS device.
Specifying "-os" to "iossimulator" allows the application to run in an iOS simulator:
fyne package -os ios -appID my.domain.appname
fyne package -os iossimulator -appID my.domain.appname
# Preparing a release
Using the `fyne` utility "release" subcommand you can package up your app for release
to app stores and market places. Make sure you have the standard build tools installed
and have followed the platform documentation for setting up accounts and signing.
Then you can execute something like the following, notice the `-os ios` parameter allows
building an iOS app from macOS computer. Other combinations work as well :)
$ fyne release -os ios -certificate "Apple Distribution" -profile "My App Distribution" -appID "com.example.myapp"
The above command will create a '.ipa' file that can then be uploaded to the iOS App Store.
# Documentation
API reference is available on [pkg.go.dev](https://pkg.go.dev/github.com/alexballas/refyne/v2?tab=doc).
# Additional apps
It is recommended that you install the following additional app:
| app | go install | description |
| ------------- | ------------------------------------------------------- | ---------------------------------------------------------------------- |
| fyne_settings | `github.com/alexballas/refyne/v2/cmd/fyne_settings` | A GUI for managing your global Refyne settings like theme and scaling |