File tree Expand file tree Collapse file tree 1 file changed +2
-9
lines changed Expand file tree Collapse file tree 1 file changed +2
-9
lines changed Original file line number Diff line number Diff line change @@ -62,14 +62,13 @@ export class TimeSignature extends StaveModifier {
62
62
63
63
protected timeSpec : string = '4/4' ;
64
64
protected line : number = 0 ;
65
- protected glyph : Glyph ;
65
+ protected glyph ! : Glyph ;
66
66
protected is_numeric : boolean = true ;
67
67
protected validate_args : boolean ;
68
68
69
69
constructor ( timeSpec : string = '4/4' , customPadding = 15 , validate_args = true ) {
70
70
super ( ) ;
71
71
this . validate_args = validate_args ;
72
- this . timeSpec = timeSpec ;
73
72
74
73
const padding = customPadding ;
75
74
@@ -81,13 +80,7 @@ export class TimeSignature extends StaveModifier {
81
80
this . topLine = 2 + fontLineShift ;
82
81
this . bottomLine = 4 + fontLineShift ;
83
82
this . setPosition ( StaveModifierPosition . BEGIN ) ;
84
-
85
- // violates DRY w/ setTimeSig(timeSpec) but needed to convince TypeScript that all is well.
86
- const info = this . parseTimeSpec ( timeSpec ) ;
87
- this . glyph = info . glyph ;
88
- this . is_numeric = info . num ;
89
- this . line = info . line ;
90
-
83
+ this . setTimeSig ( timeSpec ) ;
91
84
this . setWidth ( defined ( this . glyph . getMetrics ( ) . width ) ) ;
92
85
this . setPadding ( padding ) ;
93
86
}
You can’t perform that action at this time.
0 commit comments