Skip to content
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

Markers don't seem to be rotated correctly #106

Open
jroessel opened this issue Jul 15, 2024 · 0 comments
Open

Markers don't seem to be rotated correctly #106

jroessel opened this issue Jul 15, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@jroessel
Copy link

Describe the bug
Seemingly at the end of Bézier segments markers are not rotated correctly.

To Reproduce

<svg xmlns="http://www.w3.org/2000/svg"
     width="275" height="200" viewBox="0 0 275 200">
  <defs>
    <marker id="Triangle" viewBox="0 0 10 10" refX="1" refY="5" 
            markerUnits="strokeWidth" markerWidth="4" markerHeight="3"
            orient="auto">
      <path d="M 0 0 L 10 5 L 0 10 z" fill="context-stroke"/>
    </marker>
  </defs>

  <g fill="none" stroke-width="10">
    <path stroke="crimson" d="M 100,75 C 125,50 150,50 175,75 l 15 15" marker-end="url(#Triangle)"/>
    <path stroke="olivedrab" d="M 175,125 C 150,150 125,150 100,125" marker-end="url(#Triangle)"/>
  </g>
</svg>

Expected behavior
The marker should be rotated to match the tangent in the marker location

@jroessel jroessel added the bug Something isn't working label Jul 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant