civfanatics / CQUI_Community-Edition

Civilization 6 mod - UI enhancements, reduce clicks and manage your empire faster!
MIT License
149 stars 28 forks source link

City renaming changes text to all-caps—whether or not a new name is entered #327

Closed dylansan closed 1 year ago

dylansan commented 2 years ago

Is your feature request related to a problem? Please describe. In the city details panel, clicking the city name allows editing the name to something else. However, simply clicking this field automatically converts the current name to all-caps (internally, or as displayed in notifications and other areas). From what I can tell, once the city name is changed, the original name is returned to the pool of available city names for founding. This can lead to multiple cities with the same name.

I sometimes click the city name by mistake, leading to the name being changed to all-caps. While re-entering the name can restore the correct formatting, this can be annoying when the names contain special characters. Also, I am unsure if this prevents new cities from being founded with that original name.

Describe the solution you'd like My understanding is that the city name is stored internally with capital and lowercase as expected, but in the city view it is displayed using 'small caps'. When editing the name, this displayed value becomes the internal value, causing the change to occur automatically whether or not anything is typed. One solution could be to replace the text with the internal value whenever the user clicks it, so that nothing changes when saved. However, I'm not sure if this would correctly block that city name from the pool used by future cities.

Describe alternatives you've considered If the text box required confirmation before the change were accepted, and could be cancelled instead, it could resolve the issue of accidental clicks.

Additional context A reddit thread with some screenshots of the names appearing in caps.

the-m4a commented 2 years ago

Interesting bug. I'll look into it.