i am using fabric.js
to write text on canva .later on click of button i want to show mirror image of text . is there any property in fabric.js
which i can use to rotate text on canvas.
Please check , http://jsfiddle.net/BTh6A/9/
document.getElementById( 'btn' ).addEventListener( 'click', function (e) {
var obj = canvas.getActiveObject();
if ( !obj ) return;
//here comes code to show mirror image
obj.set( 'fill', '#FF0000' );
canvas.renderAll();
});
Try this piece of code...I have edited it..