0

I've got a very simple graph with a handful of nodes. The Nodes use SVG background images and they scale without issue in Chrome/IE. These are defined in JS using the cytoscape css functional format and given to cytoscape for initialization.

However, they appear to be rendered as bitmaps in FF (v29.0). If I set the size to 50px, that's the size they stay and any zooming results in nasty pixelation. Oddly, the 'native' cytoscape graphic elements (arrows and text) scale without issue. Any ideas?

2 Answers2

0

That's a browser implementation difference. If you don't like how Firefox handles drawing SVGs in canvas, then you should file a bug report with them.

maxkfranz
  • 11,896
  • 1
  • 27
  • 36
0

I was able to use a careful combination of the style API and the zoom event to redraw the SVG background in Firefox according to a given zoom amount.

So far, it's acceptably performant for small graphs (I never have too many nodes on the canvas at any one time) so it looks like this will work as a rough work-around in Firefox.