Opened 8 years ago

Last modified 8 years ago

#12282 closed enhancement

Remove XML mappaint support — at Version 16

Reported by: Don-vip Owned by: team
Priority: normal Milestone: 16.04
Component: Core mappaint Version:
Keywords: xml mapcss Cc: bastiK, Klumbumbus, simon04, yopaseopor, lists@…

Description (last modified by Don-vip)

We have today 81 styles listed on styles.

Only 7 of them are still in XML format. I propose to rewrite them in MapCSS and drop support for old XML styles:

  1. https://github.com/avar/osmis-josm-style/blob/master/elemstyles_is.xml ==> to rewrite
  2. http://www.freietonne.de/ft_icons/josm/FreieTonne_rules_presets_zip.php ==> To rewrite
  3. Styles/FrenchEPCI ==> Converted
  4. Styles/LegacyStandard ==> to remove from list
  5. Styles/Lit ==> to rewrite
  6. Styles/MaxspeedIcons ==> to drop (integrated in core)
  7. Styles/Traffic_signs ==> Converted

I don't remember how we switched from XML to MapCSS: is there a transformation script somewhere? All styles are quite small except traffic signs...

Change History (16)

comment:1 by stoecker, 8 years ago

For FreieTonne: I wonder that Jan should not react. Are you sure he got the mail? Dropping that style without informing him is not ok I think. Did you also try the email from here: http://www.jesse.de/HTML/impressum.shtml ?

comment:2 by stoecker, 8 years ago

I'll try to send him an mail.

comment:3 by yopaseopor, 8 years ago

Well, I understand JOSM has to be improved...but removing capabilities? You say ok, rewrite it. It is not easy for me (I will have to investigate if it is possible to me) . I don't know anything about programming or codes, I have only learned to open something and If I understand how it works I can change it and improve it. I did the style traffic signs tweaking Speedlimit Signs code from Martin Koppenhoefer. The style is good, it works...Now you tell me I have to change it, "translate the code" ...but How? Can you help me? Can you give me some examples to understand how MapCSS works? Can you make some lines of code of my style to rewrite the whole style? How I have to change the code? Anybody can help me? I have dedicated a lot of hours to make it possible. Can you help me?

Last edited 8 years ago by yopaseopor (previous) (diff)

in reply to:  description ; comment:4 by bastiK, 8 years ago

Replying to Don-vip:

I propose to rewrite them in MapCSS and drop support for old XML styles

I'm not as eager to get rid of the xml format, but I see no reason to keep it, either.

I don't remember how we switched from XML to MapCSS: is there a transformation script somewhere?

Wasn't very sophisticated, I don't think I have saved anything.

in reply to:  4 comment:5 by yopaseopor, 8 years ago

Replying to bastiK:

Replying to Don-vip:

I propose to rewrite them in MapCSS and drop support for old XML styles

I'm not as eager to get rid of the xml format, but I see no reason to keep it, either.

I see one powerful reason: I don't know how to change my style so my style won't work without XML support :(

in reply to:  2 ; comment:6 by stoecker, 8 years ago

Replying to stoecker:

I'll try to send him an mail.

Vincent: Jan answered immediately. Also for the preset I don't understand the error - The URL which is told as error is not in the presets file. Did you maybe mix something here?

in reply to:  3 ; comment:7 by bastiK, 8 years ago

Replying to yopaseopor:

Well, I understand JOSM has to be improved...but removing capabilities? You say ok, rewrite it. It is not easy for me (I will have to investigate if it is possible to me) . I don't know anything about programming or codes, I have only learned to open something and If I understand how it works I can change it and improve it. I did the style traffic signs tweaking Speedlimit Signs code from Martin Koppenhoefer. The style is good, it works...Now you tell me I have to change it, "translate the code" ...but How? Can you help me? Can you give me some examples to understand how MapCSS works? Can you make some lines of code of my style to rewrite the whole style? How I have to change the code? Anybody can help me? I have dedicated a lot of hours to make it possible. Can you help me?

Please don't panic! :)

You don't have to be a programmer, to understand MapCSS. Especially for your Traffic sign style it shouldn't be too hard: Have a look at the first example in the tutorial (And maybe some other available styles). If you cannot get it to work, we will help!

Sorry for the inconvenience, but sometimes this happens in the open source world...

in reply to:  7 ; comment:8 by yopaseopor, 8 years ago

Replying to bastiK:

Please don't panic! :)

You don't have to be a programmer, to understand MapCSS. Especially for your Traffic sign style it shouldn't be too hard: Have a look at the first example in the tutorial (And maybe some other available styles). If you cannot get it to work, we will help!

I panic because first thing I have done before write these lines is open some MapCSS style and I did not understand anything. Also I have opened https://josm.openstreetmap.de/wiki/Help/Styles/MapCSSTutorial and https://josm.openstreetmap.de/wiki/Help/Styles/MapCSSImplementation and I don't understand how it works . I am so worried. Please help me.

Last edited 8 years ago by yopaseopor (previous) (diff)

in reply to:  6 ; comment:9 by Don-vip, 8 years ago

Description: modified (diff)

Replying to stoecker:

Replying to stoecker:

I'll try to send him an mail.

Vincent: Jan answered immediately.

I don't know who Jan is. I sent an e-mail on 24/10/2015 to fta at freietonne.de (which is the only contact listed on https://www.freietonne.de home page) and nobody answered. I also sent an e-mail about this (same day) on josm-dev and nobody replied neither.

Also for the preset I don't understand the error - The URL which is told as error is not in the presets file. Did you maybe mix something here?

You're right. The presets have been modified on 2015-10-27, 3 days after my e-mail, but I wasn't notified. I'm going to restore it, that's good news :)

