Skip to main content

Semantic Rules

Element Identification

  • All rings and chains must have unique identifiers within pattern scope
  • Identifiers follow pattern: elementtype + number (e.g., ring1, chain2)
  • Custom names allowed: center_ring, petal_chain

Pattern Import System

  • import "path/to/pattern.tatml" as motif_name loads external pattern
  • Imported patterns become reusable components
  • Pattern elements accessible via motif_name.element_id

Pattern Usage & Connection

// Use imported pattern with connections
motif1: use flower_motif with {
    connect ring1.picot1 to flower_motif.ring1.picot3
}

Picot Addressing

  • Picots automatically numbered 1, 2, 3... in order of appearance
  • Named picots override automatic numbering for that position
  • References use dot notation: ring1.picot2, chain1.join_here
  • Cross-pattern references: motif1.ring2.picot1

Picot Variations

TatML supports different picot types and length specifications:

Picot Types

  • p - Normal picot (default)
  • sp - Small picot
  • lp - Large picot
  • jp - Joining picot

Length Specification

ring1: R(4, p("5mm"), 4, sp("3mm"), 4)

Named Picots

ring2: R(5, p:join_here, 5, sp:tiny, 5)

Grammar

Picot := PicotType (LengthSpec)? (NameSpec)?
PicotType := "p" | "sp" | "lp" | "jp"
LengthSpec := "(" String ")"
NameSpec := ":" Identifier

Mock Rings

Mock rings are self-closing rings that don't actually close, used in advanced tatting techniques:

mock1: MR(4, p, 4, p, 4)
chain1: C(6, join(mock1.picot1), 6)  // Thread continues

Key Properties

  • Use MR() syntax instead of R()
  • Thread does not close the ring - continues to next element
  • Can have picots and joins like regular rings
  • Appear in diagrams with dashed lines to show the gap