-
Notifications
You must be signed in to change notification settings - Fork 5
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
'edge-text-rotation': 'autorotate' breaks colors #7
Comments
I forked this repo in hopes of fixing this but realized this uses https://github.com/gliffy/canvas2svg under the hood and I wasn't really ready to dig into that. I wrote a temporary fix for my case which uses DOMParser to edit the generated svg and patch the missing fill colors. Maybe it will work for your use case? You may have to adjust the fill color accordingly.
|
It looks like once the rotation of text is set, all parameters of existing nodes are reset. This is the commit that causes this issue: gliffy/canvas2svg@c7df7fa I revered it in my fork: kinimesi/canvas2svg@68b8ef8 It looks like it works, but I'm not exactly sure if it breaks something else. I pushed the fixed version to unstable branch. Could you please test it and let me know if it works? |
Hello @kinimesi . It looks like not only text-rotation: autorotate, but whole text-rotation attribute is not working. Can you propose the pull request to the canvas2svg? Or perhaps make cytoscape-svg dependant on your forked fix? Best regards, |
Hi @karasma3, I'm confused by this: |
Is there an update on this? |
Hi, could you please try v0.4.0 and let me if it solves your problem? |
Yes, it works, thanks a lot! |
As soon as I display any labels using
'edge-text-rotation': 'autorotate'
, the SVG loses all colors and just becomes black and white. See the attached image of a correctly displayed and an incorrectly displayed image. As soon as I remove the edge text rotation, it works again.Selector
The text was updated successfully, but these errors were encountered: