Embed google maps in Java desktop Application

前端 未结 2 1331
面向向阳花
面向向阳花 2020-12-01 09:43

I want to embed google maps on a JPanel. Since I want features like zoom-in/out, using static images isn\'t feasible.

To achieve this, I\'ll probably need to embed a

2条回答
  •  刺人心
    刺人心 (楼主)
    2020-12-01 10:28

    You can use JxMaps library to complete this task. It has Swing component which can be simply embedded to JPanel.

    void createMapView(JPanel parent) {
        MapView view = new MapView();
        parent.add(view);
    }
    

    This library has comprehensive set of classes for working with Google Maps from java.

提交回复
热议问题