diff options
author | 2020-05-05 00:05:47 +0200 | |
---|---|---|
committer | 2020-05-05 00:05:47 +0200 | |
commit | 7dc02a5e16a3143b7c3ba9270207e3ebda71d567 (patch) | |
tree | dd727f138641fbda008af8e7827369cc99420749 /examples/README.md | |
parent | 27aad74a32fd8ac2b12f9d32df8a3b61a3175457 (diff) | |
parent | 93c6be5eef577f0778b5787dac37351c035ed471 (diff) | |
download | iced-7dc02a5e16a3143b7c3ba9270207e3ebda71d567.tar.gz iced-7dc02a5e16a3143b7c3ba9270207e3ebda71d567.tar.bz2 iced-7dc02a5e16a3143b7c3ba9270207e3ebda71d567.zip |
Merge pull request #325 from hecrj/feature/canvas-interaction
Canvas interactivity and Game of Life example
Diffstat (limited to 'examples/README.md')
-rw-r--r-- | examples/README.md | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/examples/README.md b/examples/README.md index f67a0dd2..8e1b781f 100644 --- a/examples/README.md +++ b/examples/README.md @@ -50,6 +50,27 @@ We have not yet implemented a `LocalStorage` version of the auto-save feature. T [TodoMVC]: http://todomvc.com/ +## [Game of Life](game_of_life) +An interactive version of the [Game of Life], invented by [John Horton Conway]. + +It runs a simulation in a background thread while allowing interaction with a `Canvas` that displays an infinite grid with zooming, panning, and drawing support. + +The relevant code is located in the __[`main`](game_of_life/src/main.rs)__ file. + +<div align="center"> + <a href="https://gfycat.com/briefaccurateaardvark"> + <img src="https://thumbs.gfycat.com/BriefAccurateAardvark-size_restricted.gif"> + </a> +</div> + +You can run it with `cargo run`: +``` +cargo run --package game_of_life +``` + +[Game of Life]: https://en.wikipedia.org/wiki/Conway%27s_Game_of_Life +[John Horton Conway]: https://en.wikipedia.org/wiki/John_Horton_Conway + ## [Styling](styling) An example showcasing custom styling with a light and dark theme. @@ -69,7 +90,7 @@ cargo run --package styling ## Extras A bunch of simpler examples exist: -- [`bezier_tool`](bezier_tool), a Paint-like tool for drawing Bézier curves using [`lyon`]. +- [`bezier_tool`](bezier_tool), a Paint-like tool for drawing Bézier curves using the `Canvas` widget. - [`clock`](clock), an application that uses the `Canvas` widget to draw a clock and its hands to display the current time. - [`color_palette`](color_palette), a color palette generator based on a user-defined root color. - [`counter`](counter), the classic counter example explained in the [`README`](../README.md). |