Re: [mkgmap-dev] default style improvements

2018-12-08 Thread Ticker Berkin
Hi Gerd

Here is revision to defaultStyleTidy3.patch. The changes are:

1/ change highway=trail to highway=path; add bicycle=no instead of
track

2/ don't generate routable line for highway=rest_area

Regards
Ticker
 
Index: resources/styles/default/inc/access_country
===
--- resources/styles/default/inc/access_country	(revision 4258)
+++ resources/styles/default/inc/access_country	(working copy)
@@ -4,19 +4,26 @@
 
 # Belgium (BEL)
 
-highway=trunk & mkgmap:country=BEL	{ add bicycle=no; add foot=no }
-highway=cycleway & mkgmap:country=BEL	{ add foot=yes }
-highway=bridleway & mkgmap:country=BEL	{ add foot=yes }
+highway=trunk & mkgmap:country=BEL {add bicycle=no; add foot=no}
+highway=cycleway  & mkgmap:country=BEL {add foot=yes}
+highway=bridleway & mkgmap:country=BEL {add foot=yes}
 
 # The Netherlands (NLD)
 
-highway=trunk & mkgmap:country=NLD	{ add bicycle=no; add foot=no }
-highway=cycleway & mkgmap:country=NLD	{ add foot=yes }
-highway=bridleway & mkgmap:country=NLD	{ add foot=yes }
+highway=trunk & mkgmap:country=NLD {add bicycle=no; add foot=no}
+highway=cycleway  & mkgmap:country=NLD {add foot=yes}
+highway=bridleway & mkgmap:country=NLD {add foot=yes}
 
 # Spain (ESP)
 
-highway=trunk & mkgmap:country=ESP	{ add bicycle=yes; add foot=yes }
-highway=bridleway & mkgmap:country=ESP	{ add bicycle=yes; add foot=yes }
+highway=trunk & mkgmap:country=ESP {add bicycle=yes; add foot=yes}
+highway=bridleway & mkgmap:country=ESP {add bicycle=yes; add foot=yes}
 
+# United Kingdom (GBR)
 
+highway=cycleway  & mkgmap:country=GBR {add foot=yes}
+highway=bridleway & mkgmap:country=GBR {
+add bicycle=yes;
+add foot=yes;
+add motor_vehicle=private
+}
Index: resources/styles/default/lines
===
--- resources/styles/default/lines	(revision 4258)
+++ resources/styles/default/lines	(working copy)
@@ -10,9 +10,12 @@
 
 addr:housenumber=* {set mkgmap:execute_finalize_rules=true}
 
-aeroway=runway & highway!=* & is_closed()=false {name '${ref}'} [0x27 resolution 20]
-(aeroway=taxiway | aeroway=taxilane) & highway!=* & is_closed()=false {name '${ref}'} [0x27 resolution 24]
+abandoned=yes {deletealltags}  # old, depreciated, ambiguous, method of handling abandoned
 
+# do these as lines regardless of being closed unless explicity marked as area. continue in case also a highway
+aeroway=runway & area!=yes {name '${ref}'} [0x27 resolution 20 continue]
+(aeroway=taxiway | aeroway=taxilane) & area!=yes {name '${ref}'} [0x27 resolution 24 continue]
+
 # Assign the street name for house number search
 highway=* & name=* {set mkgmap:street='${name}'}
 
@@ -19,22 +22,22 @@
 # Mark highways with the toll flag
 highway=* & (toll=yes | toll=true) {set mkgmap:toll=yes}
 
-# mark multipolygons as area
-highway=* & mkgmap:mp_created=true {add area=yes}
-
 # Hide proposed ways
 highway=proposed | highway=proposal | highway=planned | highway~'.*proposed.*' {delete highway; delete junction}
 # Hide removed ways
-highway=razed | highway=dismantled {deletealltags}
+highway=razed | highway=dismantled | highway=disused | highway=demolished {delete highway; delete junction}
 # Hide abandoned ways. Abandoned highways have some evidence of their former existence but are no longer used. These
 # abandoned highways could be useful in topographical maps.
 # https://wiki.openstreetmap.org/wiki/Key:abandoned:
