-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Fix #9352: Add ability to guess tie attachment point for different noteheads #9653
Fix #9352: Add ability to guess tie attachment point for different noteheads #9653
Conversation
df23038
to
e6ba044
Compare
Added some extra space for the ties to adjust to each other |
Yup, I noticed those as well. Thanks for looking through and getting the screenshots, I'll definitely be taking another whack at this once I finish something I'm working on tomorrow. |
e6ba044
to
f20db59
Compare
So, the extra height on some of the ties were due to the fact that the vtests still use Emmentaler rather than Leland, for the record. The vtests will almost certainly still fail because the ties will look different, but now the ties from gracenotes will be a lot nicer with a little special handling. The wholenotes one was a weird oversight that should be fixed now. Let's see what the vtests say on this one. edit: a few fixes still needed, should be easy |
Yep, very well aware. The problem is that headWidth (and, bafflingly, the bounding box as well) always returns the width of a regular-sized notehead instead of the grace-sized one, so I just need to figure out how to get the grace-sized head width and we're golden. |
See (in 3.x) Format > Style > Sizes > Grace note size. Defaults to 70%, so you'ds need to pick on that style setting |
f20db59
to
913a570
Compare
The answer was |
Still the issue with these too narrow ties (same as in the above images), they are not going from/to center of notehead |
Those are inside-style ties because they are going to or from a multinote chord. This is an issue in other inside-style tie situations as well, and in the future there will be a minimum tie width issue where that will be looked at in greater detail. |
Still messing around with different fonts and noteheads, there are so many combinations to go through..! |
913a570
to
94505fd
Compare
Rewrote the Y adjust code to be simpler and also more robust in the face of different fonts. Still needs a rebase. |
94505fd
to
dbd681f
Compare
Rebase finished. I was also requested to add a small left- or right-offset to outside tie endpoints, which I ended up making 1/8 sp. edit: i think i know what is killing the utests, give me a sec. |
4 utests crash with a failed assertion: Edit: I see, you're on it |
dbd681f
to
8571237
Compare
Tests should be fixed now |
Nope, exact same crash |
3211f22
to
ccd8db4
Compare
The weird thing is that these tests pass when I run them locally. I think I identified the problem, we'll see if the tests are good this time. edit: There we go. The problem was that |
Does this work as expected on chords where every note has a different notehead? |
4dbf36c
to
6b85e44
Compare
Also, cleaned up some comments and renamed some functions to make them easier to understand
6b85e44
to
18064e7
Compare
Fixed a little issue with forced-direction outside ties colliding with hooks, and also added another special case for slashed noteheads, which are different from slash noteheads for the record. |
Resolves: #9352
Noteheads are now taken into account when determining where to attach ties. For noteheads with cutout information, this is the average of the cutouts. Also, now that noteheads have a single attachment point, ties adjust for each other when they share that point:
For slash noteheads, which are special, the tie attachment point takes the stem anchor into account:
For all other noteheads, the exact center is used.