enable icon indicating copy to clipboard operation
enable copied to clipboard

Make sure all kiva backends implement AbstractGraphicsContext faithfully

Open jwiggins opened this issue 4 years ago • 3 comments

Since AbstractGraphicsContext is the published and documented interface for kiva backends, we should make sure that all current backends actually use that interface.

  • [x] select_font is not consistently implemented [closed by #691]
  • [ ] Gradients work very differently in the Quartz backend (they are applied immediately as a fill of the current path)
  • [ ] A number of backends that could implement gradients, don't (PDF, SVG).
  • [ ] The PDF, PS, and SVG backends have no CompiledPath. PDF could have one (not sure about the others)
  • [ ] draw_marker_at_points [details in #708]
  • [ ] arc takes a keyword argument cw, not clockwise as it's called in several backends (celiagg, qpainter)
  • [ ] set_flatness is mostly not implemented. (only Cairo has it)
  • [ ] set_image_interpolation is mostly not implemented (only kiva.agg has it)
  • [ ] set_text_drawing_mode is mostly not implemented
  • [ ] The text position and text matrix is not uniformly implemented
  • [ ] *_character_spacing is not widely implemented
  • [ ] All backends should implement all the curve commands consistently: arc, arc_to, quad_curve_to, curve_to. (partial fixes in #970 and #988, see also #960, #961, #962, #985)

jwiggins avatar Mar 01 '21 14:03 jwiggins

The PDF, PS, and SVG backends have no CompiledPath

All the backends that inherit from basecore2d can use the Agg CompiledPath implementation, but they don't expose it in the module API: https://github.com/enthought/enable/blob/dae67fea0b6729cf43841c1e45bcda62ea463739/kiva/basecore2d.py#L704-L743

corranwebster avatar Aug 10 '22 08:08 corranwebster

I'm pretty averse to creating new dependencies on the Agg backend. We should consider a different way.

jwiggins avatar Aug 10 '22 08:08 jwiggins

This isn't new, just noting that there is a default implementation.

I agree thought: I'd really like a pure python implementation of CompiledPath, together with a proper definition of the expected interface.

corranwebster avatar Aug 10 '22 10:08 corranwebster