Exemple #1
0
        public static string ToString(InternalNote note, InternalNoteStringStyle style)
        {
            if (NoteUtils.IsNatural(note) || style != InternalNoteStringStyle.ShowBoth)
            {
                return(NoteUtils.ToString(NoteUtils.ToNote(note, style)));
            }
            else
            {
                switch (note)
                {
                case InternalNote.Cs_Db:
                    return("C#/Db");

                case InternalNote.Ds_Eb:
                    return("D#/Eb");

                case InternalNote.Fs_Gb:
                    return("F#/Gb");

                case InternalNote.Gs_Ab:
                    return("G#/Ab");

                case InternalNote.As_Bb:
                    return("A#/Bb");
                }
            }

            throw new ArgumentException();
        }