1. 14 Mar, 2019 5 commits
    • Federico Mena Quintero's avatar
    • Federico Mena Quintero's avatar
      Remove unnecessary import · 0fcebff1
      Federico Mena Quintero authored
      0fcebff1
    • Federico Mena Quintero's avatar
      (#438): Only create a temporary ImageSurface if we'll need filtering · 692c0b65
      Federico Mena Quintero authored
      When with_discrete_layer() needs a temporary surface, the original C
      code distinguished between the case where filters will run (so it
      needs an ImageSurface), and the "easy" case, where it is sufficient to
      have a surface of similar type to the cr's current target.
      
      If we always create an ImageSurface, it causes the following problem.
      When rendering to a Cairo PDF surface, if some SVG elements have
      opacity or clip (but no filters), then those elements will be rendered
      to a raster surface unnecessarily, while PDF is perfectly capable of
      representing them with vector primitives.
      
      Thanks to Julian Sparber, Jordan Petridis, and Zeeshan Ali for doing
      the huge bisect needed to find the culprit
      a9a5b65e from last year!
      
      Also, check the status of the temporary surface by hand, since
      cairo-rs doesn't.
      
      Fixes #438
      692c0b65
    • Federico Mena Quintero's avatar
      DrawingCtx: remove the surfaces_stack · c1e6c962
      Federico Mena Quintero authored
      The stack of surfaces is implicit in the cr_stack, and only the
      topmost surface was ever used for filtering, anyway.
      c1e6c962
    • Federico Mena Quintero's avatar
      PathBuilder::to_cairo() - Check the cr.status after completing the path · de961d2f
      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.)
      de961d2f
  2. 23 Feb, 2019 1 commit
  3. 21 Feb, 2019 1 commit
  4. 16 Feb, 2019 2 commits
  5. 15 Feb, 2019 5 commits
  6. 14 Feb, 2019 3 commits
  7. 21 Jan, 2019 2 commits
  8. 20 Jan, 2019 1 commit
  9. 18 Jan, 2019 1 commit
  10. 17 Jan, 2019 2 commits
  11. 29 Dec, 2018 2 commits
  12. 14 Dec, 2018 6 commits
  13. 12 Dec, 2018 1 commit
  14. 11 Dec, 2018 3 commits
  15. 06 Dec, 2018 3 commits
  16. 27 Nov, 2018 2 commits