Class: HeadMusic::Style::Guidelines::AlwaysMove

Inherits:
Annotation
  • Object
show all
Defined in:
lib/head_music/style/guidelines/always_move.rb

Overview

A counterpoint guideline

Constant Summary collapse

MESSAGE =
"Always move to a different note."

Instance Method Summary collapse

Constructor Details

This class inherits a constructor from HeadMusic::Style::Annotation

Instance Method Details

#marksObject



8
9
10
11
12
# File 'lib/head_music/style/guidelines/always_move.rb', line 8

def marks
  melodic_note_pairs
    .select { |pair| pair.perfect? && pair.unison? }
    .map { |pair| HeadMusic::Style::Mark.for_all(pair.notes) }
end