Skip to content

Commit

Permalink
shift shorter note
Browse files Browse the repository at this point in the history
  • Loading branch information
rvilarl committed Mar 26, 2023
1 parent 0bb3a6e commit a376503
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/stavenote.ts
Original file line number Diff line number Diff line change
Expand Up @@ -279,8 +279,8 @@ export class StaveNote extends StemmableNote {
} //Very close whole notes
} else if (lineDiff < 1) {
xShift = voiceXShift + 2;
if (noteU.stemDirection === noteL.stemDirection) {
// upper voice is middle voice, so shift it right
if (noteU.note.duration < noteL.note.duration) {
// upper voice is shorter, so shift it right
noteU.note.setXShift(xShift);
} else {
// shift lower voice right
Expand Down

0 comments on commit a376503

Please sign in to comment.