-
Notifications
You must be signed in to change notification settings - Fork 81
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
Upgrade svg_fmt_color to svg rgba spec #319
Conversation
Codecov Report
@@ Coverage Diff @@
## master #319 +/- ##
==========================================
+ Coverage 78.73% 78.76% +0.03%
==========================================
Files 14 14
Lines 1171 1168 -3
==========================================
- Hits 922 920 -2
+ Misses 249 248 -1
Continue to review full report at Codecov.
|
In Gadfly, there are 2 tests that fail: line 15 & 16 in Note also that there is a second issue with the tests in |
I would be okay with updating the tests to not check hex codes directly |
Would anyone object to deleting these lines? The images that the test generates still act as a test. |
What wrong with duplicating this line Line 89 in 71ffc8e
over in Gadfly to use instead of the hex codes? Those lines are really testing whether using the dark theme works, which is something we might miss with just the image generation (except when we run full regression testing). We really need to refactor how we do testing in Gadfly. @bjarthur, thoughts? |
Nothing wrong with upgrading those lines, just checking if people thought differently from me 🙂 |
i'm fine with either deleting those lines or updating them to check for rgba. i've tried to make regression testing painless enough to do with each PR, which i believe it is, just takes time. in what way do you think gadfly testing needs refactoring? |
I also think the testing in Gadfly works well. Going back to the |
just delete those lines. it's the only testscript which has |
you could instead move them to the bottom of runtests.jl, or some other file which runtest.jl includes. this is probably the best option, as we might want to add other tests like this as well. |
actually couldn't the loop in runtest.jl be re-written as:
this would run the testscript only once, which would not only run the |
Sounds like a MS issue to me! I like the rgba spec, and think that most julia users probably do too. So my thoughts would be to patch it somehow for windows using |
It's not just a MS issue. I can reproduce with the latest Inkscape build on Ubuntu 18.04. We're gonna have to fix this regression. It's unfortunate that the RGBA standard isn't more widely supported. The best option might be option ii from here #318 (comment) |
Fixes #318
This PR
svg_fmt_color()
to include a method for the svgrgba
spec.fill(c)
andfillopacity(a)
, producing the same result as in the svg backend (alphas multiply).