Update README.md

This commit is contained in:
Preet
2017-01-12 00:14:25 -08:00
committed by GitHub
parent 0d6ab78636
commit 2f2131e2e6

View File

@@ -1,10 +1,20 @@
# Rough.js
## Welcome to GitHub Pages
This is a light weight [Canvas](https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API) based library that lets you draw in a _sketchy_, _hand-drawn-like_, style.
You can use the [editor on GitHub](https://github.com/pshihn/rough/edit/master/README.md) to maintain and preview the content for your website in Markdown files.
The library defines primitives to draw lines, curves, arcs, polygons, circles, and ellipses. It also supports drawing [SVG paths](https://developer.mozilla.org/en-US/docs/Web/SVG/Tutorial/Paths).
Whenever you commit to this repository, GitHub Pages will run [Jekyll](https://jekyllrb.com/) to rebuild the pages in your site, from the content in your Markdown files.
This project was inspired by [Handy](http://www.gicentre.net/handy/), a java based library for [Processing](https://processing.org/).
Rough.js borrows some core algorithms from Handy, but it is _not a JS port_ for processing.js.
## Releases
The latest Rough.js release (beta version 0.1): [Download](./rough.zip)
# How to use Rough.js
## Setup
Initialize a **RoughCanvas** object by passing in the canvas node and the size of the canvas.
Following code snippet draws a rectangle.
### Markdown