in reply to:  8 ; comment:10 by Don-vip, 8 years ago

Replying to yopaseopor:

I am so worried. Please help me.

Don't worry, we're going to help you :) Don't want to loose any active contributor with this change, and you do great work! It seems complicated at first glance but you don't need to understand all features. The basic features are quite simple and the resulting file is easier to update once you know the syntax. Also, it's far more powerful, maybe you will have new ideas for the style after :)

in reply to:  10 comment:11 by yopaseopor, 8 years ago

Replying to Don-vip:

Replying to yopaseopor:

I am so worried. Please help me.

Don't worry, we're going to help you :) Don't want to loose any active contributor with this change, and you do great work! It seems complicated at first glance but you don't need to understand all features. The basic features are quite simple and the resulting file is easier to update once you know the syntax. Also, it's far more powerful, maybe you will have new ideas for the style after :)

One Catalan Community member is helping me in this moment.I hope I can translate it in a few time. For things he explains me it is true it seems more powerful and I start thinking new ideas for some items...Thank your for your attention.

comment:12 by Don-vip, 8 years ago

Description: modified (diff)

First conversion example: FrenchEPCI

comment:13 by Don-vip, 8 years ago

I have some problems to get identical rendering with Styles/Lit for this rule:

  <rule>
    <condition k="lit" b="no"/>
    <linemod mode="over" width="10" realwidth="8" colour="lit_no#000000B0"/>
  </rule>

I came up with the following:

meta {
    title: "Lit";
    version: "2.0";
    description: "Show lit=yes/no settings in JOSM map display";
    author: "cmuelle8";
    link: "https://josm.openstreetmap.de/wiki/Styles/Lit";
}
way[lit=yes]::lit_layer
{
    object-z-index: +1.0;
    width: +10;
    opacity: 0.75;
    color: #EEEECC;
}
way[lit=no]::lit_layer
{
    object-z-index: +1.0;
    width: +10;
    opacity: 0.75;
    color: #000000;
}

Original XML style darkens the ways with lit=no, I can't get the same result with MapCSS, any hint?

in reply to:  9 comment:14 by stoecker, 8 years ago

Vincent: Jan answered immediately.

I don't know who Jan is. I sent an e-mail on 24/10/2015 to fta at freietonne.de (which is the only contact listed on https://www.freietonne.de home page) and nobody answered. I also sent an e-mail about this (same day) on josm-dev and nobody replied neither.

Jan Jesse - the operator of Freie Tonne. Seems he has a major mail misconfiguration, as sending mail to that address does not work :-)

Also for the preset I don't understand the error - The URL which is told as error is not in the presets file. Did you maybe mix something here?

You're right. The presets have been modified on 2015-10-27, 3 days after my e-mail, but I wasn't notified. I'm going to restore it, that's good news :)

That line-dance URL very likely never was part of the preset. I assume an mixup in the checkscript. Anyway I told him about some double entries in the preset which should be fixed. He'll also have a look at MapCSS.

comment:15 by yopaseopor, 8 years ago

Help me please, I did the conversion work, but there is some error that makes wrong all the style. Check it please .
https://josm.openstreetmap.de/wiki/Styles/Traffic_signs

comment:16 by Don-vip, 8 years ago

Description: modified (diff)
Note: See TracTickets for help on using tickets.