Modify

Opened 4 hours ago

#24885 new defect

Mapcss rules don't override previous rules if using layers and combining multiple selectors

Reported by: cyton Owned by: team
Priority: normal Milestone:
Component: Core Version:
Keywords: template_report Cc:

Description

What steps will reproduce the problem?

  1. load the attached mapcss file
  2. load the attached osm file
  3. look at the examples

What is the expected result?

All the elements to the side of the ways are purple.

What happens instead?

At least one side/layer is not affected and remains a different color (orange)

Please provide any additional information below. Attach a screenshot if possible.

Relative:URL: ^/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2026-08-11 15:36:21 +0200 (Tue, 11 Aug 2026)
Revision:19613
Build-Date:2026-08-12 01:30:51
URL:https://josm.openstreetmap.de/svn/trunk

Identification: JOSM/1.5 (19613 en) Linux Freedesktop SDK 25.08 (Flatpak runtime)
Memory Usage: 288 MB / 24576 MB (72 MB allocated, but free)
Java version: 21.0.12.1, Flathub, OpenJDK 64-Bit Server VM
Look and Feel: javax.swing.plaf.metal.MetalLookAndFeel
Screen: :0.0 1600x1200x[Multi depth]@60Hz (scaling 1.00×1.00) :0.1 1920x1080x[Multi depth]@60Hz (scaling 1.00×1.00) :0.2 2560x1440x[Multi depth]@60Hz (scaling 1.00×1.00)
Maximum Screen Size: 2560×1440
Best cursor sizes: 16×16→16×16, 32×32→32×32
Environment variable LANG: en_US.UTF-8
System property file.encoding: UTF-8
System property sun.jnu.encoding: UTF-8
Locale info: en_US
Numbers with default locale: 1234567890 -> 1234567890
Desktop environment: GNOME
VM arguments: [--module-path=/app/share/openjfx/lib, --add-modules=java.scripting,java.sql,javafx.controls,javafx.media,javafx.swing,javafx.web, -Djosm.restart=true, -Djava.net.useSystemProxies=true, --add-exports=java.base/sun.security.action=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED]
Dataset consistency test: No problems found

Map paint styles:
+ ${HOME}/Documents/parking_lanes_custom/bug_layer_class_combined.mapcss

Last errors/warnings:
- 00065.617 E: Skipping to the next rule, because of an error: org.openstreetmap.josm.gui.mappaint.mapcss.parsergen.ParseException: Encountered " "/" "/ "" at line 30, column 3.
- 00065.618 W: Failed to parse Mappaint styles from '${HOME}/Documents/parking_lanes_custom/bug_layer_class_combined.mapcss'. Error was: Reached end of file while parsing
- 00065.618 E: org.openstreetmap.josm.gui.mappaint.mapcss.parsergen.ParseException: Reached end of file while parsing

Attachments (4)

bug_layer_class_combined.mapcss (1.1 KB ) - added by cyton 4 hours ago.
mapcss example
example.osm (2.7 KB ) - added by cyton 4 hours ago.
a few tagged ways, affected by the style
Screenshot from 2026-09-04 13-38-05.png (23.8 KB ) - added by cyton 4 hours ago.
screenshot of current unexpected behaviour
Screenshot from 2026-09-04 13-38-54.png (23.6 KB ) - added by cyton 4 hours ago.
screenshot of what I expected behaviour

Download all attachments as: .zip

Change History (4)

by cyton, 4 hours ago

mapcss example

by cyton, 4 hours ago

Attachment: example.osm added

a few tagged ways, affected by the style

by cyton, 4 hours ago

screenshot of current unexpected behaviour

by cyton, 4 hours ago

screenshot of what I expected behaviour

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain team.
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from team to the specified user.
Next status will be 'needinfo'. The owner will be changed from team to cyton.
as duplicate The resolution will be set to duplicate. Next status will be 'closed'. The specified ticket will be cross-referenced with this ticket.
The owner will be changed from team to anonymous. Next status will be 'assigned'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.