bernii/gauge.js

Configuration option for rotating gauge?

jdgamble opened this issue · 1 comments

I like the capabilities of gauge.js and would like to use it in my application. However, I would like to be able to rotate the canvas element at an arbitrary angle prior to creating the gauge, so I can create top/bottom or left/right style gauges. Unfortunately, just calling the rotate() method on the canvas context prior to instantiating the new Gauge does not seem to work. Are there any additional configuration options to accomplish this or examples you could share on how to do this?

Add a transform to your canvas
<canvas style="transform: rotate(' + this.getProperty("GaugeRotation") + 'deg);'">