Skip to content

Commit

Permalink
fix bug with volta selection
Browse files Browse the repository at this point in the history
  • Loading branch information
AaronDavidNewman committed Dec 30, 2023
1 parent 77bc22e commit 09a58ef
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 2 deletions.
1 change: 1 addition & 0 deletions release/library/bigband/Poinciana.json

Large diffs are not rendered by default.

8 changes: 7 additions & 1 deletion src/common/serializationHelpers.js
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,13 @@ export class smoSerialize {
"jh": "program",
"kh": "volume",
"lh": "pan",
"mh": "midiDevice"
"mh": "midiDevice",
"nh": "audioSettings",
"oh": "skipMeasureCount",
"ph": "forceRest",
"qh": "instrument",
"rh": "shortText",
"sh": "hideEmptyLines"
}`;
return JSON.parse(_tm);
}
Expand Down
5 changes: 4 additions & 1 deletion src/render/vex/vxSystem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -425,7 +425,10 @@ export class VxSystem {
const vxVolta = new VF.Volta(vtype, ending.number.toString(), smoMeasure.staffX + ending.xOffsetStart, ending.yOffset);
vxVolta.setContext(this.context.getContext()).draw(vxMeasure.stave, -1 * ending.xOffsetEnd);
this.context.getContext().closeGroup();
// ending.logicalBox = this.context.offsetBbox(group);
const height = parseInt(vxVolta.getFontSize(), 10) * 2;
const width = smoMeasure.staffWidth;
const y = smoMeasure.svg.logicalBox.y - (height + ending.yOffset);
ending.logicalBox = { x: smoMeasure.svg.staffX, y, width, height };
if (!pushed) {
voAr.push({ smoMeasure, ending });
pushed = true;
Expand Down

0 comments on commit 09a58ef

Please sign in to comment.