@coderline/alphatab 1.9.0-alpha.1767 → 1.9.0-alpha.1785

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -105,15 +105,12 @@ declare class AlphaSynth extends AlphaSynthBase {
105
105
  * @public
106
106
  */
107
107
  declare class AlphaSynthBase implements IAlphaSynth {
108
-
109
-
110
108
  protected isSoundFontLoaded: boolean;
111
109
  private _isMidiLoaded;
112
110
  private _tickPosition;
113
111
  private _timePosition;
114
112
  private _metronomeVolume;
115
113
  private _countInVolume;
116
-
117
114
  protected midiEventsPlayedFilterSet: Set<MidiEventType>;
118
115
  private _notPlayedSamples;
119
116
  private _synthStopping;
@@ -149,7 +146,6 @@ declare class AlphaSynthBase implements IAlphaSynth {
149
146
  get isLooping(): boolean;
150
147
  set isLooping(value: boolean);
151
148
  destroy(): void;
152
-
153
149
  protected onSampleRequest(): void;
154
150
  play(): boolean;
155
151
  private _playInternal;
@@ -203,8 +199,6 @@ declare class AlphaSynthBase implements IAlphaSynth {
203
199
  * @lateinit
204
200
  */
205
201
  readonly playbackRangeChanged: IEventEmitterOfT<PlaybackRangeChangedEventArgs>;
206
-
207
-
208
202
  loadBackingTrack(_score: Score): void;
209
203
  updateSyncPoints(_syncPoints: BackingTrackSyncPoint[]): void;
210
204
  }
@@ -697,7 +691,6 @@ export declare class AlphaTabApiBase<TSettings> {
697
691
  */
698
692
  renderTracks(tracks: Track[], renderHints?: RenderHints): void;
699
693
  private _internalRenderTracks;
700
-
701
694
  private _appendRenderResult;
702
695
  private _updateRenderResult;
703
696
  /**
@@ -2508,7 +2501,6 @@ export declare class AlphaTabApiBase<TSettings> {
2508
2501
  *
2509
2502
  */
2510
2503
  readonly error: IEventEmitterOfT<Error>;
2511
-
2512
2504
  /**
2513
2505
  * This event is fired when all required data for playback is loaded and ready.
2514
2506
  * @remarks
@@ -3287,7 +3279,6 @@ declare interface AlphaTexArgumentList extends AlphaTexAstNode {
3287
3279
  * The close parenthesis token grouping the arguments.
3288
3280
  */
3289
3281
  closeParenthesis?: AlphaTexParenthesisCloseTokenNode;
3290
-
3291
3282
  /**
3292
3283
  * A list of indices to signatures which were selected as candidates matching
3293
3284
  * this argument list.
@@ -3763,7 +3754,6 @@ declare class AlphaTexImporter extends ScoreImporter implements IAlphaTexImporte
3763
3754
  private _beatDuration;
3764
3755
  private _parseDuration;
3765
3756
  private _note;
3766
-
3767
3757
  applyStaffNoteKind(staff: Staff, staffNoteKind: AlphaTexStaffNoteKind): void;
3768
3758
  private _noteEffects;
3769
3759
  private _handleTransposition;
@@ -3838,7 +3828,6 @@ declare interface AlphaTexMetaDataNode extends AlphaTexAstNode {
3838
3828
  * The optional properties defined for the metadata.
3839
3829
  */
3840
3830
  properties?: AlphaTexPropertiesNode;
3841
-
3842
3831
  }
3843
3832
 
3844
3833
  /**
@@ -4003,7 +3992,6 @@ declare class AlphaTexParser {
4003
3992
  get lexerDiagnostics(): AlphaTexDiagnosticBag;
4004
3993
  readonly parserDiagnostics: AlphaTexDiagnosticBag;
4005
3994
  addParserDiagnostic(diagnostics: AlphaTexDiagnostic): void;
4006
-
4007
3995
  constructor(source: string);
4008
3996
  read(): AlphaTexScoreNode;
4009
3997
  private _score;
@@ -4408,7 +4396,6 @@ declare class BackingTrackSyncPoint {
4408
4396
  */
4409
4397
  declare class Bar {
4410
4398
  private static _globalBarId;
4411
-
4412
4399
  /**
4413
4400
  * Gets or sets the unique id of this bar.
4414
4401
  */
@@ -4520,7 +4507,6 @@ declare class Bar {
4520
4507
  * If specified, overrides the value from the stylesheet on score level.
4521
4508
  */
4522
4509
  barNumberDisplay?: BarNumberDisplay;
4523
-
4524
4510
  /**
4525
4511
  * The bar line to draw on the left side of the bar with an "automatic" type resolved to the actual one.
4526
4512
  * @param isFirstOfSystem Whether the bar is the first one in the system.
@@ -4787,12 +4773,6 @@ declare class BeamingRules {
4787
4773
  * The map value defines the "groups" placed within the sliced.
4788
4774
  */
4789
4775
  groups: Map<Duration, number[]>;
4790
-
4791
-
4792
-
4793
-
4794
-
4795
-
4796
4776
  }
4797
4777
 
4798
4778
  /**
@@ -4805,7 +4785,6 @@ declare class BeamingRules {
4805
4785
  */
4806
4786
  declare class Beat {
4807
4787
  private static _globalBeatId;
4808
-
4809
4788
  /**
4810
4789
  * Gets or sets the unique id of this beat.
4811
4790
  * @clone_ignore
@@ -6748,9 +6727,16 @@ export declare class DisplaySettings {
6748
6727
  *
6749
6728
  * The page layout does not use `displayWidth`. The use of absolute widths would break the proper alignments needed for this kind of display.
6750
6729
  *
6751
- * Also note that the sizing is including any glyphs and notation elements within the bar. e.g. if there are clefs in the bar, they are still "squeezed" into the available size.
6752
- * It is not the case that the actual notes with their lengths are sized accordingly. This fits the sizing system of Guitar Pro and when files are customized there,
6753
- * alphaTab will match this layout quite close.
6730
+ * In both modes, prefix and postfix glyphs (clef, key signature, time signature, barlines) are treated as fixed overhead: they keep their
6731
+ * natural size and the remaining staff width is distributed across bars by a per-bar weight. This matches the convention used by
6732
+ * Guitar Pro, Dorico, Finale, Sibelius and MuseScore. Bars that carry a system-start prefix or a mid-line clef/key/time-signature change
6733
+ * are therefore visibly wider than plain bars with the same weight. The weight source depends on the mode:
6734
+ *
6735
+ * * `Automatic` (default for `page` layout): weights come from the built-in spacing engine (the natural content width of each bar).
6736
+ * `displayScale` on the model is ignored.
6737
+ * * `UseModelLayout` (and the `parchment` layout): weights come from `bar.displayScale` / `masterBar.displayScale`. An unset
6738
+ * `displayScale` defaults to `1` and behaves identically to an explicit `1`, matching Guitar Pro (which omits the value when the
6739
+ * author hasn't customized it).
6754
6740
  *
6755
6741
  * ### Horizontal Layout
6756
6742
  *
@@ -7107,9 +7093,16 @@ declare interface DisplaySettingsJson {
7107
7093
  *
7108
7094
  * The page layout does not use `displayWidth`. The use of absolute widths would break the proper alignments needed for this kind of display.
7109
7095
  *
7110
- * Also note that the sizing is including any glyphs and notation elements within the bar. e.g. if there are clefs in the bar, they are still "squeezed" into the available size.
7111
- * It is not the case that the actual notes with their lengths are sized accordingly. This fits the sizing system of Guitar Pro and when files are customized there,
7112
- * alphaTab will match this layout quite close.
7096
+ * In both modes, prefix and postfix glyphs (clef, key signature, time signature, barlines) are treated as fixed overhead: they keep their
7097
+ * natural size and the remaining staff width is distributed across bars by a per-bar weight. This matches the convention used by
7098
+ * Guitar Pro, Dorico, Finale, Sibelius and MuseScore. Bars that carry a system-start prefix or a mid-line clef/key/time-signature change
7099
+ * are therefore visibly wider than plain bars with the same weight. The weight source depends on the mode:
7100
+ *
7101
+ * * `Automatic` (default for `page` layout): weights come from the built-in spacing engine (the natural content width of each bar).
7102
+ * `displayScale` on the model is ignored.
7103
+ * * `UseModelLayout` (and the `parchment` layout): weights come from `bar.displayScale` / `masterBar.displayScale`. An unset
7104
+ * `displayScale` defaults to `1` and behaves identically to an explicit `1`, matching Guitar Pro (which omits the value when the
7105
+ * author hasn't customized it).
7113
7106
  *
7114
7107
  * ### Horizontal Layout
7115
7108
  *
@@ -7313,7 +7306,6 @@ declare class EndOfTrackEvent extends MidiEvent {
7313
7306
  */
7314
7307
  export declare class EngravingSettings {
7315
7308
  private static _bravuraDefaults?;
7316
-
7317
7309
  /**
7318
7310
  * A {@link EngravingSettings} copy filled with the settings of the Bravura font used by default in alphaTab.
7319
7311
  */
@@ -7493,14 +7485,12 @@ export declare class EngravingSettings {
7493
7485
  * @smufl 1.4
7494
7486
  */
7495
7487
  glyphHeights: Map<MusicFontSymbol, number>;
7496
-
7497
7488
  /**
7498
7489
  * Fills the engraving settings from the provided smufl metdata.
7499
7490
  * @param smufl The metadata shipped together with the SMuFL fonts.
7500
7491
  * @param musicFontSize The font size to configure in alphaTab for the music font.
7501
7492
  */
7502
7493
  fillFromSmufl(smufl: SmuflMetadata, musicFontSize?: number): void;
7503
-
7504
7494
  private static _smuflNameToMusicFontSymbol;
7505
7495
  /**
7506
7496
  * The size of the bars drawn in numbered notation to indicate the durations.
@@ -8162,13 +8152,10 @@ declare interface EngravingStemInfoJson {
8162
8152
  * @public
8163
8153
  */
8164
8154
  export declare class Environment {
8165
-
8166
8155
  /**
8167
8156
  * @target web
8168
8157
  */
8169
8158
  private static _globalThis;
8170
-
8171
-
8172
8159
  /**
8173
8160
  * @target web
8174
8161
  */
@@ -8201,7 +8188,6 @@ export declare class Environment {
8201
8188
  * @target web
8202
8189
  */
8203
8190
  private static _detectScriptFile;
8204
-
8205
8191
  private static _appendScriptName;
8206
8192
  /**
8207
8193
  * @target web
@@ -8212,10 +8198,7 @@ export declare class Environment {
8212
8198
  */
8213
8199
  private static _registerJQueryPlugin;
8214
8200
  static readonly renderEngines: Map<string, RenderEngineFactory>;
8215
-
8216
-
8217
8201
  static getRenderEngineFactory(engine: string): RenderEngineFactory;
8218
-
8219
8202
  /**
8220
8203
  * Gets all default ScoreImporters
8221
8204
  * @returns
@@ -8239,15 +8222,12 @@ export declare class Environment {
8239
8222
  * @partial
8240
8223
  */
8241
8224
  private static _createPlatformSpecificRenderEngines;
8242
-
8243
8225
  private static _createDefaultStaveProfiles;
8244
8226
  private static _createDefaultLayoutEngines;
8245
8227
  /**
8246
8228
  * @target web
8247
8229
  */
8248
8230
  static initializeMain(createWebWorker: (settings: Settings, nameHint: string) => Worker, createAudioWorklet: (context: AudioContext, settings: Settings) => Promise<void>): void;
8249
-
8250
-
8251
8231
  /**
8252
8232
  * @target web
8253
8233
  */
@@ -8278,9 +8258,6 @@ export declare class Environment {
8278
8258
  * @partial
8279
8259
  */
8280
8260
  private static _printPlatformInfo;
8281
-
8282
-
8283
-
8284
8261
  }
8285
8262
 
8286
8263
  export declare namespace exporter {
@@ -9791,7 +9768,6 @@ declare class InstrumentArticulation {
9791
9768
  */
9792
9769
  outputMidiNumber: number;
9793
9770
  constructor(elementType?: string, staffLine?: number, outputMidiNumber?: number, noteHeadDefault?: MusicFontSymbol, noteHeadHalf?: MusicFontSymbol, noteHeadWhole?: MusicFontSymbol, techniqueSymbol?: MusicFontSymbol, techniqueSymbolPlacement?: TechniqueSymbolPlacement, id?: number);
9794
-
9795
9771
  getSymbol(duration: Duration): MusicFontSymbol;
9796
9772
  }
9797
9773
 
@@ -10787,7 +10763,6 @@ declare class MasterBar {
10787
10763
  * Defines the custom beaming rules which should be applied to this bar and all bars following.
10788
10764
  */
10789
10765
  beamingRules?: BeamingRules;
10790
-
10791
10766
  /**
10792
10767
  * Gets or sets whether the bar indicates a free time playing.
10793
10768
  */
@@ -11353,7 +11328,6 @@ declare class MidiFileGenerator {
11353
11328
  * @returns The generated sync points for usage in the backing track playback.
11354
11329
  */
11355
11330
  static generateSyncPoints(score: Score, createNew?: boolean): BackingTrackSyncPoint[];
11356
-
11357
11331
  private static _playThroughSong;
11358
11332
  private static _processBarTime;
11359
11333
  private static _processBarTimeWithNewSyncPoints;
@@ -11472,7 +11446,6 @@ declare class MidiFileGenerator {
11472
11446
  */
11473
11447
  declare class MidiTickLookup {
11474
11448
  private _currentMasterBar;
11475
-
11476
11449
  /**
11477
11450
  * A list of all {@link MasterBarTickLookup} sorted by time.
11478
11451
  */
@@ -12726,8 +12699,6 @@ declare interface NotationSettingsJson {
12726
12699
  * @public
12727
12700
  */
12728
12701
  declare class Note {
12729
-
12730
-
12731
12702
  /**
12732
12703
  * Gets or sets the unique id of this note.
12733
12704
  * @clone_ignore
@@ -13128,8 +13099,6 @@ declare class Note {
13128
13099
  private static _noteIdLookupKey;
13129
13100
  private _noteIdBag;
13130
13101
  chain(sharedDataBag?: Map<string, unknown> | null): void;
13131
-
13132
-
13133
13102
  }
13134
13103
 
13135
13104
  /**
@@ -14346,6 +14315,13 @@ declare interface RenderHints {
14346
14315
  * internally it might still be decided to clear the viewport.
14347
14316
  */
14348
14317
  reuseViewport?: boolean;
14318
+ /**
14319
+ * Indicates the index of the first masterbar which was modified in the data model.
14320
+ * @remarks
14321
+ * AlphaTab will try to optimize the rendering and other updates to keep unchanged parts.
14322
+ * At this point only the rendering is affected and the generated MIDI has to be updated separately.
14323
+ */
14324
+ firstChangedMasterBar?: number;
14349
14325
  }
14350
14326
 
14351
14327
  export declare namespace rendering {
@@ -14379,7 +14355,6 @@ export declare class RenderingResources {
14379
14355
  * The default fonts for notation elements if not specified by the user.
14380
14356
  */
14381
14357
  static defaultFonts: Map<NotationElement, Font>;
14382
-
14383
14358
  /**
14384
14359
  * The SMuFL Metrics to use for rendering music symbols.
14385
14360
  * @defaultValue `alphaTab`
@@ -14576,7 +14551,6 @@ export declare class RenderingResources {
14576
14551
  */
14577
14552
  scoreInfoColor: Color;
14578
14553
  constructor();
14579
-
14580
14554
  }
14581
14555
 
14582
14556
  /**
@@ -14587,7 +14561,6 @@ export declare class RenderingResources {
14587
14561
  * @target web
14588
14562
  */
14589
14563
  declare interface RenderingResourcesJson {
14590
-
14591
14564
  /**
14592
14565
  * The SMuFL Metrics to use for rendering music symbols.
14593
14566
  * @defaultValue `alphaTab`
@@ -15045,7 +15018,6 @@ declare class ScoreRenderer implements IScoreRenderer {
15045
15018
  canvas: ICanvas | null;
15046
15019
  score: Score | null;
15047
15020
  tracks: Track[] | null;
15048
-
15049
15021
  settings: Settings;
15050
15022
  boundsLookup: BoundsLookup | null;
15051
15023
  width: number;
@@ -15234,7 +15206,6 @@ export declare class Settings {
15234
15206
  * @target web
15235
15207
  */
15236
15208
  fillFromJson(json: SettingsJson): void;
15237
-
15238
15209
  }
15239
15210
 
15240
15211
  /**
@@ -15633,7 +15604,14 @@ declare class StaffSystemBounds {
15633
15604
  */
15634
15605
  boundsLookup: BoundsLookup;
15635
15606
  /**
15636
- * Finished the lookup for optimized access.
15607
+ * Whether this system's bounds have already been scaled via `finish`. Prevents double-scaling
15608
+ * when the parent `BoundsLookup` is preserved across partial renders and `finish` is invoked
15609
+ * again on a mix of already-scaled (preserved) and newly-registered (natural-coordinate) systems.
15610
+ */
15611
+ isFinished: boolean;
15612
+ /**
15613
+ * Finished the lookup for optimized access. Idempotent: once finished, further calls are no-ops
15614
+ * so preserved systems survive partial renders without being re-scaled.
15637
15615
  */
15638
15616
  finish(scale?: number): void;
15639
15617
  /**
@@ -16156,7 +16134,6 @@ declare class TremoloPickingEffect {
16156
16134
  * The style of the tremolo picking.
16157
16135
  */
16158
16136
  style: TremoloPickingStyle;
16159
-
16160
16137
  /**
16161
16138
  * Gets the duration of a single tremolo note played in a beat of the given duration
16162
16139
  * based on the configured marks.
@@ -16450,7 +16427,6 @@ declare class Voice {
16450
16427
  private _isEmpty;
16451
16428
  private _isRestOnly;
16452
16429
  private static _globalVoiceId;
16453
-
16454
16430
  /**
16455
16431
  * Gets or sets the unique id of this bar.
16456
16432
  */
@@ -16478,12 +16454,10 @@ declare class Voice {
16478
16454
  * The style customizations for this item.
16479
16455
  */
16480
16456
  style?: VoiceStyle;
16481
-
16482
16457
  /**
16483
16458
  * Gets or sets a value indicating whether this voice is empty.
16484
16459
  */
16485
16460
  get isRestOnly(): boolean;
16486
-
16487
16461
  insertBeat(after: Beat, newBeat: Beat): void;
16488
16462
  addBeat(beat: Beat): void;
16489
16463
  private _chain;