mapsforge map theme: reference to patterns and symbols only possible with absolute paths
+2
orux
keenonkites
6 posters
mapsforge map theme: reference to patterns and symbols only possible with absolute paths
Hi,
recently we struggled over the following problem:
If we download a mapsforge map with the according theme xml file which references symbol files and pattern files it does only work if absolut paths are in the respective lines. Using relative paths (relative to the location of the xml theme file) it does not work and the screen stays black.
Here an example:
Working is the following:
But relative paths are allowed in mapsforge.
The concept that the theme needs to be named the same as the mapfile just with an additional .xml at the end is not optimal if several cards are installed using the same theme. Additionally it contains the danger that, different themes might reference same pattern or symbol names with different content.
Much better would be a possibility to have the different themes all in separate subdirectories, this way there will be no conflicts.... the directory name could still be made out of the mapname, but inho having a possibility to choose the theme would be even better.
Gracias y Saludos de Suiza
Patrik
recently we struggled over the following problem:
If we download a mapsforge map with the according theme xml file which references symbol files and pattern files it does only work if absolut paths are in the respective lines. Using relative paths (relative to the location of the xml theme file) it does not work and the screen stays black.
Here an example:
Working is the following:
- Code:
<area src="file:/storage/emulated/0/oruxmaps/mapfiles/patterns/weinberg-32.png"/>
- Code:
<area src="file:./patterns/weinberg-32.png"/>
- Code:
<area src="file:patterns/weinberg-32.png"/>
But relative paths are allowed in mapsforge.
The concept that the theme needs to be named the same as the mapfile just with an additional .xml at the end is not optimal if several cards are installed using the same theme. Additionally it contains the danger that, different themes might reference same pattern or symbol names with different content.
Much better would be a possibility to have the different themes all in separate subdirectories, this way there will be no conflicts.... the directory name could still be made out of the mapname, but inho having a possibility to choose the theme would be even better.
Gracias y Saludos de Suiza
Patrik
keenonkites- Cantidad de envíos : 3
Fecha de inscripción : 2013-03-28
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
keenonkites wrote:Hi,
recently we struggled over the following problem:
If we download a mapsforge map with the according theme xml file which references symbol files and pattern files it does only work if absolut paths are in the respective lines. Using relative paths (relative to the location of the xml theme file) it does not work and the screen stays black.
Here an example:
Working is the following:Not working:
- Code:
<area src="file:/storage/emulated/0/oruxmaps/mapfiles/patterns/weinberg-32.png"/>
Also not working:
- Code:
<area src="file:./patterns/weinberg-32.png"/>
- Code:
<area src="file:patterns/weinberg-32.png"/>
But relative paths are allowed in mapsforge.
The concept that the theme needs to be named the same as the mapfile just with an additional .xml at the end is not optimal if several cards are installed using the same theme. Additionally it contains the danger that, different themes might reference same pattern or symbol names with different content.
Much better would be a possibility to have the different themes all in separate subdirectories, this way there will be no conflicts.... the directory name could still be made out of the mapname, but inho having a possibility to choose the theme would be even better.
Gracias y Saludos de Suiza
Patrik
Hi,
thanks;
you are right,
added to my 'todo' list,
orux
orux- Cantidad de envíos : 3946
Fecha de inscripción : 2009-07-06
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
Thanks, Orux.
Very much appreciated.
Saludos
Patrik
Very much appreciated.
Saludos
Patrik
keenonkites- Cantidad de envíos : 3
Fecha de inscripción : 2013-03-28
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
Orux,
I know it's a bit 'offtopic' in this topic here as it is not about 'relative' vs 'absolut' but it nevertheless still is about 'installation' of maps and themes:
In Locus there are so called locus_actions.... having either exactly the same (for interopability of maps and installation routines) or at least something similar would be very handy:
http://docs.locusmap.eu/doku.php/manual:locus_actions
Felices Pascuas
Patrik
I know it's a bit 'offtopic' in this topic here as it is not about 'relative' vs 'absolut' but it nevertheless still is about 'installation' of maps and themes:
In Locus there are so called locus_actions.... having either exactly the same (for interopability of maps and installation routines) or at least something similar would be very handy:
http://docs.locusmap.eu/doku.php/manual:locus_actions
Felices Pascuas
Patrik
keenonkites- Cantidad de envíos : 3
Fecha de inscripción : 2013-03-28
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
Relative paths would be really helpful for mapsforge maps. I made my own theme for Oruxmaps and Openandromaps but it doesn't make sense to make it available to others as long as the paths are absolute. And of course a theme switcher would also help :-)
Anyway, the mapsforge support made orux maps so much better (from already the best), now there's just those small details which need refining.
Anyway, the mapsforge support made orux maps so much better (from already the best), now there's just those small details which need refining.
eartrumpet- Cantidad de envíos : 8
Fecha de inscripción : 2013-06-07
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
Yes relative paths would be very helpful in the theme xml file.
Regards
zapfen
Regards
zapfen
zapfen- Cantidad de envíos : 14
Fecha de inscripción : 2012-06-05
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
Indeed!zapfen wrote:Yes relative paths would be very helpful in the theme xml file.
Also it would be nice if themes are easily changeable like offline maps.
bianchifan- Cantidad de envíos : 11
Fecha de inscripción : 2011-11-21
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
Hi;bianchifan wrote:Indeed!zapfen wrote:Yes relative paths would be very helpful in the theme xml file.
Also it would be nice if themes are easily changeable like offline maps.
initial support to multiple themes, last beta--> www.oruxmaps.com/cs
orux
orux- Cantidad de envíos : 3946
Fecha de inscripción : 2009-07-06
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
And it works perfect
No need for clearing the cache when changing themes - simply working.
The openandromaps themes for Orux and Locus now are the same, basicly the installation too, however the directory structure can be optimized for the solution Orux provided (one single /patterns + /symbol folder for all themes together.
No big deal.
Once this is released I will provide the advanced Themes within the downloads of the maps as usual so maps and themes will always have the same version.
Incredible Job ORUX , Thanks a lot !!
Best regards,
Christian
kech61- Cantidad de envíos : 67
Fecha de inscripción : 2012-01-30
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
Thanks, Christiankech61 wrote:And it works perfect
No need for clearing the cache when changing themes - simply working.
The openandromaps themes for Orux and Locus now are the same, basicly the installation too, however the directory structure can be optimized for the solution Orux provided (one single /patterns + /symbol folder for all themes together.
No big deal.
Once this is released I will provide the advanced Themes within the downloads of the maps as usual so maps and themes will always have the same version.
Incredible Job ORUX , Thanks a lot !!
Best regards,
Christian
Yes, you are right, if the patterns/symbols are the same for all the themes, you can put all the .xml together in one folder.
orux
orux- Cantidad de envíos : 3946
Fecha de inscripción : 2009-07-06
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
I'v provided a complete set of the new openandromaps themes with optimized folder structure for download:
www.openandromaps.org/wp-content/files/themes/orux_new/themes_orux_new.zip
Unzip the contents to /oruxmaps/mapstyles/ or a subdirectory like /oruxmaps/mapstyles/OAM/ (don't forget the /patterns /symbols folders) for the switching themes look at the oruxmaps site: http://www.oruxmaps.com/cs/
Its easy, works perfect, enjoy!
kech61- Cantidad de envíos : 67
Fecha de inscripción : 2012-01-30
Re: mapsforge map theme: reference to patterns and symbols only possible with absolute paths
bianchifan- Cantidad de envíos : 11
Fecha de inscripción : 2011-11-21
Similar topics
» The rendering theme of the "Opencyclemap->mapsforge" map
» Symbols in Vectormaps sometimes disappear
» Track database and profile paths
» Anouncement: Vector cycle-maps now available
» Alternative theme not used for settings menu
» Symbols in Vectormaps sometimes disappear
» Track database and profile paths
» Anouncement: Vector cycle-maps now available
» Alternative theme not used for settings menu
Permissions in this forum:
You cannot reply to topics in this forum
|
|