Skip to content

Commit

Permalink
Fix #312625 Accessibility: Speak notehead group type
Browse files Browse the repository at this point in the history
Implement screen reader speech output for when a note has a non-default
notehead shape (group type) such as cross, triangle, diamond, etc.

Backport of musescore#8877, part 2, resp. duplicate of musescore#7870, part 5
  • Loading branch information
shoogle authored and Jojo-Schmitz committed Sep 9, 2021
1 parent e8ab87e commit afc12ca
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion libmscore/note.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3092,7 +3092,9 @@ QString Note::screenReaderInfo() const
else if (staff()->isTabStaff(tick()))
pitchName = QObject::tr("%1; String: %2; Fret: %3").arg(tpcUserName(true), QString::number(string() + 1), QString::number(fret()));
else
pitchName = tpcUserName(true);
pitchName = _headGroup == NoteHead::Group::HEAD_NORMAL
? tpcUserName(true)
: QObject::tr("%1 head %2").arg(subtypeName()).arg(tpcUserName(true));
return QString("%1 %2 %3%4").arg(noteTypeUserName(), pitchName, duration, (chord()->isGrace() ? "" : QString("; %1").arg(voice)));
}

Expand Down

0 comments on commit afc12ca

Please sign in to comment.