Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2010-06-16 18:51:54

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Bug in handling of terms typed in ALL-CAPS

Textile’s default behaviour is to wrap terms typed in capital letters with a <span class="caps">, which in turn allows you to improve readability by adding a small amount of letter spacing – quite a handy feature.

Apparently this breaks though, if you use any other characters than the lower 128 ascii ones:
EXPO is wrapped properly, but EXPÓ only wraps the first three characters omitting the Ó.

Nothing I’ll lose sleep over, but I hadn’t seen it mentioned before.

Offline

#2 2010-06-16 19:04:02

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,446
Website GitHub

Re: Bug in handling of terms typed in ALL-CAPS

Personally I wish it could be turned off completely at times! But I can see why some people find it handy.

Regarding the accented characters, I guess it could be considered a bug. But isn’t there some sort of unwritten rule that words in uppercase generally aren’t given accents? Or is that just in French? (I’m a bit ignorant here, sorry).

I’ll be looking at Textile again very soon to try and track down Issue 61 so if this is deemed a bug I might as well do it while I’m poking around in that area of the code. Anybody have any i18n wisdom to share here?


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Online

#3 2010-06-16 19:14:20

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: Bug in handling of terms typed in ALL-CAPS

It’s not limited to accented characters. From the few tests I’ve just done, it’s triggered by any of the more exotic characters.

It can be very handy especially if you’re dealing with lots of acronyms. But I agree with you, a prefs setting to enable/disable this would be good. It should work consistently though, that is to say, either wrap it all or not.

Offline

#4 2010-06-16 19:18:15

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,446
Website GitHub

Re: Bug in handling of terms typed in ALL-CAPS

masa wrote:

it’s triggered by any of the more exotic characters.

Figures. Probably ASCII-characters only. Let me take a look when I get a chance and see if there’s anything that can be done about it. But the chances are that if it could be done it would have been done by now!


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Online

#5 2010-06-16 19:27:14

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: Bug in handling of terms typed in ALL-CAPS

Bloke wrote:

But the chances are that if it could be done it would have been done by now!

In that case a pref setting like the current Prevent widowed words in article titles would probably be a good compromise.

Offline

Board footer

Powered by FluxBB