Comments (6)
Thanks for your report! As far as I will have free time I will check this case. Most probably your solution is a correct way to solve the issue. To be honest I really wasn't check the highlights with more than 3 colors....
from canvas-gauges.
I am running into the same issue. I have 5 color areas and the image is flipped 180 degrees. The workaround doesn't work for me because I want to use more than one gauge and the other ones only have 3 color areas. Also for my gauge with the 5 color areas it didn't put the 5th area in the right location. It was placed beneath the 1st area.
Thanks
from canvas-gauges.
Thank you. Working on fix...
from canvas-gauges.
Just to be clear with my little hacky workaround I got the line number wrong. Should be placed after line 557:
ctx.arc( 0, 0, r2, sa - 0.2, ea + 0.2, false);
then put:
ctx.rotate( radians( -90));
This is just a little hack though and still might not work in your case. I am sure Mikhus will have a better solution soon.
from canvas-gauges.
Fixed with commit eb3f264
from canvas-gauges.
to jeffjenk: It's better after line 532 just add ctx.save();
I did it with the specified commit. I've also added example.html containing 5 highlights, so you can check easily.
Best regards,
Mike
from canvas-gauges.
Related Issues (20)
- can't assign a deferent value to multiple gauges in one page
- canvas to SVG HOT 1
- Only Half of Linear Gauge appearing in Home Assistant HOT 1
- Horizontal rotating gauge
- No valuebox when using a horizontal linear gauge?
- radial gauge seems to be broken. HOT 2
- Upstream Dependency Conflicts
- Congratulations on your AWESOME script! HOT 1
- AnimationRule HOT 1
- Unable to change Highlight HOT 1
- Interactive Gauges
- Gauge title spanning two lines? HOT 2
- deviation mode for linear gauges HOT 1
- Canvas-Gauge HOT 1
- Draw problem after a few value updates HOT 4
- RadialGauge animationTarget = "plate" turning needle issue HOT 1
- compass gauge with int values HOT 1
- howto adjust LinearGauge to container without cutting scale
- CSS warnings "Expected color but found ‘null’
- is there a possibility to read logarithmic scales in stead of linear? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from canvas-gauges.