zoom/pane controls

4 posts, 0 answers
  1. Daniel
    Daniel avatar
    6 posts
    Member since:
    Jan 2012

    Posted 05 Dec 2013 Link to this post

    Hello,

    Is there a way to turn off the zoom and pane controls?  Ideally I just want the map to sit over a country and not be moved.

    Additionally is there an easy way to display hover text in a bubble when hovering over geo polygon location?

    Thanks!
  2. T. Tsonev
    Admin
    T. Tsonev avatar
    2770 posts

    Posted 09 Dec 2013 Link to this post

    Hi,

    Constraining the zoom is easy enough, just set minZoom, maxZoom and zoom to the same value.

    Disabling the panning is a different matter, as there's no built-in option to control it.
    This as an omission that we'll address in the next internal build by adding a "pannable" option. We'll also add a complimentary "zoomable" option. Both will apply only to user interaction, not to the API.
    A rather nasty workaround would be to destroy the map scroller:
    $("#map").data("kendoMap").scroller.destroy();

    The shapeMouseEnter and shapeMouseLeave events are suitable for your second requirement. You can show a Window at the mouse coordinates with data for the particular shape.

    I hope this helps.

    Regards,
    T. Tsonev
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Kendo UI is VS 2017 Ready
  4. Daniel
    Daniel avatar
    6 posts
    Member since:
    Jan 2012

    Posted 09 Dec 2013 Link to this post

    Hi,

    Thanks, much better than my nastier work around for pannable.  I was having it redraw the map if it detected a pane action!  While it worked just fine, it added a sort of 1/2 sec lag if you looked closely.

    As far as my second requirement, I was more hoping that the API actually had a built in tool tip like in bar charts, etc..  I could certainly get a second library to do this as well, but it would be easier to have it wrapped in the map API.

    Thanks for the help :)
  5. T. Tsonev
    Admin
    T. Tsonev avatar
    2770 posts

    Posted 11 Dec 2013 Link to this post

    Hello,

    The zoomable and pannable options are now live in the latest internal build. No hacks required, just an update.

    We're considering a built-in tooltip for the shapes. There are a few technical difficulties regarding this feature, most notably performance related.
    I hope we'll have a solution ready for the next major release.

    Thank you for your feedback.

    Regards,
    T. Tsonev
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Back to Top
Kendo UI is VS 2017 Ready