ScoreScript Language wiki

Meter, key, tempo, and clef

Opening settings and later changes

Set meter, key, and tempo in the score header. A setting stays in force until another replaces it. For several changes, a compact map puts the timeline together. The first unaddressed entry is the opening value; later entries begin with their measure number.

ScoreScript sourceDownload source
scorescript 0.3
score "Changing meter" {
  meter {4/4, m2 3/4, m3 4/4}
  key {C, m3 G}
  tempo {Andante 80, m3 Allegro 120}

  parts {
    flute
  }

  flute {
    m1-3 {
      4C5 D E F | G A B | 1C
    }
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Changing meter" {
  meter {4/4, m2 3/4, m3 4/4}
  key {C, m3 G}
  tempo {Andante 80, m3 Allegro 120}

  parts {
    flute
  }

  flute {
    m1-3 {
      4C5 D E F | G A B | 1C
    }
  }
}

An addressed block such as at m2 { meter 3/4 } states the same kind of change. Inside a part, [meter 3/4], [key G], and [tempo 120] place changes at a musical point. An inline key or meter change warns when it also governs other parts. To keep a key local, put at m2 { key G } inside that part; key G in its head sets its opening key. Meter remains score-wide. Score-wide changes should be stated once in the score timeline.

Key, meter and pitch-reading changes currently require a bar boundary: before the first event they govern that bar; after the last event they govern the next. An interior position is refused rather than changing earlier notes. Tempo and clef changes can take effect between events.

A tempo written between two notes takes effect at the second one — the bracket stands where the change happens, the mark prints over that note, and playback changes speed there rather than at the next bar line. 4C5 D [tempo e=144] E F is two notes at the old speed and two at the new one.

ScoreScript sourceDownload source
[tempo q=96] 4C5 D [tempo e=144] E F
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
[tempo q=96] 4C5 D [tempo e=144] E F

Written before a bar's first note it is that bar's opening tempo, printed at its head as always; written after the last note it is the next bar's.

meter none allows unmetered music. Compound meters such as 6/8 have their own standard beam grouping. A key signature and the pitch-reading mode are different settings; see key-aware spelling.

Tempo words and beat units

A tempo entry can contain a word, a metronome value, or both. Use quotes for several words. An explicit metronome beat retains its printed unit: tempo 4.=88 gives dotted-quarter equals 88. tempo 8=164 gives eighth equals 164. Two note values instead of a metronome number express metric modulation, such as tempo 4=8 or tempo 4=e.~s.

ScoreScript sourceDownload source
scorescript 0.3
score "Compound pulse" {
  meter 6/8
  tempo 4.=88

  parts {
    flute
  }

  flute {
    m1 {
      8C5 D E F G A
    }
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Compound pulse" {
  meter 6/8
  tempo 4.=88

  parts {
    flute
  }

  flute {
    m1 {
      8C5 D E F G A
    }
  }
}

One directive carries a tempo's words and its rate, at the head (tempo …) or at a point in a bar ([tempo …]), and the value reads the same at both doors. The words come first — one word bare, several words quoted — then the rate:

WrittenPrintsPlays
tempo AndanteAndantethe tempo already in force
tempo "Andante con moto"Andante con motothe tempo already in force
tempo q=120♩ = 120120
tempo Andante q=120Andante ♩ = 120120
tempo Andante (q=120)Andante (♩ = 120)120
tempo Andante (ca. q=120)Andante (ca. ♩ = 120)120
tempo Andante ca. q=120Andante ca. ♩ = 120120
tempo (ca. q=120)(ca. ♩ = 120)120
tempo q=112-120♩ = 112–120112, the range's first number

The parentheses and ca. are print only: they never change what plays. A rate written before its words ([tempo q=120 Andante]) is read, and the formatter writes the words first. The equals sign identifies a real tempo change; the renderer draws a note symbol and playback uses its beat length. A dotted quarter at 120 is 180 quarter notes per minute. q=120 also works by itself before music, and tempo {Andante q.=120} uses the same value in a top-level map. Spaces around = are optional.

ScoreScript sourceDownload source
tempo Andante (ca. q=120)

4C5 D E F | G A [tempo "poco più mosso"] B C
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
tempo Andante (ca. q=120)

4C5 D E F | G A [tempo "poco più mosso"] B C

Written between two notes, [tempo …] stands at the note after it: the words print there and a number takes effect there, mid-bar included.

The older prefix *Andante / *"Molto Andante" (and *Andante q=120) is still read, as the [tempo …] standing before its note. scorescript migrate and the formatter write it as that directive and never write the star; the words keep their note and the number its onset.

A range states the available speeds, not a gradual change: q=112-120 prints both endpoints and starts playback at 112. A practice player can use the upper endpoint as a target; it does not automatically accelerate to it.

A modulation relates the old note value to the new one. At quarter = 112, 8=4 makes the old eighth the new quarter, so the new quarter rate is 224. It acts at its written position and does not change the meter or note durations. For example, the second bar below starts at that new rate:

ScoreScript sourceDownload source
scorescript 0.3
score "Range and modulation" {
  tempo {Andante q=112-120, m2 Allegro 8=4}
  parts { flute }
  flute { m1-2 { 4C5 D E F | G A B C } }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Range and modulation" {
  tempo {Andante q=112-120, m2 Allegro 8=4}

  parts {
    flute
  }

  flute {
    m1-2 {
      4C5 D E F | G A B C
    }
  }
}

In a tempo map, prefix a direction with the comma down-mark to request player-facing text below the staff, as in tempo {80, m2 ,"molto rit."}. Above-system directions remain visible to resting players; below directions are omitted in a resting part.

Polymeter

Parts can keep different meters at the same time. Define the polymeter once, in the main meter map, at the bars it covers. Part bodies write only their music. Name each part as its body does (horn, clarinet-bb 1, piano t). Name exactly one part primary and give it the tempo. Every other part states how it lines up with the primary, because there is no default:

  • bars 1 to 2: one bar of this part lasts as long as two primary bars.
  • beats 4.=4: this part's dotted quarter equals the primary's quarter. The follower's note value comes first, then the primary's, as in a metric modulation. Bare beats is refused: name both note values.
ScoreScript sourceDownload source
scorescript 0.3
score "Hemiola" {
  meter {m1-2 poly {horn primary 3/4 tempo q=120, clarinet 6/8 beats 4=4}, m3 4/4}

  parts {
    horn
    clarinet
  }

  horn {
    m1-3 {
      4C4 D E | F E D | 1C
    }
  }

  clarinet {
    m1-3 {
      8G4 A B C D E | D C B A G F | 1E
    }
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Hemiola" {
  meter {m1-2 poly {horn primary 3/4 tempo q=120, clarinet 6/8 beats 4=4}, m3 4/4}

  parts {
    horn
    clarinet
  }

  horn {
    m1-3 {
      4C4 D E | F E D | 1C
    }
  }

  clarinet {
    m1-3 {
      8G4 A B C D E | D C B A G F | 1E
    }
  }
}

The bar ranges are the primary's bars. Here each clarinet bar of 6/8 lasts exactly as long as a horn bar of 3/4. Both parts change to 4/4 together at m3. When a section ends, every part resumes together on the barline after it. A follower whose bars do not come out even has its last bar cut short on that barline, so its notes must end by then. A part that poly {…} does not name follows the primary bar for bar. Tempo changes belong to the primary: write them in its bars, not in a follower's.

A follower may have a different number of bars from the primary. Its bars inside the section are numbered from the section's first bar:

ScoreScript sourceDownload source
scorescript 0.3
score "Dotted quarter on the beat" {
  meter {m1-2 poly {horn primary 3/4 tempo q=120, clarinet 6/8 beats 4.=4}}

  parts {
    horn
    clarinet
  }

  horn {
    m1-2 {
      4C4 D E | F E D
    }
  }

  clarinet {
    m1-3 {
      8G4 A B C D E | D C B A G F | E F G A B C
    }
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Dotted quarter on the beat" {
  meter {m1-2 poly {horn primary 3/4 tempo q=120, clarinet 6/8 beats 4.=4}}

  parts {
    horn
    clarinet
  }

  horn {
    m1-2 {
      4C4 D E | F E D
    }
  }

  clarinet {
    m1-3 {
      8G4 A B C D E | D C B A G F | E F G A B C
    }
  }
}

Each clarinet bar holds two dotted quarters, and each lasts one horn quarter. So the horn's two bars of 3/4 hold three clarinet bars, m1-3. The engine works out each part's exact tempo: here the clarinet's eighth runs at 360 while the horn's quarter runs at 120. Because the clarinet's m3 would name the score's m3, music cannot yet follow a section where a follower has more bars than the primary; that is refused with polymeter.bounds. Parts may also stand on separate rows inside poly {…}, one part per row. format writes them back as one comma-separated line, which is the form shown here.

at m1-2 {meter poly {…}} is the same definition written as a context. Polymeter playback does not yet combine with written navigation, hearing or expression readings, a uniform tempo or the pulse overlay; each is refused by name. How independent barlines are engraved is not yet decided (ruling N112c).

Clefs and instruments

Catalog instruments provide their normal clef. Use clef bass, clef alto, or another supported clef where necessary, and [clef bass] for an inline change. Numeric clefs 1 through 7 mean treble, soprano, mezzo-soprano, alto, tenor, baritone, and bass respectively. An instrument change is written [instrument piccolo]; inspect the resulting range and written part when doubling instruments.

Placing a part's sound

Inside a part body, pan -100 places its sound hard left, pan 0 centres it, and pan 100 places it hard right. Intermediate whole numbers set positions between them. Omitting pan leaves an unstated centre; an explicit zero stays in the source. Pan changes playback placement, not staff order or notation.

ScoreScript sourceDownload source
scorescript 0.3
score "Two positions" {
  parts { flute horn-f }
  flute {
    pan -100
    m1 { 1C5 }
  }
  horn-f {
    pan 100
    m1 { 1G4 }
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Two positions" {
  parts {
    flute
    horn-f
  }

  flute {
    pan -100

    m1 {
      1C5
    }
  }

  horn-f {
    pan 100

    m1 {
      1G4
    }
  }
}

Pan is constant for the part. Fractional or out-of-range values are errors; score-level pan, pan maps, aliases such as left, and mid-bar pan changes are not supported. MusicXML and MIDI exports carry the authored position.

Moving a voice between staves

Inside a piano voice, [staff 2] displays following notes on the second staff. The shortcut is [st 2]. [staff own] or [st own] returns to the voice's original staff. The change persists until replaced and does not alter the voice, sounding pitch, rhythm, or another voice's staff assignment.

ScoreScript sourceDownload source
scorescript 0.3
score "One voice, two staves" {
  meter 4/8

  parts { pn }

  pn t {
    m1 {
      eC5 [st b] D3 [st own] E5 [st b] F3
    }
  }

}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "One voice, two staves" {
  meter 4/8

  parts {
    pn
  }

  pn treble {
    m1 {
      8C5 [staff b] D3 [staff own] E5 [staff b] F3
    }
  }

  pn bass {
  }
}

The piano owns both staves; its empty partner needs no placeholder rests.

A printed roster label, such as parts { pn: "Added Parts" }, keeps those same staff addresses. Use pn treble and pn bass to write its music. An explicit [staves 1] still selects a single-staff piano. Staff numbers count from the top within the same instrument. t, treble, and st1 select staff 1; b, bass, and st2 select staff 2. These names still select the same physical staff after a clef change. A change moves the complete note or chord. It does not split individual chord members or move music into another instrument. The destination staff's clef determines where the notes print. Staff changes also work inside a tuplet.

A part-header map can target one voice: staff {m1 v2 2, m2 v2 own} places voice 2 on the second staff from measure 1 and returns it at measure 2. The same assignments can be written at m1 {staff v2 2} and at m2 {staff v2 own}. st is available in both forms. Other voices retain their assignments. Name an existing voice; an unknown voice is an error.

The same map can stand above the music, with its instrument and source staff named explicitly:

ScoreScript sourceDownload source
meter 4/8
parts { pn }
staff { pn t { m1 v2 b, m2 v2 own } }
pn t {
  m1-2 { v1 [ hC5 | D ] v2 [ hE3 | F ] }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
meter 4/8

parts {
  pn
}

pn treble {
  staff {m1 v2 b, m2 v2 own}

  m1-2 {
    v1 [ 2C5 | D ]
    v2 [ 2E3 | F ]
  }
}

pn bass {
}

st is the short map head; piano treble is the long owner spelling here. For two pianos, use pn 1 t or pn 2 t. The map may precede or follow the roster and music. Switching between part-first and measure-first source keeps the ownership; the formatter may place the map inside its part body. Extracting the complete piano keeps both staves and its mapped destinations. Putting an edited piano part back preserves the other instruments. A map in one movement does not assign staves in another movement.

To limit a destination to a group of complete measures, collect them in a scope:

ScoreScript sourceDownload source
meter 4/8

parts {
  piano 3
}

piano {
  m1-4 {
    [staff m1-3 2] 2C5 | [staff m2-2 3] D | E | F
  }
}

piano {
  m1-4 {
    r(hidden) | r(hidden) | r(hidden) | r(hidden)
  }
}

piano {
  m1-4 {
    r(hidden) | r(hidden) | r(hidden) | r(hidden)
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
meter 4/8

parts {
  piano 3
}

piano {
  m1-4 {
    [staff m1-3 2] 2C5 | [staff m2-2 3] D | E | F
  }
}

piano {
  m1-4 {
    r(hidden) | r(hidden) | r(hidden) | r(hidden)
  }
}

piano {
  m1-4 {
    r(hidden) | r(hidden) | r(hidden) | r(hidden)
  }
}

For an instrument with three staves, this reads on staff 2, then staff 3, then staff 2 again. Measure 4 resumes the assignment from before the outer scope. A scope restores the previous assignment even if it was another staff. Changes made inside a tuplet also end with the enclosing scope.

The same bounded assignment can be placed at the first measure as [staff m1-3 2], in a part's map as staff {m1-3 2}, or in an addressed block as at m1-3 {staff 2}. The explicit at m1 {staff m1-3 2} also works. Add v2 before the destination to select that voice in a map. Ranges must name existing measures and nest completely; a range that crosses another range's closing boundary is an error.

Extract the complete Piano instrument to keep both staves and their routes. Extracting only Piano 1 or Piano 2 is refused when a connection would lose its other end. Source part get and part put preserve the complete instrument; keep its staff names and order when putting the music back.

An unwritten piano staff bar, or an empty collection such as m2 { }, supplies automatic silence. Its placeholder rest disappears when music is routed into that staff. Write r (or a rest run such as r4) when an independent voice really rests: those rests remain visible. Formatting, extraction and MusicXML round trips preserve this distinction.

Declared ranges

The instrument catalog knows each instrument's practical and full range and advises when a note leaves them (range.above-practical, range.outside-professional). A range you declare is different: it is a contract, and a note outside it is an error (range.outside-declared). Use it to hold a part to an audition table, a grade level, or a passage's intended register — and to give an agent writing the part a boundary it cannot cross silently.

ScoreScript sourceDownload source
scorescript 0.3
score "Held to a range" {
  meter 4/4
  range written { fl C4-C7, tpt F#3-C6 }

  parts {
    fl
    tpt
  }

  fl {
    m1 {
      4C5 D E F
    }
  }

  tpt {
    range written G3-G5

    m1 {
      4C4 D E F
    }
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Held to a range" {
  meter 4/4
  range written { fl C4-C7, tpt F#3-C6 }

  parts {
    fl
    tpt
  }

  fl {
    m1 {
      4C5 D E F
    }
  }

  tpt {
    range written G3-G5

    m1 {
      4C4 D E F
    }
  }
}

The score head's map states one range per roster key; a part's own range replaces the map's entry for that part; at m9 { range written C4-C6 } and an inline [range written C4-C6] change it at a bar and hold until the next change, like a clef. range catalog returns a stretch to the catalog's advice and range none switches the check off.

Bounds are written (what the player reads — how every audition table is printed) or concert (what sounds); a concert bound is converted through the part's transposition before it is compared, so range concert F3-C5 on a horn holds the player to written C4–G5. The lower pitch comes first.

A range can carry two tiers, the way the catalog's own bands do: range written { warn B3-F5, cap F#3-D6 }. A note past the warn band is a warning (range.outside-warn); a note past the cap is the error. On the roster line the same contract is a word after the key — tpt-c F#3-C6 is the cap alone, tpt-c warn B3-F5 cap F#3-D6 both tiers — written pitch unless concert precedes it.

Highlighted pitches

A highlight prints chosen pitches in a colour — the notes a student must watch, the maximums of an audition range in red:

ScoreScript sourceDownload source
scorescript 0.3
score "Watch these" {
  meter 4/4

  parts {
    fl C4-C7
  }

  fl {
    highlight { color: red, G6-C7, color: blue, C4 }

    m1-2 {
      4C4 D E F | G6 A B C
    }
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Watch these" {
  meter 4/4

  parts {
    fl C4-C7
  }

  fl {
    highlight { color: red, G6-C7, color: blue, C4 }

    m1-2 {
      4C4 D E F | G6 A B C
    }
  }
}

highlight { … } lists single pitches (C4) and ranges (G6-C7), each group opened by color: — red, orange, yellow, green, blue, purple, or gray. Pitches are written pitch (what the player reads) unless concert precedes the braces. The same doors as a range: in the score head it is every part's default; in a part it holds from the first bar; at m9 { highlight … } and an inline [highlight …] change it at a bar and hold until the next change; highlight none switches it off. The colour follows the note through every view — the trumpet's written G5 is red on its part and red, sounding F5, in the concert score.

Beams

Standard grouping follows the meter. An override such as [beams 3+3+2] counts in eighths — in every meter, whatever the meter's own denominator is — and so fits a whole 4/4 measure. The eighth is where beaming starts, so it is what a bare grouping counts in.

ScoreScript sourceDownload source
[beams 3+3+2] 8C5 D E F G A B C
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
[beams 3+3+2] 8C5 D E F G A B C

To count in anything else, say the unit, either as a letter in front (w h q e s t) or as a /N suffix:

ScoreScript sourceDownload source
// two quarters, then two
[beams q2+2] 4C5 D E F
// sixteenths, six and six and four
[beams 6+6+4/16] 16C D E F G A B C D E F G A B C D
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
// two quarters, then two
[beams q2+2] 4C5 D E F
// sixteenths, six and six and four
[beams 6+6+4/16] 16C D E F G A B C D E F G A B C D

A meter counted in a unit coarser than the eighth — 4/4, 3/2 — keeps the eighth as its default too, so the same numbers mean the same thing wherever they are written.

[beams none] separates the notes; [beams beat] groups by beat; [beams standard] restores the standard grouping. A custom grouping is remembered for its meter when that meter returns. standard clears that meter's remembered override.

For unmetered eighth-pair exercises, [beams beat] repeats a quarter-note grid for the whole authored bar. State it once; the following bars inherit it. There is no need to spell [beams 1+1+1+1+1+1+1+1/4] on every line. Keep an explicit list when its unequal groups are intentional.

Rehearsal marks

Default and recommended: boxed actual measure numbers, including inside the measures themselves. Choose the placement that suits your source:

PlacementSourceMeaning
Inside a continuous measure block... F | [[5]] G ...A boxed 5 on the measure containing G
Inside an addressed measurem5 { [[5]] 1G }A boxed 5 on measure 5
In a score-level mapRH {m5, m9, m13}Boxed 5, 9, and 13 at those measures across the score

Inside continuous measures

Place the box after the barline and before that measure's first note. It takes no musical time and does not reset the inherited duration or octave.

ScoreScript sourceDownload source
scorescript 0.3
score "Measure-number landmarks" {
  meter 4/4

  part piano

  piano {
    m1-8 {
      1C5 | D | E | F | [[5]] G | F | E | D
    }
    m9-16 {
      [[9]] 1C | D | E | F | [[13]] G | F | D | C
    }
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Measure-number landmarks" {
  meter 4/4

  part piano

  piano {
    m1-8 {
      1C5 | D | E | F | [[5]] G | F | E | D
    }
    m9-16 {
      [[9]] 1C | D | E | F | [[13]] G | F | D | C
    }
  }
}

Inside separately addressed measures

The same music and the same boxes can be written a bar at a time, addressed: m5 { [[5]] 1G }. The box sits where it always sits — after the address, before that measure's first note.

Formatting folds a run of separately addressed bars back into one range block, so the chapter shows only the folded form above: the addressing is a way to type the music, not a second shape the file keeps.

In a map

These same landmarks can instead live in RH {m5, m9, m13}. Each map entry is both the address and displayed number; no repeated label or extra brackets are needed. Include 1 only when an opening box is wanted: RH {m1, m5, m9, m13}. The equivalent inline opening is m1 { [[1]] 1C5 }.

ScoreScript sourceDownload source
scorescript 0.3
score "Measure-number landmarks" {
  meter 4/4

  RH {m5, m9, m13}

  part piano

  piano {
    m1-8 {
      1C5 | D | E | F | G | F | E | D
    }
    m9-16 {
      1C | D | E | F | G | F | D | C
    }
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
scorescript 0.3
score "Measure-number landmarks" {
  meter 4/4

  RH {m5, m9, m13}

  part piano

  piano {
    m1-8 {
      1C5 | D | E | F | G | F | E | D
    }
    m9-16 {
      1C | D | E | F | G | F | D | C
    }
  }
}

An inline [[5]] is a label on its containing measure, not a jump to measure 5 or an automatic current-measure placeholder. Keep that explicit number aligned with its measure when inserting or renumbering bars. The map is score-wide; an inline mark inside one part belongs to that part. The three examples above are equivalent because they contain one part.

A custom boxed letter such as [[A]] or RH A, and a circled (A), are optional alternatives—not the recommended default. In a map, RH {m5 [[A]], m9 (B)} explicitly chooses those alternate labels/shapes. Single [A] is neither: it is the retired spelling and the reader refuses it by name — write [[A]] for the box, or a bare A for the pitch.

The default is manual placement: only requested marks are printed. rehearsal auto is an optional, separate scheme that derives sequential letter marks at structural seams; it is not needed for the recommended numbered map. Written marks take precedence. Check the rendered rehearsal sequence before extracting parts.

One piano, two staves

Declare one piano with parts { pn }. pn, pno, and piano all name the piano. Its upper staff starts in treble clef and its lower staff in bass clef. Use pn t { ... } and pn b { ... } to write their music; the long selectors are piano treble { ... } and piano bass { ... }.

ScoreScript sourceDownload source
meter 4/8

parts {
  pn
}

pn treble {
  m1 {
    8C5 D E F
  }
}

pn bass {
  m1 {
    4C3 G'
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
meter 4/8

parts {
  pn
}

pn treble {
  m1 {
    8C5 D E F
  }
}

pn bass {
  m1 {
    4C3 G'
  }
}

The staff selector remains the same after a clef change. pn b { clef treble ... } still writes on the lower staff. A second voice belongs to its staff, not automatically to the lower staff:

ScoreScript sourceDownload source
meter 4/8

parts {
  pn
}

pn treble {
  m1 {
    v1 [ 8C5 D E F ]
    v2 [ 4G4 A ]
  }
}

pn bass {
  m1 {
    2C3
  }
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
meter 4/8

parts {
  pn
}

pn treble {
  m1 {
    v1 [ 8C5 D E F ]
    v2 [ 4G4 A ]
  }
}

pn bass {
  m1 {
    2C3
  }
}

[st 2] moves following notes to the second staff; [st 1] returns to the first. Their voice and sounding pitches do not change. The older st own means the voice's owning staff, which may be either staff.

For two piano players, write parts { pn 2 [staves 2] }, then pn 1 t, pn 1 b, pn 2 t, and pn 2 b bodies. sts is the shortcut for staves. For a single-staff piano use [staves 1]; for three staves use [staves 3] and address the third as pn st3. Old numbered rosters such as piano 2 without a staff instruction keep their earlier two-staff interpretation.

Place a part's sound

pan -100 puts a part at hard left; pan 0 centres it; pan 100 puts it at hard right. Any whole number between those endpoints is allowed. Without a pan declaration the part is centred. The setting belongs to the entire part, so write it outside the measures:

ScoreScript sourceDownload source
parts {fl ob}
fl {
  pan -60
  m1 {1C5}
}
ob {
  pan 60
  m1 {1E5}
}
Generated notationNotation for the preceding Meter, key, tempo, and clef example
Canonical spelling
parts {
  fl
  ob
}

fl {
  pan -60

  m1 {
    1C5
  }
}

ob {
  pan 60

  m1 {
    1E5
  }
}

This moves the sound, not its notes on the page. MusicXML and MIDI carry the same position. Fractions and numbers outside -100 through 100 are errors.