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

StaveModifiers placed at the end of the Stave collide with StaveTies without end notes. #489

Closed
Silverwolf90 opened this issue Dec 18, 2016 · 2 comments · Fixed by #1198
Closed
Labels

Comments

@Silverwolf90
Copy link
Contributor

See the collision at the end of the stave in this example:

image

StaveModifiers placed at the beginning do not exhibit this issue (although the spacing leaves something to be desired):

image

@Silverwolf90 Silverwolf90 changed the title StaveModifiers placed at the end of the Stave collide with StaveTie's without end notes. StaveModifiers placed at the end of the Stave collide with StaveTies without end notes. Dec 18, 2016
@0xfe
Copy link
Owner

0xfe commented Dec 19, 2016

This is because Stave.setTieEndX() does not accommodate for modifiers.

From src/stave.js:

  getTieStartX() { return this.start_x; }
  getTieEndX() { return this.x + this.width; }

So while getTieStartX() is based on Stave.start_x which changes as modifiers are added, getTieEndX() is just the last horizontal pixel on the stave.

@Silverwolf90
Copy link
Contributor Author

Cool, simple fix then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
2 participants