Clef constructor
Implementation
Clef({this.clefType = ClefType.treble, this.staffPosition, String? type}) {
// Backward compatibility - se type for fornecido, converta para ClefType
if (type != null) {
switch (type) {
case 'g':
_clefType = ClefType.treble;
break;
case 'f':
_clefType = ClefType.bass;
break;
case 'c':
_clefType = ClefType.alto;
break;
default:
_clefType = ClefType.treble;
}
} else {
_clefType = clefType;
}
}