How to force to show all placemarks even when overlapp each other

王璀 WANG Cui iucgnaw at msn.com
Sun Mar 26 06:22:12 BST 2023


Hi Torsten,
Thanks for the tip.
I quickly hacked code as attached patch, it does can show all placemarks as I expected.

However, to make it a valid enhancement, I have below questions:
- Where to add new API? The hack code impact all placemarks, I believe should limit it to requestor (i.e. specific plugin), but keep old behavior for others.
- Looks like PlacemarkLayout binds to PlacemarkLayer. I guess LayerInterface is right way to change for new API?
- For plugin, how to to create a new layer and customize layer’s behavior via API?
- For placemarksOnScreenLimit, I guess should be similar, add new API to set limits by requestor?

Hope my comment is reasonable.
Thanks,
WANG Cui

From: Torsten Rahn <tackat at t-online.de>
Sent: Sunday, March 26, 2023 2:29 AM
To: ?? WANG Cui <iucgnaw at msn.com>; Mailinglist, Marble-Devel <marble-devel at kde.org>
Subject: AW: How to force to show all placemarks even when overlapp each other


Hello,



yes the default behavior is that Marble will only populate the map view with "the most prominent" placemarks up to a certain density.

At the same time it also takes care not to have the labels overlapped (by testing out four default label positions).

The current layout algorithm is optimized for speed.



The density check is made inside placemarksOnScreenLimit and there is currently no API that would allow to change this default behavior.

Feel free to create a patch that would allow to change the limit away from the default via a dedicated API.



Best regards

Torsten









-----Original-Nachricht-----

Betreff: How to force to show all placemarks even when overlapp each other

Datum: 2023-03-25T15:26:50+0100

Von: "?? WANG Cui" <iucgnaw at msn.com<mailto:iucgnaw at msn.com>>

An: "Mailinglist, Marble-Devel" <marble-devel at kde.org<mailto:marble-devel at kde.org>>






Hi,
Placemarks all show on globe when separate from each other without overlapping. However, when zoom out globe, placemarks get overlap and only 1 placemark shows, other placemarks hide.
Is there a way to force all placemarks show even when overlap each other?
Thanks,
WANG Cui



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/marble-devel/attachments/20230326/1b7ee07c/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: paint_overlapped_placemarks.patch
Type: application/octet-stream
Size: 1998 bytes
Desc: paint_overlapped_placemarks.patch
URL: <http://mail.kde.org/pipermail/marble-devel/attachments/20230326/1b7ee07c/attachment-0001.obj>


More information about the Marble-devel mailing list