Flat Brace
flat-brace()
Draw a flat curly brace between two points.
cetz.decorations.flat-brace((0,1),(2,1))
cetz.decorations.flat-brace((0,0),(2,0),
  curves: .2,
  aspect: 25%)
cetz.decorations.flat-brace((0,-1),(2,-1),
  outer-curves: 0,
  aspect: 75%)
This mimics the braces from TikZ's decorations.pathreplacing library.
In contrast to the brace function, these braces use straight line segments, resulting in better looks for long braces with a small amplitude.
start:
Start point
end:
End point
Styling
Root: flat-brace
- aspect (ratio) = 50% Determines the fraction of the total length where the spike will be placed.
Curviness factor of the brace, a factor of 0 means no curves.
 
Anchors
- start Where the brace starts, same as the 
startparameter. - end Where the brace end, same as the 
endparameter. - spike Point of the spike's top.
 - content Point to place content/text at, in front of the spike.
 - center Center of the enclosing rectangle.