The support forum is temporarily read-only. For urgent requests, please email contact[at]psyberia.net

[fixed] KML File polygon borders too thin - not importing properly

Something wrong? Report it here
Post Reply
DolphinsPC

[fixed] KML File polygon borders too thin - not importing properly

Post by DolphinsPC »

Hi,

AQ has bug. Not importing KML file polygons correctly. The import is successful. But is displayed incorrect. Borders are too thin and almost invisible. Must zoom in too far to see. And color is not correct.

Offer Your ideas?
Thanks you


Here is sample of KML file...

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2" xmlns:gx="http://www.google.com/kml/ext/2.2" xmlns:kml="http://www.opengis.net/kml/2.2" xmlns:atom="http://www.w3.org/2005/Atom">
<Document>
	<name>Test.kml</name>
	<StyleMap id="msn_ylw-pushpin">
		<Pair>
			<key>normal</key>
			<styleUrl>#sn_ylw-pushpin</styleUrl>
		</Pair>
		<Pair>
			<key>highlight</key>
			<styleUrl>#sh_ylw-pushpin</styleUrl>
		</Pair>
	</StyleMap>
	<Style id="sh_ylw-pushpin">
		<IconStyle>
			<scale>1.3</scale>
			<Icon>
				<href>http://maps.google.com/mapfiles/kml/pushpin/ylw-pushpin.png</href>
			</Icon>
			<hotSpot x="20" y="2" xunits="pixels" yunits="pixels"/>
		</IconStyle>
		<BalloonStyle>
		</BalloonStyle>
		<LineStyle>
			<color>ffff00ff</color>
			<width>4</width>
		</LineStyle>
		<PolyStyle>
			<color>00ffffff</color>
		</PolyStyle>
	</Style>
	<Style id="sn_ylw-pushpin">
		<IconStyle>
			<scale>1.1</scale>
			<Icon>
				<href>http://maps.google.com/mapfiles/kml/pushpin/ylw-pushpin.png</href>
			</Icon>
			<hotSpot x="20" y="2" xunits="pixels" yunits="pixels"/>
		</IconStyle>
		<BalloonStyle>
		</BalloonStyle>
		<LineStyle>
			<color>ffff00ff</color>
			<width>4</width>
		</LineStyle>
		<PolyStyle>
			<color>00ffffff</color>
		</PolyStyle>
	</Style>
	<Folder>
		<name>Temporary Places</name>
		<open>1</open>
		<Placemark>
			<name>Untitled Polygon</name>
			<styleUrl>#msn_ylw-pushpin</styleUrl>
			<Polygon>
				<tessellate>1</tessellate>
				<outerBoundaryIs>
					<LinearRing>
						<coordinates>
							-86.0061660216454,38.29808251717118,0 -85.58716900921911,37.49252070301364,0 -85.25322339432266,37.04951715896762,0 -84.03361459588464,37.78492595439324,0 -84.70243172413959,38.55973892194613,0 -86.0061660216454,38.29808251717118,0 
						</coordinates>
					</LinearRing>
				</outerBoundaryIs>
			</Polygon>
		</Placemark>
	</Folder>
</Document>
</kml>
Psyberia-Support
Site Admin
Posts: 6407
Joined: Wed Apr 14, 2010 9:41 pm

Re: KML File polygon borders too thin - not importing properly

Post by Psyberia-Support »

I'll have a look.
If there is a bug I'll correct it.
Do you like AlpineQuest ? Leave a small comment on Google Play !
Psyberia-Support
Site Admin
Posts: 6407
Joined: Wed Apr 14, 2010 9:41 pm

Re: KML File polygon borders too thin - not importing properly

Post by Psyberia-Support »

Here are my results:
- The app does not support multiple colors for one item, so you cannot have an area filled with one color and outlined with another one. So the app uses the "<PolyStyle>" color, white in your case;
- Concerning the width of lines, the outlines cannot be currently styled. I'll add this in the next version however, so you'll be able to display thicker outlines.
Do you like AlpineQuest ? Leave a small comment on Google Play !
DolphinsPC

Re: KML File polygon borders too thin - not importing properly

Post by DolphinsPC »

Hello,

Thank you for your concern with my problem.

I do not understand why this is issue. I have another KML that is OK. Contains only polygons. Color and border size correct. On this file, I have pasted style section of KML into bad file. Re-assigned all placemarks style urls and still no success on the file.

I have remedied issue by using 'Path' placemark for border (path work successfully) and using polygon transparent to allow clicking within bounds of polygon.

Style section of KML that works OK:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2" xmlns:gx="http://www.google.com/kml/ext/2.2" xmlns:kml="http://www.opengis.net/kml/2.2" xmlns:atom="http://www.w3.org/2005/Atom">
<Document>
	<name>TOWNSHIPS.kml</name>
	<Style id="SUBSTYLE">
		<LineStyle>
			<color>cc00b3ff</color>
			<width>2.7</width>
		</LineStyle>
		<PolyStyle>
			<color>00ffffff</color>
		</PolyStyle>
	</Style>
	<Style id="MAINSTYLE">
		<LineStyle>
			<color>80ffff55</color>
			<width>4</width>
		</LineStyle>
	</Style>
Psyberia-Support
Site Admin
Posts: 6407
Joined: Wed Apr 14, 2010 9:41 pm

Re: KML File polygon borders too thin - not importing properly

Post by Psyberia-Support »

In the example you gave above, in the "SUBSTYLE" style you have defined 2 colors, one for the lines ("<LineStyle>") which is KML color code "cc00b3ff", and one for the polygons ("<PolyStyle>") which is KML color code "00ffffff" = transparent full white.
For areas, the application only uses the polygon (PolyStyle) color, so it's white. And it does not take into account the width.
For paths, the application uses the line (LineStyle) color and width.

If you want to make an area filled in one color, with an outline of a different color, you can create one polygon with one line string above, with the correct color and width.
Do you like AlpineQuest ? Leave a small comment on Google Play !
Post Reply