Skip to content

Commit

Permalink
Update mapcss
Browse files Browse the repository at this point in the history
  • Loading branch information
Famlam authored and frodrigo committed Nov 4, 2024
1 parent f3927b8 commit fcf08c5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion plugins/indoor.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def init(self, logger):
self.errors[52] = self.def_class(item = 1300, level = 3, tags = mapcss.list_('indoor', 'geom') + mapcss.list_('fix:survey', 'shop'), title = mapcss.tr('This indoor shop should probably be inside a room'))
self.errors[53] = self.def_class(item = 1300, level = 2, tags = mapcss.list_('indoor', 'geom'), title = mapcss.tr('This indoor room should have a door'))
self.errors[21201] = self.def_class(item = 2120, level = 3, tags = mapcss.list_('indoor', 'geom'), title = mapcss.tr('`{0}` without `{1}` or `{2}`', mapcss._tag_uncapture(capture_tags, '{0.tag}'), mapcss._tag_uncapture(capture_tags, '{1.key}'), mapcss._tag_uncapture(capture_tags, '{2.key}')))
self.errors[21202] = self.def_class(item = 2120, level = 3, tags = mapcss.list_('indoor', 'geom'), title = mapcss.tr('`{0}` without `{1}`', mapcss._tag_uncapture(capture_tags, '{0.tag}'), mapcss._tag_uncapture(capture_tags, '{1.key}')))
self.errors[21202] = self.def_class(item = 2120, level = 3, tags = mapcss.list_('indoor', 'geom'), title = mapcss.tr('`{0}` without `{1}`', mapcss._tag_uncapture(capture_tags, '{0.tag}'), mapcss._tag_uncapture(capture_tags, '{1.key}')), trap = mapcss.tr('For the number of rooms in a facility, use `{0}` instead.', 'rooms=*'))

self.re_2a047336 = re.compile(r'room|corridor|area|level')

Expand Down Expand Up @@ -70,6 +70,7 @@ def node(self, data, tags):
try: match = ((mapcss._tag_capture(capture_tags, 0, tags, 'room')) and (not mapcss._tag_capture(capture_tags, 1, tags, 'indoor')) and (not mapcss._tag_capture(capture_tags, 2, tags, 'buildingpart')))
except mapcss.RuleAbort: pass
if match:
# -osmoseTrap:tr("For the number of rooms in a facility, use `{0}` instead.","rooms=*")
# -osmoseItemClassLevel:"2120/21202:2/3"
# throwWarning:tr("`{0}` without `{1}`","{0.tag}","{1.key}")
# fixAdd:"indoor=room"
Expand Down Expand Up @@ -174,6 +175,7 @@ def way(self, data, tags, nds):
try: match = ((mapcss._tag_capture(capture_tags, 0, tags, 'room')) and (not mapcss._tag_capture(capture_tags, 1, tags, 'indoor')) and (not mapcss._tag_capture(capture_tags, 2, tags, 'buildingpart')))
except mapcss.RuleAbort: pass
if match:
# -osmoseTrap:tr("For the number of rooms in a facility, use `{0}` instead.","rooms=*")
# -osmoseItemClassLevel:"2120/21202:2/3"
# throwWarning:tr("`{0}` without `{1}`","{0.tag}","{1.key}")
# fixAdd:"indoor=room"
Expand Down Expand Up @@ -219,6 +221,7 @@ def relation(self, data, tags, members):
try: match = ((mapcss._tag_capture(capture_tags, 0, tags, 'room')) and (not mapcss._tag_capture(capture_tags, 1, tags, 'indoor')) and (not mapcss._tag_capture(capture_tags, 2, tags, 'buildingpart')))
except mapcss.RuleAbort: pass
if match:
# -osmoseTrap:tr("For the number of rooms in a facility, use `{0}` instead.","rooms=*")
# -osmoseItemClassLevel:"2120/21202:2/3"
# throwWarning:tr("`{0}` without `{1}`","{0.tag}","{1.key}")
# fixAdd:"indoor=room"
Expand Down

0 comments on commit fcf08c5

Please sign in to comment.