Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/rendering/stave.ts
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ export class Stave {
const isFirstFragment = this.document.isFirstFragment(this.key);
const isFirstPart = this.document.isFirstPart(this.key);
const isFirstStave = this.document.isFirstStave(this.key);
const isAbsolutelyFirst = isFirstSystem && isFirstMeasure && isFirstFragment && isFirstPart && isFirstStave;
const isAbsolutelyFirst = isFirstSystem && isFirstMeasure && isFirstFragment;

const currentMetronome = this.document.getFragment(this.key).signature.metronome;
const previousMetronome = this.document.getPreviousFragment(this.key)?.signature.metronome;
Expand All @@ -370,7 +370,7 @@ export class Stave {
const hasMetronome =
currentMetronome.displayBpm || currentMetronome.dots || currentMetronome.dots2 || currentMetronome.duration;

if (hasMetronome && (isAbsolutelyFirst || didMetronomeChange)) {
if (hasMetronome && isFirstPart && isFirstStave && (isAbsolutelyFirst || didMetronomeChange)) {
vexflowStave.setTempo({ ...currentMetronome, bpm: currentMetronome.displayBpm }, -METRONOME_TOP_PADDING);
}
}
Expand Down