-
Notifications
You must be signed in to change notification settings - Fork 685
Description
In stringsync/vexml#201, I'm using vexflow to draw slurs encoded in MusicXML. I have a few asks for the Curve API.
-
Fix the types. Curve objects can be partial, but the constructor forces you to specify
Noteinstead ofNote | undefined. -
Allow me to specify the curve opening direction. Otherwise, I have to mimic the calculation that
vexflowdoes to figure out the direction of the opening, and my implementation will know too much about how vexflow works. Maybe a property inCurveOptionslikeopeningDirection?: 'up' | 'down' | undefined. -
Make
vexflowdynamically calculatecpswhen not provided one inCurveOptions. Currently, it will just use the defaultcpsthat theCurveconstructor sets. As I was migrating slurs fromStaveTie, I thought it would be a similar experience whereCurvewould just mostly work. However, I had no idea howcpswere control points that influenced the shape of the curve until I opened up theCurveimplementation and studied it. It probably would be a good experience forvexflowusers to not have to calculate control points.