Support "on hover" labels in KML import (scale 0)
KML has "hovering" placemark labels that only appear when pointer is on top. It would be great if Locus supported that. Maybe it's a rather simple addition, since you already seem to parse styles somewhat and since Locus supports "hovering" for its waypoints already.
The technique used in KML for this is to scale the normal label to 0 using a style map.
<Style id="top0"><LabelStyle><scale>0</scale></LabelStyle></Style>
<Style id="top1"><LabelStyle><scale>1</scale></LabelStyle></Style>
<StyleMap id="top">
<Pair><key>normal</key><styleUrl>#top0</styleUrl></Pair>
<Pair><key>highlight</key><styleUrl>#top1</styleUrl></Pair>
</StyleMap>
A simplified scanner in Locus could for example parse the label styles for a placemark and do something like
if (normal->scale==0 && highlight->scale!=0)
set_waypoint_label_to_hovering();
Attached is a sample kml file for hovering labels. In Google Earth, all photo waypoints (little camera) and all blog entry waypoints (white bubble) show their labels only when the mouse is on top. In Locus, all labels are always visible.
Attached is a sample kml file for hovering labels. In Google Earth, all photo waypoints (little camera) and all blog entry waypoints (white bubble) show their labels only when the mouse is on top. In Locus, all labels are always visible.
Hello, task done. Please just keep in mind, that settings in map - object & styles > content of popup for points > labels on map, has a priority. So if you disable labels here, they won't be visible no matter of it's style.
Hello, task done. Please just keep in mind, that settings in map - object & styles > content of popup for points > labels on map, has a priority. So if you disable labels here, they won't be visible no matter of it's style.
Another problem related to labels is that KML / GoogleEarth does not show labels for linestrings. People add a <point> in a <multigemoetry> when they want their linestrings to have a label.
Locus does show labels for "linestrings" (which become tracks), at least when its settings tell it to. This mostly results in double labels when showing KML, one from the linestring/track and one from the point.
Maybe tracks imported from KML linestrings should set their label in Locus to OnHover or Never automatically?
In general, I guess KML/KMZ used as mapitem shouldn't depend on Locus settings at all. But this is probably quite hard to do with current implementation.
Another problem related to labels is that KML / GoogleEarth does not show labels for linestrings. People add a <point> in a <multigemoetry> when they want their linestrings to have a label.
Locus does show labels for "linestrings" (which become tracks), at least when its settings tell it to. This mostly results in double labels when showing KML, one from the linestring/track and one from the point.
Maybe tracks imported from KML linestrings should set their label in Locus to OnHover or Never automatically?
In general, I guess KML/KMZ used as mapitem shouldn't depend on Locus settings at all. But this is probably quite hard to do with current implementation.
Hmm, what you describe leads to "visible kml won't depend on Locus implementation, but on how Google Earth display it". It's wrong as well.
If you find me in official KML documentation ( https://developers.google.com/kml/documentation/kmlreference#syntax_71 ), that Labels should not apply on LineStrings, I'll do something with it. Otherwise your method with point is just a hack on Google Earth, that is not needed in Locus.
EDIT: as I think about it, labels for tracks in Locus are completely independent on LabelStyle in KML. If you do not want to see them, just disable them.
Hmm, what you describe leads to "visible kml won't depend on Locus implementation, but on how Google Earth display it". It's wrong as well.
If you find me in official KML documentation ( https://developers.google.com/kml/documentation/kmlreference#syntax_71 ), that Labels should not apply on LineStrings, I'll do something with it. Otherwise your method with point is just a hack on Google Earth, that is not needed in Locus.
EDIT: as I think about it, labels for tracks in Locus are completely independent on LabelStyle in KML. If you do not want to see them, just disable them.
Why do I care so much about KML? Because I made a kml network link that automatically displays tracks of many major tour portals inside Locus (utagawa, gpsies, etcpp). Inside Locus, these are a hundred times more useful for researching trips than in separate ugly apps or in a browser.
However, Locus insists on adding its labels and icons to my network link kml... which kind of destroys the map. Fixing that by changing Locus Settings is besides the point... because I might actually want to see track labels and icons for all the other tracks in the Locus database.
Why do I care so much about KML? Because I made a kml network link that automatically displays tracks of many major tour portals inside Locus (utagawa, gpsies, etcpp). Inside Locus, these are a hundred times more useful for researching trips than in separate ugly apps or in a browser.
However, Locus insists on adding its labels and icons to my network link kml... which kind of destroys the map. Fixing that by changing Locus Settings is besides the point... because I might actually want to see track labels and icons for all the other tracks in the Locus database.
Replies have been locked on this page!