[mkgmap-dev] Styles, typ and multiple languages
From 7770 7770 at foskan.eu on Tue Nov 10 14:19:40 GMT 2020
Hi. Thanks all for the ideas, it works well to add information. The one thing i was not able to complete was to delete the name. First i have: tourism=lean_to | (amenity=shelter & shelter_type=lean_to) [0x2b05 resolution 24] and after the include section: tourism=lean_to | (amenity=shelter & shelter_type=lean_to) {add mkgmap:phone = '${name}'; delete name} The text from the name is nicely added into the phone section. But the name remains, instead of being deleted... (what did i do wrong?) Regard Karl On måndag 9 november 2020 kl. 21:19:26 CET Ticker Berkin wrote: > Hi Karl > Yes, for POI there is an address and phone number and the address > components can be misused as you suggest. > I've just experimented with this and haven't found any disruption of > normal address searches. > It is best to append to one of the address fields after any other > address processing has been done, so I suggest putting any code after: > include 'inc/address'; > towards the bottom of your 'points' file > In the UK the postcode field comes last, so it looks better to append > to this, rather than the region. I've added: > opening_hours=* > {set mkgmap:postal_code='${mkgmap:postal_code}. Open > ${opening_hours}' | > 'Open ${opening_hours}'} > website=* > {set mkgmap:postal_code='${mkgmap:postal_code}. ${website}' | > '${website}'} > Which keeps any existing postcode and doesn't add unnecessary ". " > I don't know what the size limitations for these fields. > Ticker > > On Mon, 2020-11-09 at 18:06 +0100, 7770 wrote: > > Hi. > > I answers the question, though may not help too much.. > > > > How does the --poi-address work? > > It states that it enables address / phone information to POIs. > > Is this a feature of Garmin devices that only works for exactly > > address and > > phone. > > I think i have seen some maps with opening hours added to POIs. > > Can the same idea/pattern be used for anything? > > > > Opentopomap does like this for opening hours and website: > > opening_hours=* {set > > mkgmap:region='${opening_hours|subst:Tu=>Di|subst:We=>Mi| > > subst:Th=>Do|subst:Su=>So}' } > > website=* {set mkgmap:region='${mkgmap:region} ${website}'} > > etc. > > > > But maybe this breaks other functionality? > > > > > > Regards > > Karl > > > > On måndag 9 november 2020 kl. 10:57:39 CET Ticker Berkin wrote: > > > Hi Karl > > > > > > I don't think what you are hoping for can be done. Some of it is > > > possible for special cases, but not generally. > > > > > > If a POI has a name and the name is the same as a TYP translation, > > > then > > > logic can be added to the rule for the point to suppress the name, > > > eg, > > > > > > for english: > > > sport=swimming {set name='${name|not-equal:"Swimming Pool"}'} > > > > > > [0x...] > > > > > > It is unlikely that any OSM objects are tagged in this rather > > > pointless > > > way. > > > > > > There isn't anywhere except the name/label field for a specific > > > name, > > > and, apart from Roads, there is only 1 name field. > > > > > > The behaviour of Garmin devices differs regarding showing static > > > information from the typeCode and/or the name in the map. Some show > > > both when the item is selected, others just the name if set or the > > > TYP > > > translation otherwise (and just say "Unnamed" if the item isn't > > > defined > > > in the TYP file). > > > > > > A good option for making a more useable map of a foreign country by > > > a > > > speaker of another language is --name-tag-list. > > > > > > For example, make a map of Morocco I use: > > > --name-tag-list=name:en,int_name,name:fr,name,place_name,loc_name > > > > > > Does this answer your question about multiple name tags? > > > > > > Ticker > > > > > > On Fri, 2020-11-06 at 19:40 +0100, 7770 wrote: > > > > Hi. > > > > > > > > I am looking into a pattern where a name of a map point is given > > > > in a > > > > local > > > > word, which is not easy for foreigners. Instead of showing the > > > > name > > > > as the > > > > name, i would like to move it into the information which becomes > > > > available when clicking on a point on a Garmin device. Hence > > > > leaving > > > > the name > > > > empty or removed. > > > > > > > > Example: > > > > Say we have a lean-to shelter somewhere in Sweden. > > > > The name is set as: "Vindskydd rastaplatsen". > > > > For any foreigner, this may not say a lot. > > > > Whereas in the TYP file it is defined with the description: > > > > .. > > > > String=Lean to shelter > > > > String6=0x07,Vindskydd > > > > String7=0x15,Schronienie > > > > String10=0x0f,Gapahuk > > > > etc. > > > > etc. > > > > .. > > > > > > > > So when pointing/hovering this object on the GPS unit, i will > > > > tell me > > > > in the > > > > local language (which is set up on the unit) what it is (taken > > > > from > > > > the TYP > > > > file). > > > > When clicking the item, i will get the info page with additional > > > > details, and > > > > here is the name. > > > > > > > > But the question is now: how do i get the additional details to > > > > the > > > > info page? > > > > Can i just add any tag an it will show? > > > > > > > > Would something like this work? > > > > tourism=lean_to | (amenity=shelter & shelter_type=lean_to) {add > > > > info > > > > = '$ > > > > {name}'; delete name} [0x2b05 resolution 24] > > > > > > > > > > > > > > > > Is it otherwise possible to define multiple name tags, one per > > > > language? > > > > name = general name > > > > name:en = English name > > > > name:se = Swedish name > > > > > > > > so that the device will pick up the correct one based on the > > > > language > > > > settings? > > > > > > > > > > > > > > > > Regards > > > > Karl > > > > > > > > > > > > > > > > _______________________________________________ > > > > mkgmap-dev mailing list > > > > mkgmap-dev at lists.mkgmap.org.uk > > > > http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev > > > > > > _______________________________________________ > > > mkgmap-dev mailing list > > > mkgmap-dev at lists.mkgmap.org.uk > > > http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev > > > > _______________________________________________ > > mkgmap-dev mailing list > > mkgmap-dev at lists.mkgmap.org.uk > > http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
- Previous message: [mkgmap-dev] Styles, typ and multiple languages
- Next message: [mkgmap-dev] Styles, typ and multiple languages
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the mkgmap-dev mailing list