Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to draw broken Line of mulch in Comprehensive Application of Qt Map compilation

2025-03-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/02 Report--

This article is to share with you about how to draw broken lines of mulch in Qt's comprehensive mapping application. The editor thinks it is very practical, so share it with you as a reference and follow the editor to have a look.

I. Preface

Line chart is currently the most widely used to draw a variety of tracks, line chart is actually behind the dynamic trajectory map, the predecessor of the aircraft route map, a common method addPolyline, line chart can be set color, thickness, transparency and other properties, if you open the suspension drawing toolbar, you can also directly click the line chart drawing tool in the toolbar, direct dynamic drawing.

II. Functional features

Both online map and offline map modes are supported.

It also supports webkit kernel, webengine kernel, miniblink kernel and IE kernel.

Multiple dimension points can be set, including name, address, longitude and latitude.

You can set whether the map can be clicked, dragged, or scrolled.

You can set the protocol version, secret key, theme style, central coordinates, central city, geocoding location, and so on.

Can set the map zoom scale and level, thumbnails, scale, road information and other controls visible.

Support map interaction, such as mouse press to get the latitude and longitude of the corresponding location.

Support to query the route, you can set the starting point, end point, route mode, route mode, route scheme (minimum time, least transfer, least walk, do not take the subway, shortest distance, avoid highway).

Can display dots, lines and surfaces tools, and can draw lines, points, rectangles, circles and so on directly on the map.

Administrative divisions can be set up, a certain urban area drawing layer can be specified, and the online map automatically outputs the administrative division boundary points to the js file for offline map use.

Multiple coverings can be added statically or dynamically. Support points, broken lines, polygons, rectangles, circles, arcs, point aggregations, etc.

Provides a function interface to handle latitude and longitude resolution to address and address resolution to latitude and longitude coordinates.

The demo provided can be directly selected to perform corresponding processing such as route query.

You can get the collection of point coordinate information queried by the route, such as for robot coordinate navigation.

Encapsulates a wealth of functions such as deleting specified points and all points, deleting specified coverings and all coverings, etc.

Callout point pop-up box information can be customized in standard html format.

Dimension point click event optional 0-do not process 1-own pop-up box 2-send a signal.

Dimension points can be animated 0-do not process 1-Jump 2-fall

Dimension points can be set up local picture files and so on.

The function interface is friendly and unified, and it is easy to use, just one class.

Support js dynamic interaction to add points, delete points, clear points, reset points, no need to refresh the page.

Support any Qt version, any system, any compiler.

Third, effect picture

4. The related code void MapBaiDu::addPolyline (QStringList & list) {/ / dynamically add broken line list

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report