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

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

Music.Score.Export.MusicXml

Contents

Description

 

Synopsis

MusicXml backend

class HasMusicXmlInstrument a whereSource

Extract instrument info as per Music.Part This is really crude, needs rethinking!

Methods

getMusicXmlClef :: a -> IntSource

data XmlContext a Source

Context passed to the note export. Includes duration and note/rest distinction.

Constructors

XmlContext Duration (Maybe a) 

Instances

Functor XmlContext 
Foldable XmlContext 
Traversable XmlContext 
Eq a => Eq (XmlContext a) 
Show a => Show (XmlContext a) 

type HasMusicXml a = (HasBackendNote MusicXml (BackendScoreEvent MusicXml a), HasBackendScore MusicXml a)Source

Constraint for types that has a MusicXML representation.

Converting to MusicXml

toMusicXml :: HasMusicXml a => a -> ScoreSource

Convert a score to a MusicXML score.

toMusicXmlString :: HasMusicXml a => a -> StringSource

Convert a score to a MusicXML string.

MusicXml I/O

showMusicXml :: HasMusicXml a => a -> IO ()Source

Convert a score to MusicXML string and print it on the standard output.

openMusicXml :: HasMusicXml a => a -> IO ()Source

Typeset a score using MusicXML and open it. (This is simple wrapper around writeMusicXml that may not work well on all platforms.)

writeMusicXml :: HasMusicXml a => FilePath -> a -> IO ()Source

Convert a score to MusicXML and write to a file.