Quellcode durchsuchen

fix(RenderSingleHorizontalStaffline): Fixed for osmd-extended (#41)

fix #41
sschmidTU vor 3 Jahren
Ursprung
Commit
238c8701be
1 geänderte Dateien mit 7 neuen und 1 gelöschten Zeilen
  1. 7 1
      src/MusicalScore/Graphical/MusicSheetCalculator.ts

+ 7 - 1
src/MusicalScore/Graphical/MusicSheetCalculator.ts

@@ -826,7 +826,13 @@ export abstract class MusicSheetCalculator {
 
 
         // build the MusicSystems
-        const musicSystemBuilder: MusicSystemBuilder = new JustifiedMusicSystemBuilder();
+        let musicSystemBuilder: MusicSystemBuilder;
+        if (this.rules.RenderSingleHorizontalStaffline) {
+            musicSystemBuilder = new MusicSystemBuilder();
+        } else {
+            musicSystemBuilder = new JustifiedMusicSystemBuilder();
+        }
+
         musicSystemBuilder.initialize(this.graphicalMusicSheet, visibleMeasureList, numberOfStaffLines);
         this.musicSystems = musicSystemBuilder.buildMusicSystems();