<html><head></head><body><div><span class="short_text" lang="en"><span class="">Usually (in Italy) the municipality name is used as city in </span></span><span id="result_box" class="short_text" lang="en"><span class="">composing the address but it</span></span><span id="result_box" class="short_text" lang="en"><span class=""> often happens that within the municipality there are other main towns </span></span>which names are used instead.</div><div>I want this addresses to be searchable with both the municipality name (admin_level=8) and the city name when it differs (tagged with addr:city=*).</div><div>I use the default style with little modifications and added this rules in the points file.</div><div><br></div><div>On top, first create a "fake" object only for searching, which will be matched by default rules in address file, so these will have admin_level8 as mkgmap:city.</div><div>  addr:city=* & 'addr:city'!='mkgmap:admin_level8'    [0x3200 continue with_actions]</div><div><br></div><div>Then set mkgmap:city with the addr:city value to have this as city for the following matches.</div><div>      addr:city=* & 'addr:city'!='mkgmap:admin_level8'    { set mkgmap:city='${addr:city}' }</div><div><br></div><div>I also added modified the rule at the bottom to avoid "fake" objects to get a name and show on the map.</div><div>      !(addr:city=* & 'addr:city'!='mkgmap:admin_level8' & mkgmap:city!=*) &</div><div>       name=* { name '${name}' }</div><div><br></div><div><br></div><div><br></div><div>This seems to work pretty well but it looks rather complicated. I wonder if there is a better way to do this. Any thoughts?</div><div><br></div><div>These are my options:</div><div>        --style-file=$style_reg \</div><div>        --latin1 \</div><div>        --country-name=Italia \</div><div>        --country-abbr="$abbr" \</div><div>        --region-name="$nome_reg" \</div><div>        --area-name="$nome_reg" \</div><div>        --family-name="OpenStreetMap: Mappe regionali ital.img" \</div><div>        --description="$nome_reg" \</div><div>        --series-name="$serie" \</div><div>        --precomp-sea=${MYPATH}/sea/ \</div><div>        --generate-sea \</div><div>        --bounds=${MYPATH}/bounds/ \</div><div>        --max-jobs \</div><div>        --route \</div><div>        --drive-on=detect,right \</div><div>        --process-destination \</div><div>        --process-exits \</div><div>        --location-autofill=is_in,nearest \</div><div>        --index \</div><div>        --split-name-index \</div><div>        --housenumbers \</div><div>        --add-pois-to-areas \</div><div>        --link-pois-to-ways \</div><div>        --preserve-element-order \</div><div>        --verbose \</div><div>        --name-tag-list=name,name:it,loc_name,reg_name,nat_name \</div><div>        --draw-priority=$priority \</div><div>        --reduce-point-density=3.2 \</div><div>        --make-opposite-cycleways \</div><div>        --gmapsupp</div><div><br></div><div><br></div><div>Lorenzo</div></body></html>