ppannuto / python-titlecase

Python library to capitalize strings as specified by the New York Times Manual of Style
MIT License
244 stars 36 forks source link

Initial words in all caps are sometimes not cased properly #90

Closed rogerl50 closed 1 year ago

rogerl50 commented 1 year ago

titlecase('FOO bar') returns FOO Bar, while titlecase('FOO BAR') returns Foo Bar.

ppannuto commented 1 year ago

This is by design. If a string is all caps (or all lowercase), it is assumed there is no intentional casing and it is titlecased as such. If there is already mixed case and a word is all uppercase, it is assumed that word is an acronym, and it is left unchanged.