music-score-1.7.1: Musical score and part representation.

Portabilitynon-portable (TF,GNTD)
Stabilityexperimental
Maintainerhans@hanshoglund.se
Safe HaskellNone

Music.Score.Meta.Key

Contents

Description

Provides key signature meta-data.

Synopsis

Key signature type

data Fifths Source

Instances

Enum Fifths 
Eq Fifths 
Integral Fifths 
Num Fifths 
Ord Fifths 
Real Fifths 
IsPitch Fifths 

data KeySignature Source

A key signature, represented by number of fifths from C and mode.

key :: Fifths -> Bool -> KeySignatureSource

Create a major or minor signature.

Adding key signatures to scores

keySignature :: (HasMeta a, HasPosition a) => KeySignature -> a -> aSource

Set the key signature of the given score.

keySignatureDuring :: HasMeta a => Span -> KeySignature -> a -> aSource

Set the key signature of the given part of a score.

Extracting key signatures

withKeySignature :: KeySignature -> (KeySignature -> Score a -> Score a) -> Score a -> Score aSource

Extract all key signatures from the given score, using the given default key signature.