How to encode ties in **kern data.

Ties

Ties are indicated by attaching [ to the starting note of a tie, and ] on the ending note. For intermediate notes in a tied group, the underscore character _ indicates a previous tie ends on the note at the same time that a tie starts to the next note.

Tie orientation

There are two ways to control the placement of ties on the staff. When a tie needs to be placed in an arbitrary position, use one of the following two systems.

By layout parameters

The !LO:T: layout prefix indicates that the layout parameter applies to the tie in the next data token in the spine. To force the tie above the staff, add the parameter a, which is short for a=true. To force the tie below the staff, add the parameter b.

By RDF records

When tie orientations need to be adjusted often in a score, a more compact way of encoding them is to use an RDF record:

In the above example, the < character is defined as a qualification on the tie to force it below the staff, and > is used to force the tie above the staff. These characters must immediately follow the [ (or ‘_’) character representing the tie start. Other positions in the token will cause slur or beam to be oriented up or down, and placing the above/below signifiers after a note will move it to the next staff above or below the current one.

Ties on chords

When a chord possesses two or more ties, they can be oriented above or below using either of the two methods described above. For controlling the orientation using a layout command, add n=1 to the layout parameter to modify only the tie on the first note, n=2 for the second note, and so on.

Dashed and dotted ties

Layout parameters can be prefixed to the starting token of a tie to display the tie as dotted or dashed lines.

The layout prefix !LO:T: means that the layout parameter applies to a tie in the next data token. To display the tie as a dashed line, add the parameter dash which is equivalent to dash=true. To display the tie as a dotted line, add the parameter dot.

Coloring ties

Ties can be colored by giving an SVG color as a color layout parameter:

Disjunct tied notes

Sometimes ties connect two notes that are not directly adjacent. This usually occurs in the case of written out arpeggios. In such cases, double the tie signifier to indicate that the ending note of the tie does not directly follow the starting note of the tie.

Notice that the last sixteenth note is adjacent to the chord to which all of the notes are tied, so it has a regular tie signifier.

Cross-staff tied notes

Cross-staff ties (in particular for piano music), can be created using an RDF record as in the following example:

The RDF record N = linked is used to create the link between the two tie endpoints in the data. The link signifier must come immediately in front of the tie signifiers in the data. And the matching tie can be either adjacent or disjunct on the other staff.