Getting Started

Ravel is a C++ library compiled to Javascript via the Emscripten compiler.

To insert a Ravel widget in your HTML document, create a canvas element, then pass the canvas's ID to the factory function newRavel. Finally, add some data describing the handles and you're ready to go. For example, from the top level page of the Ravelation website.

<script type="text/javascript" src="examples/jsravel.js"></script>
<script type="text/javascript" src="examples/ravel.js"></script>
<canvas width="500" height="500" id="ravel"></canvas>
<script type="text/javascript" >
var ravel=newRavel("ravel");
ravel.addHandle("Year",["1990","1991","1992"]);
ravel.addHandle("Gender",["Male","Female"]);
ravel.addHandle("Country",["Australia","UK","USA"]);
ravel.redraw();
function onunload() {ravel.delete();}
</script>

Ravelation Pty Ldt