Skip to content

A Rust library to build a Chat Client that uses conrod for 2D graphics and Tokio for connection.

License

Notifications You must be signed in to change notification settings

alanpoon/conrod_chat

Repository files navigation

Conrod Chat

This is a basic sample crate for creating a chat client with Rust using Conrod with several backend options. Conrod allows different graphical backend like "glium", "winit" or even "SDL2". This crate allows different socket backend options. At the moment, only the websocket crate.

Hot code reloading

This is a feature that is only available on desktop. It uses the crate "libloading" to reload "test_shared.rs" code during runtime. It helps programmers to adjust components of the gui on the fly.

To get started.

  1. You need to compile test_shared.rs into a crate.
rustc src/test_shared.rs --crate-name test_shared --crate-type dylib --out-dir target/debug
  1. Run cargo with --feature="hotload"
  2. During runtime, edit src/test_shared.rs and run rustc src/test_shared.rs --crate-name test_shared --crate-type dylib --out-dir target/debug to see hot reloading in action.

Without Hot code reloading

The Chat's components' positions will be taken from staticapplication.rs instead of dyapplication.rs. Run cargo without the hotload feature.

Running examples

Currently, there are only one example which uses websocket backend. The default features in cargo have already the correct feature implementations so you don't need to specify.

cargo run --example websocket_glium

android cargo apk build --example run -L ~/software/openssl-1.0.2l/libcrypto.a -l ssl -lcryto adb install -r target/android-artifacts/app/build/outputs/apk/app-debug.apk

About

A Rust library to build a Chat Client that uses conrod for 2D graphics and Tokio for connection.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published