Author Topic: How to change theme?  (Read 888 times)

Offline rusm

  • Newbie
  • *
  • Posts: 2
    • View Profile
How to change theme?
« on: February 28, 2017, 18:08:32 »
Hi.
Sorry for maybe lame question, but I know nothing about vector themes. And I really need to learn how to do just one little thing:
Need to change scale visibility of Viewpoint icon on Openstreetmaps in Locus - just to see it in more smaller scales.

So, I'm using maps and Elevation theme downloaded from http://www.openandromaps.org/en/legend/elevate-mountain-hike-theme

In theme file Elements.xml I found only one text block with "viewpoint". Is it possible to change something to be able to see Viewpoints in 1-2-3 smaller scale?

<rule cat="tourism-outdoor" e="any" k="*" v="*" zoom-min="9">
      <rule e="any" k="tourism" v="viewpoint">
         <rule e="any" k="natural" v="~">
            <rule e="any" k="tower" v="~">
               <symbol src="file:../ele_res/s_viewpoint.svg" symbol-width="16dp" />
            </rule>
 

Offline jusc

  • Global Moderator
  • Professor of Locus
  • *****
  • Posts: 1883
  • Thanked: 16 times
    • View Profile
  • Device: Samsung Galaxy S2 and Note 2
Re: How to change theme?
« Reply #1 on: March 02, 2017, 16:37:48 »
Do you want to increase the svg by defualt or should it grow while you are zooming in?
Regards J.
 

Offline rusm

  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: How to change theme?
« Reply #2 on: March 03, 2017, 15:17:58 »
Do you want to increase the svg by defualt or should it grow while you are zooming in?

Not sure that I understand right ))
But I need to see viewpoint icon in low scales, now it just not shown. Not need to change size of icon, just it visibility.
« Last Edit: March 03, 2017, 15:19:45 by rusm »
 

Offline Jencek

  • More than Newbie
  • *
  • Posts: 31
  • Thanked: 5 times
    • View Profile
  • Device: Xiaomi, Redmi Note 4, Global
Re: How to change theme?
« Reply #3 on: April 27, 2017, 08:54:35 »
Visibility is the property of the mapsforge library, it determines what it does and when it renders when information is power to display. This modification can be helped in the .xml file

<rule cat="tourism-outdoor" e="any" k="*" v="*" zoom-min="9">
      <rule e="any" k="tourism" v="viewpoint">
         <rule e="any" k="natural" v="~">
            <rule e="any" k="tower" v="~">
               <symbol src="file:../ele_res/s_viewpoint.svg" force-draw="1" symbol-width="16dp" />
            </rule>
Hledám pro radost.
 

Offline PawelS

  • Newbie
  • *
  • Posts: 1
    • View Profile
  • Device: Moto G
Re: How to change theme?
« Reply #4 on: June 23, 2017, 18:07:18 »
How to change viewpoints' zoom-min visibility in the Internal theme, which currently is 15?

In the tag-mapping_20170119.xml there is:

<osm-tag key="tourism" value="viewpoint" zoom-appear="13"/>

so they may be visible from zoom 13, right?

In a copied locus_internal_theme_20170119.xml I've added

Code: [Select]
<rule cat="tourism_topo" e="any" k="tourism" v="*" zoom-min="13" >
<rule e="any" k="tourism" v="viewpoint" >
<symbol src="file:/symbols/db_poi_viewpoint.svg" symbol-color="#755741"  symbol-width="14dp" scale-icon-size="17,1.15" />
</rule>
</rule>

Is it correct? Viewpoints are still displayed only from zoom 15. Lines 2-4 I've moved from a previous section about displaying icons from zoom 15.
« Last Edit: June 23, 2017, 18:09:27 by PawelS »