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
Add support for dotted/dashed border styles #1146
Conversation
For anyone looking for a version of |
932773c
to
1584357
Compare
Not yet merged - looking at the new build, this approach could still be plugged into |
Any chance of this being merged any time soon? |
any progress for this MR? |
border dashed style still rendered as solid version 1.0.0-rc.3 @niklasvh |
Any update for this PR? |
Looks like this PR might be solving an issue, where in my case we use dashed/dotted borders to draw lines in a chart. We are getting a customer issue where they complain these dashed lines in the chart are coming as solid lines. I haven't tested this myself - but if this PR works, then we are considering using the fix in this PR, but it would be great if this were merged and part of an official new production release of I wonder what is the hold-up, I understand that this issue might not be a priority, but I would like to get a sense of how stable this fix is before I recommend my team to pick up this change and use it in production. |
@niklasvh Any thoughts or updates on getting this merged? |
Please fix this issue. |
Support for other border styles was added in #2531 |
@niklasvh awesome to see updates on this old ticket! |
Feature: Dotted/dashed border styles
Until now, dotted/dashed borders were rendered as solid borders. This should now render them correctly.
Implementation
The default border-rendering is left untouched: it is rendered as a shape and filled with a solid color.
However, when a border is detected as 'dotted' or 'dashed', rendering now switches to a path-based approach, which draws the path of the border and applies the appropriate style using
ctx.setLineDash()
.Thanks to @Rodris in #210 for getting things started.
Related issues/pull requests
#96, #210, #366, #413, #414, #589, #984, #1036, #1117