You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
This is for the website version, not the github version, which is correct.
I've been looking through this, which is fantastic for what I need.
When testing, the guage goes all wonky if your browser is much taller than wider (Y padding only)
The solution is to change the Yo and Yi formulae
OLD:
Xo = w / 2 + dx + Ro * Math.cos(alpha),
Yo = h - (h - Cy) + dy - Ro * Math.sin(alpha),
Xi = w / 2 + dx + Ri * Math.cos(alpha),
Yi = h - (h - Cy) + dy - Ri * Math.sin(alpha),
NEW:
Xo = w / 2 + dx + Ro * Math.cos(alpha),
Yo = h - (h - Cy) - Ro * Math.sin(alpha),
Xi = w / 2 + dx + Ri * Math.cos(alpha),
Yi = h - (h - Cy) - Ri * Math.sin(alpha),
The reason is that Cy already has dy added to it ( Cy = h / 1.25 + dy )
The text was updated successfully, but these errors were encountered:
Hi,
This is for the website version, not the github version, which is correct.
I've been looking through this, which is fantastic for what I need.
When testing, the guage goes all wonky if your browser is much taller than wider (Y padding only)
The solution is to change the Yo and Yi formulae
OLD:
Xo = w / 2 + dx + Ro * Math.cos(alpha),
Yo = h - (h - Cy) + dy - Ro * Math.sin(alpha),
Xi = w / 2 + dx + Ri * Math.cos(alpha),
Yi = h - (h - Cy) + dy - Ri * Math.sin(alpha),
NEW:
Xo = w / 2 + dx + Ro * Math.cos(alpha),
Yo = h - (h - Cy) - Ro * Math.sin(alpha),
Xi = w / 2 + dx + Ri * Math.cos(alpha),
Yi = h - (h - Cy) - Ri * Math.sin(alpha),
The reason is that Cy already has dy added to it ( Cy = h / 1.25 + dy )
The text was updated successfully, but these errors were encountered: