referenceLineOffsetSmufl property
double
get
referenceLineOffsetSmufl
Returns the vertical offset of the clef reference line on the staff according to SMuFL specifications (in staff space units).
Implementation
double get referenceLineOffsetSmufl {
switch (_clefType) {
case ClefType.treble:
case ClefType.treble8va:
case ClefType.treble8vb:
case ClefType.treble15ma:
case ClefType.treble15mb:
return -1.0; // G on the 2nd line (1 staff space below center)
case ClefType.bass:
case ClefType.bass8va:
case ClefType.bass8vb:
case ClefType.bass15ma:
case ClefType.bass15mb:
return 1.0; // F on the 4th line (1 staff space above center)
case ClefType.bassThirdLine:
return 0.0; // F on the 3rd line (middle line)
case ClefType.soprano:
return -2.0; // C on the 1st line
case ClefType.mezzoSoprano:
return -1.0; // C on the 2nd line
case ClefType.alto:
return 0.0; // C on the 3rd line (middle line)
case ClefType.tenor:
return 1.0; // C on the 4th line
case ClefType.baritone:
return 2.0; // C on the 5th line
case ClefType.c8vb:
return 0.0; // C on the 3rd line (one octave below)
case ClefType.percussion:
case ClefType.percussion2:
case ClefType.tab6:
case ClefType.tab4:
return 0.0; // Centered
}
}