-(abandoned:highway=* & highway!=*) | highway=abandoned {deletealltags}
+(abandoned:highway=* & (highway!=* | highway=yes)) | highway=abandoned {delete highway; delete junction}
 # Hide other non-existent ways
 highway=unbuilt | highway=neverbuilt | highway=rejected | highway~'x-.*' {delete highway; delete junction}
 # Remove highway tag from ways which are not suitable for routing
-highway=traffic_signals | highway=junction | highway=island | highway=centre_line | highway=traffic_island | highway=stopline
+highway=traffic_signals | highway=junction | highway=island | highway=centre_line | highway=traffic_island | highway=stopline |
+highway=bus_stop | highway=bus_guideway | highway=escape | highway=emergency_bay | highway=emergency_access_point |
+highway=ohm:military:Trench
 {delete highway}
+highway=via_ferrata {delete highway}  # this shouldn't show as routable on default map: path only for specialists
 highway=piste | highway=ski {delete highway}
 highway=no | highway=none {delete highway}
 
@@ -89,7 +92,7 @@
 (highway=bridleway | highway=path | highway=track) & mkgmap:unpaved!=0 {add mkgmap:unpaved=1}
 (highway=unsurfaced | highway=via_ferrata) {set mkgmap:unpaved=1}
 
-highway=* & mkgmap:unpaved!=1 & smoothness~'.*(bad|horrible|impassable)' {add mkgmap:road-speed='-2'}
+highway=* & mkgmap:unpaved!=1 & smoothness~'.*(bad|horrible|impassable)' {add mkgmap:road-speed=-2}
 
 # Good ways without relation
 highway=* & mkgmap:fast_road!=* & (int_ref=* | network=e-road | network=AH 

Re: [mkgmap-dev] How can I force the inners of a boundary relation to display?

2018-12-08 Thread Greg Troxel
Dave Swarthout  writes:

> I do use a fill. It isn't a solid color but a small letter "R" to stand for
> Reserve. That does show me where the inners are in a fashion but I would
> like to experiment with getting them to display with some sort of a line.

Certainly that makes sense and my comments were stronger than they
should have been.

I wonder if the issue is with things being too large to fit in some sort
of tile, or if this happens even for small objects.
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


Re: [mkgmap-dev] How can I force the inners of a boundary relation to display?

2018-12-08 Thread Dave Swarthout
That does work but it makes all ways that are named boundary relations (
with mkgmap:boundary_name =*) render with the same style. I can live with
that but I'm still wondering if there is a way to force it to only operate
on inners and only on ways of type boundary=protected_area ? Can I set in
"relations" and test in "lines" for a new mkgmap:boundary_name, for
example, boundary1_name?

Another interesting problem I just noticed is that simple islands (not
multipolygons) whose coastlines are also boundaries do not display as
islands, only as members of the refuge they are a part of. The coastlines
fail to display whether or not the above code is active or commented out so
it must be a separate issue. Take a look at Village Islands inside the
Kodiak National Wildlife Refuge. These display as  continuous boundaries
with my style [0x10e12], but there is no "land" inside the boundaries, only
sea. So, these objects are tagged as place=islet, natural=coastline, but
they are also outers in the Kodiak National Wildlife Refuge.

Dave

On Sat, Dec 8, 2018 at 6:13 PM Gerd Petermann <
gpetermann_muenc...@hotmail.com> wrote:

> Hi Dave,
>
> there is code in mkgmap to treat multipolygon relations. See
> mkgmap:mp_created and mkgmap:stylefilter in
> http://www.mkgmap.org.uk/doc/pdf/style-manual.pdf
> The multipolygon code produces those extra ways only for the outer rings.
> If you just want to render the outlines you may use something like
> mkgmap:boundary_name=* 0x10e12 resolution 19 continue]
> at the top of the lines file.
>
> Gerd
>
> 
> Von: Dave Swarthout 
> Gesendet: Samstag, 8. Dezember 2018 11:30
> An: Gerd Petermann
> Cc: Development list for mkgmap
> Betreff: Re: [mkgmap-dev] How can I force the inners of a boundary
> relation to display?
>
> Yes, that's confusing to me. I included those snippets to illustrate what
> I am currently using — maybe you can explain to me stepwise how those
> boundaries get rendered?
>
> Is there code inside mkgmap that interprets such directives and applies
> tags to the outer ways of relations? If there is then I assume the same can
> be done for those inners. And you would be the one who can best answer that
> question.
>
> Thanks for taking the time to explain.
>
> Dave
>
> On Sat, Dec 8, 2018 at 5:03 PM Gerd Petermann <
> gpetermann_muenc...@hotmail.com>
> wrote:
> Hi Dave,
>
> in the relations rule you set mkgmap:boundary_name but in the lines rule
> you don't use that.
>
> Gerd
>
> 
> Von: mkgmap-dev  mkgmap-dev-boun...@lists.mkgmap.org.uk>> im Auftrag von Dave Swarthout <
> daveswarth...@gmail.com>
> Gesendet: Samstag, 8. Dezember 2018 03:18
> An: Development list for mkgmap
> Betreff: [mkgmap-dev] How can I force the inners of a boundary relation
> to  display?
>
> Hi,
>
> I've been adding large Alaskan National Wildlife Refuges to OSM. The
> boundaries weren't displaying so I added a directive in my relations file
> modeled after the administrative boundary code in the default style that
> adds a name to protected areas like so:
>
> (type=boundary | type=multipolygon) & boundary=protected_area & name=*
> { apply
>   {
> set mkgmap:boundary_name='$(mkgmap:boundary_name)/${name}' | '${name}';
>   }
> }
>
> Then in my lines file I included a line style defined as:
> boundary=nature_reserve | boundary=protected_area [0x10e12 resolution 19].
>
> This works well but the lines bounding the inner areas of these relations
> do not render. How can I make them display?
>
> Many thanks
>
> Dave
>
> --
> Dave Swarthout
> Homer, Alaska
> Chiang Mai, Thailand
> Travel Blog at http://dswarthout.blogspot.com
>
>
> --
> Dave Swarthout
> Homer, Alaska
> Chiang Mai, Thailand
> Travel Blog at http://dswarthout.blogspot.com
>


