-
Notifications
You must be signed in to change notification settings - Fork 11.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added borderDash support for grid lines (#3136) #3142
Conversation
There seems to be a problem with this change. If the borderDash property is set for grid lines, it affects the point borders in the line graph too. Checking this out. |
Works after restoring the context once the line is drawn. Pardon my unfamiliarity with canvas drawing. Requesting a review. |
context.lineWidth = itemToDraw.glWidth; | ||
context.strokeStyle = itemToDraw.glColor; | ||
if (itemToDraw.glBorderDash) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this check should also check for the existence of context.setLineDash
. On IE 9 and 10 this does not exist.
Thanks @karthikiyengar |
👍 |
Looks good, +1 |
* Added borderDash support for grid lines (chartjs#3136) * Save and restore context to prevent border dash being applied to other elements * Adds support for borderDashOffset, checks for setLineDash (IE9/IE10) * Fixes tests
Please let me know if anything else is necessary here and I shall be happy to look into it.