SandDance icon indicating copy to clipboard operation
SandDance copied to clipboard

Limit zoom level

Open mariusgessler opened this issue 5 years ago • 6 comments
trafficstars

Hello,

Thanks again for the great work on Sandance! I was wondering if there is a way to limit the zoom level on a graph. When zooming in all the way I am facing the issue of labels overlapping. Screen Shot 2020-08-07 at 9 15 07 PM

Thanks!

mariusgessler avatar Aug 07 '20 19:08 mariusgessler

Hello and thanks for the feedback. This is not an easy problem to fix universally, but for now we have a few sliders in the settings tab: image

danmarshall avatar Aug 07 '20 20:08 danmarshall

Thanks for your response. I suppose this means there is currently no way to do it programatically?

mariusgessler avatar Aug 12 '20 15:08 mariusgessler

The text scale can be set programmatically. The Insight object has a signalValues property, you can set insight.signalValues['Text_ScaleSignal'] = yourScaleValue. Other SignalNames can be found here.

I can provide a better code sample if you let me know which component you're using.

danmarshall avatar Aug 12 '20 18:08 danmarshall

Re-reading your original post, I see that you also would like to limit the zoom. I think that's also a useful feature. We use deck.gl for rendering, and I see that their doc for orbitView does indeed support min and max zoom. So we would just need to add these options to our api.

danmarshall avatar Aug 12 '20 19:08 danmarshall

I am using the SandDance core visualization canvas and was able to change the text scale. It helps but I think limiting the zoom level would indeed be the better solution. Thanks again!

mariusgessler avatar Aug 13 '20 08:08 mariusgessler

I'll give this a go!

mariusgessler avatar Aug 14 '20 16:08 mariusgessler