Skip to content

Commit

Permalink
updated readme to reflect new options
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexey Tikhonov committed Aug 8, 2017
1 parent d143a87 commit 77ae3c5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ Compatible with OpenSeadragon 2.1.0 or greater.

To use, include the `openseadragon-fabricjs-overlay.js` file after `openseadragon.js` on your web page.

To add fabricjs overlay capability to your OpenSeadragon Viewer, call `fabricjsOverlay()` on it. This will return a new object with the following methods:
To add fabricjs overlay capability to your OpenSeadragon Viewer, call `fabricjsOverlay({scale: scaleWidth})` on it. `scaleWidth` is arbitrary scale for created fabric canvas. 0 corresponds to 0 and `scaleWidth` corresponds to 1 in OpenSeadragon viewport coordinates. This will return a new object with the following methods:

* `fabricCanvas()`: Returns fabricjs canvas that you can add elements to
* `resize()`: If your viewer changes size, you'll need to resize the fabricjs overlay by calling this method.

See [online demo](http://altert.github.io/OpenseadragonFabricjsOverlay/demo.html) or demo.html for an example of it in use.
See [online demo](http://altert.github.io/OpenseadragonFabricjsOverlay/demo.html) or demo.html for an example of it in use.

## Thanks

Expand Down

0 comments on commit 77ae3c5

Please sign in to comment.