Skip to content
  • Federico Mena Quintero's avatar
    PathBuilder::to_cairo() - Check the cr.status after completing the path · 9af3a3a4
    Federico Mena Quintero authored
    Any of the individual path commands may cause the cr to enter an
    error state, for example, if they come with coordinates outside of Cairo's supported range.
    
    The *next* call to the cr will probably be something that actually
    checks the status (i.e. in cairo-rs), and we don't want to panic
    there.
    
    (In the worst case, Cairo will throw out-of-memory with a super-long
    path, but this is the correct place to catch that.)
    9af3a3a4