xsl-list
[Top] [All Lists]

RE: [xsl] Testing for upper and lower case

2011-11-03 11:11:57
The regex is defined by XML Schema,
  see <http://www.w3.org/TR/xmlschema-2/#dt-ccescat>

\p{Ll} matches a Unicode lowercase character taking into account diacritics.
\p{lu} matches a Unicode uppercase character taking into account diacritics.
\p{lt} matches a Unicode titlecase character taking into account diacritics.

Hope that helps, Andy.

-----Original Message-----
From: Mark [mailto:mark(_at_)knihtisk(_dot_)org]
Sent: Thursday, November 03, 2011 12:06
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: Re: [xsl] Testing for upper and lower case

Hi Andy,
I don't understand regex, so I could not have composed these
expressions.
Do any of these test only the first letter of a word?
Thanks for your help,
Mark

-----Original Message-----
From: Houghton,Andrew
Sent: Thursday, November 03, 2011 9:00 AM
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: RE: [xsl] Testing for upper and lower case

What's wrong with matches($text, '^\p{Lu}+$') matches uppercase,
matches($text, '^\p{Ll}+$') matches lowercase, matches($text,
'^\p{lu}\p{ll}+$') matches capital case. In the latter case you might
also
be able to use matches($text, '^\p{Lt}+$').

Andy.

-----Original Message-----
From: Mark [mailto:mark(_at_)knihtisk(_dot_)org]
Sent: Thursday, November 03, 2011 11:56
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] Testing for upper and lower case

I was able to find functions that change case [upper-case(), lower-
case()],
but nothing that tested case. Is it possible to determine if the
first
letter of a word is upper or lower case? For instance, differentiate
between
@word="Android" and @word="with" by the case of the words' first
letter
alone?

Thanks,
Mark



--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--




--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--




--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: 
<mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--




--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--