Skip to content

Update locale attribute names for Diplomat locale-based labels#757

Open
Rub21 wants to merge 8 commits into
stagingfrom
1257_localized
Open

Update locale attribute names for Diplomat locale-based labels#757
Rub21 wants to merge 8 commits into
stagingfrom
1257_localized

Conversation

@Rub21
Copy link
Copy Markdown
Member

@Rub21 Rub21 commented May 6, 2026

I made some changes that require an imposm re-import, so I am considering to solve those issues in this PR:

Comment thread images/tiler-server-martin/scripts/generate_functions.py Outdated
'NULL::double precision AS min_height',
'NULL::double precision AS building_height',
'NULL::double precision AS roof_height',
'NULL::text AS building_min_level',
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

building:min_level=* is also an integer.

ARRAY[
'NULL::double precision AS height',
'NULL::double precision AS min_height',
'NULL::double precision AS building_height',
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

building:height=* is deprecated in favor of height=*. I just eliminated the last occurrence in the database.

result := ft * 0.3048;
-- meters (default or explicit): 20 / 20.5 / 20 m / 20m / 20 meters
ELSIF s ~* '^-?\d+(\.\d+)?\s*(m|meter|meters)?$' THEN
m := regexp_replace(s, '\s*(m|meter|meters)\s*$', '', 'i');
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The meter and meters symbols are discouraged. We only had one occurrence, which I’ve eliminated.

result := (ft * 0.3048) + (inch * 0.0254);
-- feet with ft suffix: 85ft / 85 ft / 85.5 ft
ELSIF s ~* '^\d+(\.\d+)?\s*ft$' THEN
ft := regexp_replace(s, '\s*ft$', '', 'i')::numeric;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unit symbols are case-sensitive.

result := (ft * 0.3048) + (inch * 0.0254);
-- feet with ft suffix: 85ft / 85 ft / 85.5 ft
ELSIF s ~* '^\d+(\.\d+)?\s*ft$' THEN
ft := regexp_replace(s, '\s*ft$', '', 'i')::numeric;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The documentation discourages ft, and we don’t currently have any occurrences in the database. OSM’s U.S. community has frequently discussed making it acceptable again, but for now, 8' is much more common. If we support it, we should probably support 8 ft 5 in too.

Comment on lines +79 to +83
{
"type": "string",
"name": "building_part",
"key": "building:part"
},
Copy link
Copy Markdown
Member

@1ec5 1ec5 May 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unlike all the other keys, building:part=* does not require building=*. It represents a different kind of feature. For example, this dome doesn’t appear in the staging tiles. We can include building parts in the buildings layer for convenience, rather than a separate layer as suggested in OpenHistoricalMap/issues#1370, but we’d need a boolean attribute indicating that it’s a building part.

In other tile schemas that expose building parts, a building outline has an attribute that tells the stylesheet not to extrude it in 3D. This attribute would appear on any building=* area that contains building parts or that has the role outline in a building relation. Without this attribute, the extruded building outline would obscure any building parts within it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants