Module: Clef::Renderer::NotationHelpers

Included in:
PdfRenderer, SvgRenderer
Defined in:
lib/clef/renderer/notation_helpers.rb

Constant Summary collapse

ACCIDENTAL_GLYPH_KEYS =
{
  -2 => :accidental_double_flat,
  -1 => :accidental_flat,
  0 => :accidental_natural,
  1 => :accidental_sharp,
  2 => :accidental_double_sharp
}.freeze
ACCIDENTAL_FALLBACK =
{
  -2 => "bb",
  -1 => "b",
  0 => "n",
  1 => "#",
  2 => "##"
}.freeze
SHARP_ORDER =
%i[f c g d a e b].freeze
FLAT_ORDER =
%i[b e a d g c f].freeze
REST_LABELS =
{
  whole: "W",
  half: "H",
  quarter: "r",
  eighth: "8",
  sixteenth: "16",
  thirty_second: "32",
  sixty_fourth: "64",
  one_twenty_eighth: "128",
  two_fifty_sixth: "256"
}.freeze