-- 
Dave Swarthout
Homer, Alaska
Chiang Mai, Thailand
Travel Blog at http://dswarthout.blogspot.com
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Re: [mkgmap-dev] How can I force the inners of a boundary relation to display?

2018-12-08 Thread Gerd Petermann
Hi Dave,

there is code in mkgmap to treat multipolygon relations. See mkgmap:mp_created 
and mkgmap:stylefilter in http://www.mkgmap.org.uk/doc/pdf/style-manual.pdf
The multipolygon code produces those extra ways only for the outer rings.
If you just want to render the outlines you may use something like
mkgmap:boundary_name=* 0x10e12 resolution 19 continue]
at the top of the lines file.

Gerd


Von: Dave Swarthout 
Gesendet: Samstag, 8. Dezember 2018 11:30
An: Gerd Petermann
Cc: Development list for mkgmap
Betreff: Re: [mkgmap-dev] How can I force the inners of a boundary relation to 
display?

Yes, that's confusing to me. I included those snippets to illustrate what I am 
currently using — maybe you can explain to me stepwise how those boundaries get 
rendered?

Is there code inside mkgmap that interprets such directives and applies tags to 
the outer ways of relations? If there is then I assume the same can be done for 
those inners. And you would be the one who can best answer that question.

Thanks for taking the time to explain.

Dave

On Sat, Dec 8, 2018 at 5:03 PM Gerd Petermann 
mailto:gpetermann_muenc...@hotmail.com>> wrote:
Hi Dave,

in the relations rule you set mkgmap:boundary_name but in the lines rule you 
don't use that.

Gerd


Von: mkgmap-dev 
mailto:mkgmap-dev-boun...@lists.mkgmap.org.uk>>
 im Auftrag von Dave Swarthout 
mailto:daveswarth...@gmail.com>>
Gesendet: Samstag, 8. Dezember 2018 03:18
An: Development list for mkgmap
Betreff: [mkgmap-dev] How can I force the inners of a boundary relation to  
display?

Hi,

I've been adding large Alaskan National Wildlife Refuges to OSM. The boundaries 
weren't displaying so I added a directive in my relations file modeled after 
the administrative boundary code in the default style that adds a name to 
protected areas like so:

