diff --git a/CHANGELOG.md b/CHANGELOG.md index 6b095c12dbf..2a415ca506a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,7 @@ # Changelog ## [unreleased] +* Support for `fTrem@unitdur` (@eNote-GmbH) ## [4.1.0] - 2023-12-15 * Support for staves ordered by `scoreDef` diff --git a/src/view_beam.cpp b/src/view_beam.cpp index 1be6bdbe31c..24bd8006935 100644 --- a/src/view_beam.cpp +++ b/src/view_beam.cpp @@ -150,8 +150,8 @@ void View::DrawFTremSegment(DeviceContext *dc, Staff *staff, FTrem *fTrem) secondElement->m_x += (m_doc->GetDrawingStemWidth(staff->m_drawingStaffSize)) / 2; } - // Number of bars to draw - const int allBars = fTrem->GetBeams(); + // Number of beams to draw + const int allBars = fTrem->HasBeams() ? fTrem->GetBeams() : fTrem->GetUnitdur() - DURATION_4; int floatingBars = fTrem->HasBeamsFloat() ? fTrem->GetBeamsFloat() : 0; int fullBars = allBars - floatingBars;