Score.singleStaff constructor

Score.singleStaff(
  1. Staff staff, {
  2. String? title,
  3. String? composer,
})

Factory: Create a simple single-staff score

Implementation

factory Score.singleStaff(
  Staff staff, {
  String? title,
  String? composer,
}) {
  return Score(
    title: title,
    composer: composer,
    staffGroups: [
      StaffGroup(
        staves: [staff],
        bracket: BracketType.none,
      ),
    ],
  );
}