Closed Moulde closed 7 years ago
Hi. Thank you for contribution!
Yes, I have an idea on this - is to provide some events which will make possible to inject into gauge drawing order. Something like:
gauge.beforeDraw('needle', function(canvasContext) {
// do some custom drawings on a given canvas
});
But this currently is not implemented, will have it as a working idea for further releases.
That sounds like a great way to implement it.
Let's keep it open until implemented :)
Implemented in branch 2.1.0
Where and how do i call guage.before()? I added guage.js inside asset folder
Hi I'm trying to recreate a gauge like this. http://www.publicdomainpictures.net/pictures/50000/velka/fuel-gauge.jpg
So i need to draw an icon on the gauge. I tried just getting the canvas context and drawing the icon, and it works, but after updating the value, the gauge is redrawn again, and so the image disappears.
And i am not able to draw the icon below the needle, as it needs to be drawn in the correct order.
Any ideas? Thanks in advance.