(type=boundary | type=multipolygon) & boundary=protected_area & name=*
{ apply
  {
set mkgmap:boundary_name='$(mkgmap:boundary_name)/${name}' | '${name}';
  }
}

Then in my lines file I included a line style defined as: 
boundary=nature_reserve | boundary=protected_area [0x10e12 resolution 19].

This works well but the lines bounding the inner areas of these relations do 
not render. How can I make them display?

Many thanks

Dave

--
Dave Swarthout
Homer, Alaska
Chiang Mai, Thailand
Travel Blog at http://dswarthout.blogspot.com


--
Dave Swarthout
Homer, Alaska
Chiang Mai, Thailand
Travel Blog at http://dswarthout.blogspot.com
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


Re: [mkgmap-dev] How can I force the inners of a boundary relation to display?

2018-12-08 Thread Dave Swarthout
Yes, that's confusing to me. I included those snippets to illustrate what I
am currently using — maybe you can explain to me stepwise how those
boundaries get rendered?

Is there code inside mkgmap that interprets such directives and applies
tags to the outer ways of relations? If there is then I assume the same can
be done for those inners. And you would be the one who can best answer that
question.

Thanks for taking the time to explain.

Dave

On Sat, Dec 8, 2018 at 5:03 PM Gerd Petermann <
gpetermann_muenc...@hotmail.com> wrote:

> Hi Dave,
>
> in the relations rule you set mkgmap:boundary_name but in the lines rule
> you don't use that.
>
> Gerd
>
> 
> Von: mkgmap-dev  im Auftrag von
> Dave Swarthout 
> Gesendet: Samstag, 8. Dezember 2018 03:18
> An: Development list for mkgmap
> Betreff: [mkgmap-dev] How can I force the inners of a boundary relation
> to  display?
>
> Hi,
>
> I've been adding large Alaskan National Wildlife Refuges to OSM. The
> boundaries weren't displaying so I added a directive in my relations file
> modeled after the administrative boundary code in the default style that
> adds a name to protected areas like so:
>
> (type=boundary | type=multipolygon) & boundary=protected_area & name=*
> { apply
>   {
> set mkgmap:boundary_name='$(mkgmap:boundary_name)/${name}' | '${name}';
>   }
> }
>
> Then in my lines file I included a line style defined as:
> boundary=nature_reserve | boundary=protected_area [0x10e12 resolution 19].
>
> This works well but the lines bounding the inner areas of these relations
> do not render. How can I make them display?
>
> Many thanks
>
> Dave
>
> --
> Dave Swarthout
> Homer, Alaska
> Chiang Mai, Thailand
> Travel Blog at http://dswarthout.blogspot.com
>


-- 
Dave Swarthout
Homer, Alaska
Chiang Mai, Thailand
Travel Blog at http://dswarthout.blogspot.com
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Re: [mkgmap-dev] How can I force the inners of a boundary relation to display?

2018-12-08 Thread Gerd Petermann
Hi Dave,

in the relations rule you set mkgmap:boundary_name but in the lines rule you 
don't use that.

Gerd


Von: mkgmap-dev  im Auftrag von Dave 
Swarthout 
Gesendet: Samstag, 8. Dezember 2018 03:18
An: Development list for mkgmap
Betreff: [mkgmap-dev] How can I force the inners of a boundary relation to  
display?

Hi,

I've been adding large Alaskan National Wildlife Refuges to OSM. The boundaries 
weren't displaying so I added a directive in my relations file modeled after 
the administrative boundary code in the default style that adds a name to 
protected areas like so:

(type=boundary | type=multipolygon) & boundary=protected_area & name=*
{ apply
  {
set mkgmap:boundary_name='$(mkgmap:boundary_name)/${name}' | '${name}';
  }
}

Then in my lines file I included a line style defined as: 
boundary=nature_reserve | boundary=protected_area [0x10e12 resolution 19].

This works well but the lines bounding the inner areas of these relations do 
not render. How can I make them display?

Many thanks

Dave

--
Dave Swarthout
Homer, Alaska
Chiang Mai, Thailand
Travel Blog at http://dswarthout.blogspot.com
___
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev