Subject: RE: [xsl] Capitalizing content of a variable From: Joerg Pietschmann <joerg.pietschmann@xxxxxx> Date: Thu, 09 Aug 2001 13:59:54 +0200 |
Tony Graham <Tony.Graham@xxxxxxxxxxxxxxx> wrote: > Joerg Pietschmann wrote at 9 Aug 2001 10:29:54 +0200: > > You may also include non-ASCII characters in the translation string, if > > necessary. The following can be used to upcase german umlauts: > > <xsl:variable name="lower" select="'äöü'"/> > > <xsl:variable name="upper" select="'ÄÖÜ'"/> > > Yes, but that's not going to work for ß, LATIN SMALL LETTER SHARP > S, which has an uppercase mapping to 'SS', is it? > > The other classic case is 'i', which has an uppercase mapping to > İ in Turkish and Azeri only. > We should be grateful that there are simple solutions at least for *some* parts of the problem space. :-) But as you brought up the point: AFAIK both "MASSE" and "MASZE" are valid uppercase versions for "Maße", because the former is ambiguous, legal texts prefer the latter. So upcasing (<-- is this already a legal word?) strings may depend on a wider context. Fortunately, because ß (=ß) must not be the first character of a word, this is irrelevant for capitalisations. Furthermore, translate() is not strictly intended to handle localised string manipulations, the standard developers may claim abuse :-) I have to say that it is surprisingly hard to get comprehensive, precisely worded standards for localised, language dependend string processing. The Unicode Standard goes a long way to provide definitions of categories to think in, but such stuff as what is applicable for a certain language such as character set, concepts of character case, case transformations, collation rules and the like appears to be spread across a lot of paper. My edition of the "Duden" has rather ambiguous formulations, and it does not even mention the DIN-Standards regulating these details for the german language. Apart from this, swiss regulations differ in minor but important details, most notably there is no ß in swiss german, which makes your first problem irrelevant to me. If you have some good sources, I'd be quite interested in hearing about them. Regards J.Pietschmann XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Capitalizing content of a, Michael Beddow | Thread | RE: [xsl] Capitalizing content of a, Michael Kay |
[xsl] Re: [xsl] Re: Réf.[2]_:_Réf.[, Goetz Bock | Date | [xsl] Calculate mantissa and expone, Mitchell, Edmund |
Month |