drawshield / Drawshield-Code

PHP code to create SVG shield images from Blazons, as used on drawshield.net
https://drawshield.net
GNU General Public License v3.0
50 stars 17 forks source link

Complex quartering doesn't recognise `twelfth` verbatim, and anything over `fifteenth` at all #635

Closed 5ucur closed 1 year ago

5ucur commented 1 year ago

The word twelfth is not recognised or highlighted at all, but twelth works.

Meanwhile, sixteenth is highlighted, but the site reports the following error and the shield does not update. The similar happens for higher numbers in ordinal words, except sixteenth is the last one to get highlighted, and the error is a little different.

Unknown word (Sixteenth)  at 4:1-4:9 Not able to process: Or , Seventeenth Gules  (4:11-5:17) 

The blazon I used to produce that error is as follows.

Quartered of 16,
Seventh Argent,
Twelth Azure,
Sixteenth Or,
Seventeenth Gules

Without the Seventeenth Gules line, the error is as follows. EDIT: I have no idea why I left that as Quartered of 16 [...] Seventeenth Gules... I think I wanted to write Quartered of a higher number.

Unknown word (Sixteenth)  at 4:1-4:9 Not able to process: Or  (4:11-4:12) 

It works normally when using any other counting method.

karlwilcox commented 1 year ago

I've fixed the spelling errors in the parser.

The highlighting is done separately by the CodeMirror javascript library config file - again, I've fixed the spellings, but as you have noticed I've only included the first 16 names in the highlight list as the higher numbers are rarely used.