1ec5 / rebusurance

Scalable highway shield image assets for navigation software
Other
12 stars 2 forks source link

State names with 'New' are transposed #13

Open kennykb opened 3 years ago

kennykb commented 3 years ago

The files for New York and New Hampshire shields are transposed as York New and Hampshire New. There appear to be no Jersey New files only because New Jersey has only generic shields defined in Rebusurance. Is this a bug or a misfeature?

1ec5 commented 3 years ago

The files for New York and New Hampshire shields are transposed as York New and Hampshire New.

This is a fun one: PaintCode is designed primarily for code generation, with static image generation as a secondary concern. The asset names are meant to be proper-sounding method names, not just image file names. In one of PaintCode’s output languages, Objective-C, any method that begins with the word “new” (among some other keywords) has special memory management behavior that isn’t appropriate for a drawing method. As a result, PaintCode disallows starting an asset name with “new”.

This is all laughably arcane, especially if you don’t end up using the Objective-C output. (Who does these days?) I actually considered calling the assets “Nueva York”, “Nueva Jersey”, and “Nueva Hampshire” as a workaround that doesn’t look quite as much like a typo. 😈

There appear to be no Jersey New files only because New Jersey has only generic shields defined in Rebusurance.

That’s correct, New Jersey state routes use the “White Ellipse” asset, and New Jersey county routes use the “Blue Pentagon” asset.