From f30bd45206cca5d391b83e78a87d071aecef15dc Mon Sep 17 00:00:00 2001 From: James Mizen Date: Mon, 10 Jun 2024 17:06:40 +0100 Subject: [PATCH] Default custom noteheads to normal on non drumset staves --- src/engraving/dom/note.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/engraving/dom/note.cpp b/src/engraving/dom/note.cpp index 247b839352687..0224269d23fc6 100644 --- a/src/engraving/dom/note.cpp +++ b/src/engraving/dom/note.cpp @@ -943,6 +943,7 @@ SymId Note::noteHead() const const Staff* st = chord() ? chord()->staff() : nullptr; + NoteHeadGroup headGroup = m_headGroup; if (m_headGroup == NoteHeadGroup::HEAD_CUSTOM) { if (st) { if (st->staffTypeForElement(chord())->isDrumStaff()) { @@ -955,6 +956,8 @@ SymId Note::noteHead() const LOGD("no drumset"); return noteHead(up, NoteHeadGroup::HEAD_NORMAL, ht); } + } else { + headGroup = NoteHeadGroup::HEAD_NORMAL; } } else { return ldata()->cachedNoteheadSym.value(); @@ -975,9 +978,9 @@ SymId Note::noteHead() const if (scheme == NoteHeadScheme::HEAD_AUTO) { scheme = NoteHeadScheme::HEAD_NORMAL; } - SymId t = noteHead(up, m_headGroup, ht, tpc(), key, scheme); + SymId t = noteHead(up, headGroup, ht, tpc(), key, scheme); if (t == SymId::noSym) { - LOGD("invalid notehead %d/%d", int(m_headGroup), int(ht)); + LOGD("invalid notehead %d/%d", int(headGroup), int(ht)); t = noteHead(up, NoteHeadGroup::HEAD_NORMAL, ht); } return t;