mg icon indicating copy to clipboard operation
mg copied to clipboard

Minimal UI library based on relm (GTK+), written in Rust.

= Mg

Minimal UI library based on https://github.com/antoyo/relm[relm] (GTK+), written in Rust.

image:https://img.shields.io/github/workflow/status/antoyo/mg/CI[link="https://github.com/antoyo/mg/actions"] image:https://img.shields.io/crates/v/mg.svg[link="https://crates.io/crates/mg"] image:https://img.shields.io/badge/rust-documentation-blue.svg[link="https://docs.rs/mg/latest/mg/"] image:https://img.shields.io/crates/d/mg.svg[link="https://crates.io/crates/mg"] image:https://img.shields.io/crates/l/mg.svg[link="LICENSE"]

== Installation

Add the following line to the dependencies section of your Cargo.toml:

[source,bash]

mg = "0.0.1" relm = "0.9.6" relm-attributes = "0.9.0" relm-derive = "0.9.2"

== Usage

In the view! macro, use the Mg widget:

[source,rust]

view! { Mg<AppCommand, NoSettings>((MODES, "examples/main.conf", None)) { // Place your main widget here. gtk::Box { } // Connect a signal to react to commands entered by the user. CustomCommand(command) => Command(command), } }