示例#1
0
 public override void FinalizeGlyph(ScoreLayout layout)
 {
     if (!Container.Beat.IsRest)
     {
         NoteHeads.UpdateBeamingHelper(Container.X + X);
     }
 }
示例#2
0
 public void FinalizeGlyph(ScoreLayout layout)
 {
     for (int i = 0, j = BeatGlyphs.Count; i < j; i++)
     {
         BeatGlyphs[i].FinalizeGlyph(layout);
     }
 }
示例#3
0
        public void FinalizeStave(ScoreLayout layout)
        {
            var x = 0f;

            Height = 0;

            var topOverflow    = TopOverflow;
            var bottomOverflow = BottomOverflow;
            var isEmpty        = true;

            for (var i = 0; i < BarRenderers.Count; i++)
            {
                BarRenderers[i].X = x;
                BarRenderers[i].Y = TopSpacing + topOverflow;
                Height            = Math.Max(Height, BarRenderers[i].Height);
                BarRenderers[i].FinalizeRenderer(layout);
                x += BarRenderers[i].Width;
                if (!BarRenderers[i].IsEmpty)
                {
                    isEmpty = false;
                }
            }

            if (!isEmpty)
            {
                Height += TopSpacing + topOverflow + bottomOverflow + BottomSpacing;
            }
            else
            {
                Height = 0;
            }
        }
示例#4
0
        public async override Task OnLoadYamlFilesChanged()
        {
            ScoreLayout = _skeletonGameProvider.ScoreDisplayConfig?.ScoreLayout;

            Animations.AddRange(_skeletonGameProvider.AssetsConfig?.Animations.Select(x => x.Key));

            await Task.Delay(100);
        }
示例#5
0
        public override void FinalizeRenderer(ScoreLayout layout)
        {
            base.FinalizeRenderer(layout);
            // after all layouting and sizing place and size the effect glyphs
            IsEmpty = true;

#if MULTIVOICE_SUPPORT
            foreach (var v in Bar.Voices)
            {
                Glyph prevGlyph = null;
                if (Index > 0)
                {
                    // check if previous renderer had an effect on his last beat
                    // and use this as merging element
                    EffectBarRenderer prevRenderer = (EffectBarRenderer)Stave.BarRenderers[Index - 1];
                    if (prevRenderer._lastBeat != null)
                    {
                        prevGlyph = prevRenderer._effectGlyphs[v.Index][prevRenderer._lastBeat.Index];
                    }
                }
                foreach (var beatIndex in _effectGlyphs[v.Index].Keys)
                {
                    Glyph effect = _effectGlyphs[v.Index][beatIndex];

                    AlignGlyph(_info.SizingMode, beatIndex, 0, prevGlyph);

                    prevGlyph = effect;
                    IsEmpty   = false;
                }
            }
#else
            EffectGlyph prevGlyph = null;
            if (Index > 0)
            {
                // check if previous renderer had an effect on his last beat
                // and use this as merging element
                EffectBarRenderer prevRenderer = (EffectBarRenderer)Stave.BarRenderers[Index - 1];
                if (prevRenderer._lastBeat != null && prevRenderer._effectGlyphs[0].ContainsKey(prevRenderer._lastBeat.Index))
                {
                    prevGlyph = prevRenderer._effectGlyphs[0][prevRenderer._lastBeat.Index];
                }
            }

            foreach (var key in _effectGlyphs[0].Keys)
            {
                int         beatIndex = Std.ParseInt(key);
                EffectGlyph effect    = _effectGlyphs[0][beatIndex];

                AlignGlyph(_info.SizingMode, beatIndex, 0, prevGlyph);

                prevGlyph = effect;
                IsEmpty   = false;
            }
#endif
        }
示例#6
0
        public void FinalizeGroup(ScoreLayout scoreLayout)
        {
            float currentY = 0;

            for (int i = 0, j = _allStaves.Count; i < j; i++)
            {
                _allStaves[i].X = AccoladeSpacing;
                _allStaves[i].Y = (currentY);
                _allStaves[i].FinalizeStave(scoreLayout);
                currentY += _allStaves[i].Height;
            }
        }
示例#7
0
        public override void FinalizeRenderer(ScoreLayout layout)
        {
            base.FinalizeRenderer(layout);
            // after all layouting and sizing place and size the effect glyphs
            IsEmpty = true;

            foreach (var voice in Bar.Voices)
            {
                foreach (var key in _effectGlyphs[voice.Index].Keys)
                {
                    AlignGlyph(_info.SizingMode, voice.Beats[key]);
                    IsEmpty = false;
                }
            }
        }
示例#8
0
        public override void FinalizeRenderer(ScoreLayout layout)
        {
            base.FinalizeRenderer(layout);
            // after all layouting and sizing place and size the effect glyphs
            IsEmpty = true;

            for (int v = 0; v < Bar.Voices.Count; v++)
            {
                var voice = Bar.Voices[v];
                foreach (var key in _effectGlyphs[voice.Index].Keys)
                {
                    var beatIndex = Std.ParseInt(key);
                    AlignGlyph(_info.SizingMode, voice.Beats[beatIndex]);
                    IsEmpty = false;
                }
            }
        }
 public override void FinalizeRenderer(ScoreLayout layout)
 {
     Std.Foreach(_voiceContainers.Values, c => c.FinalizeGlyph(layout));
 }
示例#10
0
 public override void FinalizeRenderer(ScoreLayout layout)
 {
     base.FinalizeRenderer(layout);
     IsEmpty = _endings.Count == 0;
 }
示例#11
0
 public virtual void FinalizeRenderer(ScoreLayout layout)
 {
 }
 public virtual void FinalizeGlyph(ScoreLayout layout)
 {
 }
示例#13
0
 public virtual void FinalizeRenderer(ScoreLayout layout)
 {
     IsFinalized = true;
 }
 public void FinalizeGlyph(ScoreLayout layout)
 {
     PreNotes.FinalizeGlyph(layout);
     OnNotes.FinalizeGlyph(layout);
     PostNotes.FinalizeGlyph(layout);
 }