Skip to content

Commit

Permalink
[palette] added layout for NoteHead
Browse files Browse the repository at this point in the history
  • Loading branch information
igorkorsukov committed Jul 10, 2023
1 parent 4ccdf04 commit 377cd4c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/palette/internal/palettelayout.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
#include "engraving/libmscore/letring.h"
#include "engraving/libmscore/line.h"
#include "engraving/libmscore/marker.h"
#include "engraving/libmscore/note.h"
#include "engraving/libmscore/ornament.h"
#include "engraving/libmscore/ottava.h"
#include "engraving/libmscore/palmmute.h"
Expand Down Expand Up @@ -136,6 +137,8 @@ void PaletteLayout::layoutItem(EngravingItem* item)
break;
case ElementType::MARKER: layout(toMarker(item), ctx);
break;
case ElementType::NOTEHEAD: layout(toNoteHead(item), ctx);
break;
case ElementType::OTTAVA: layout(toOttava(item), ctx);
break;
case ElementType::PALM_MUTE: layout(toPalmMute(item), ctx);
Expand Down Expand Up @@ -946,6 +949,11 @@ void PaletteLayout::layout(LetRingSegment* item, const Context& ctx)
layoutTextLineBaseSegment(item, ctx);
}

void PaletteLayout::layout(NoteHead* item, const Context& ctx)
{
layout(static_cast<Symbol*>(item), ctx);
}

void PaletteLayout::layout(Marker* item, const Context& ctx)
{
layoutTextBase(item, ctx);
Expand Down
4 changes: 4 additions & 0 deletions src/palette/internal/palettelayout.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,8 @@ class LineSegment;

class Marker;

class NoteHead;

class Ornament;
class Ottava;
class OttavaSegment;
Expand Down Expand Up @@ -162,6 +164,8 @@ class PaletteLayout

static void layout(engraving::LetRing* item, const Context& ctx);

static void layout(engraving::NoteHead* item, const Context& ctx);

static void layout(engraving::Marker* item, const Context& ctx);

static void layout(engraving::Ornament* item, const Context& ctx);
Expand Down

0 comments on commit 377cd4c

Please sign in to comment.