Add some more notes to the README + move examples out of the top level
- ID
4077ba7- date
2021-02-20 23:57:12+00:00- author
Alex Chan <alex@alexwlchan.net>- parent
b8caea2- message
Add some more notes to the README + move examples out of the top level- changed files
Changed files
README.md (419 → 1848)
diff --git a/README.md b/README.md
index 6f0e536..75c11ff 100644
--- a/README.md
+++ b/README.md
@@ -1,5 +1,8 @@
# happybackgrounds
+This is a script for generating low-contrast wallpapers and backgrounds by splattering icons from Font Awesome over a solid block of colour.
+Some examples:
+
<table>
<tr>
<td><img src="readme_images/luna.png"></td>
@@ -14,3 +17,51 @@
<td><img src="readme_images/happy.png"></td>
</tr>
</table>
+
+
+
+## Usage
+
+You need Python 3 installed.
+Clone the repo, and run the "happybackgrounds" script to see how it can be used:
+
+```console
+$ git clone https://github.com/alexwlchan/happybackgrounds.git
+$ cd happybackgrounds
+$ python3 happybackgrounds.py --help
+```
+
+You can choose:
+
+* the background colour
+* the icon to use
+* how many icons to show, and how big/small to make them
+
+The script [`run.sh`](run.sh) has the invocations that generated the examples in the table above.
+
+The script returns the path to the generated SVG file, or you can specify the output file with the `--out_path` flag.
+For example:
+
+```console
+$ python3 happybackgrounds.py --background="#d6fcff" --icon_name="snowflake"
+/var/folders/_c/h0g4c9_n6rg8d2v509hztzdc0000gn/T/tmpfo3v6nqr.svg
+```
+
+You can convert these SVGs to PNGs using ImageMagick (as was done for the table above).
+
+
+
+## Known limitations
+
+Right now I run the script repeatedly until I get a "nice-looking" result; the success rate is nowhere near good enough to drop this into an automated process.
+
+* The script isn't very smart about where it places icons.
+ Sometimes they overlap, sometimes they disappear outside the viewbox.
+* The choice of colours is sometimes good, sometimes not-so-good.
+
+
+
+
+## License
+
+CC0.
happy.svg (4730) → examples/happy.svg (4730)
diff --git a/happy.svg b/examples/happy.svg
similarity index 100%
rename from happy.svg
rename to examples/happy.svg
luna.svg (10426) → examples/luna.svg (10426)
diff --git a/luna.svg b/examples/luna.svg
similarity index 100%
rename from luna.svg
rename to examples/luna.svg
mars.svg (10824) → examples/mars.svg (10824)
diff --git a/mars.svg b/examples/mars.svg
similarity index 100%
rename from mars.svg
rename to examples/mars.svg
plants.svg (18094) → examples/plants.svg (18094)
diff --git a/plants.svg b/examples/plants.svg
similarity index 100%
rename from plants.svg
rename to examples/plants.svg
snowflake.svg (26588) → examples/snowflake.svg (26588)
diff --git a/snowflake.svg b/examples/snowflake.svg
similarity index 100%
rename from snowflake.svg
rename to examples/snowflake.svg
starfield.svg (3029) → examples/starfield.svg (3029)
diff --git a/starfield.svg b/examples/starfield.svg
similarity index 100%
rename from starfield.svg
rename to examples/starfield.svg