[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Unicode character blocks in strings

Subject: RE: Unicode character blocks in strings
From: tom tom <tomxsllist@xxxxxxxxxxx>
Date: Fri, 29 May 2009 15:25:47 +0100
RE:  Unicode character blocks in strings
My confusion came when I was trying to the value 'IsCJKUnifiedIdeographs' in a
variable and reference this in an attribute value template.

If I store 'IsCJKUnifiedIdeographs' in the variable 'UnicodeCharBlock'
\p{{{$UnicodeCharBlock}}} seems to work.

If I understand you correctly the innermost {} flags the AVT, the outermost
ones are the actual braces required for this expression. Are the middle ones
to process the results of the first AVT within a second AVT?

> Date: Fri, 29 May 2009 07:50:00 -0400
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> From: gkholman@xxxxxxxxxxxxxxxxxxxx
> Subject: RE:  Unicode character blocks in strings
> At 2009-05-29 12:46 +0100, tom tom wrote:
>>I don't understand why the regex \p{{IsCJKUnifiedIdeographs}}
>>contains a double '{}' structure. Why doesn't \p{IsCJKUnifiedIdeographs}
> Because the value of the regex= attribute is an attribute value template.
> In an attribute value template, the single brace is a signal to
> perform a "value-of" instruction with the contents as the value of
> the select= expression.
> Since you need actual brace brackets in the attribute, you need to
> double them up in order to escape the attribute value template parsing.
> This happens a lot when writing XSLT stylesheets that create Ant
> scripts (a very useful design pattern).
> I hope this helps.
> . . . . . . . . . . . . Ken
> --
> XSLT/XSL-FO/XQuery hands-on training - Los Angeles, USA 2009-06-08
> Crane Softwrights Ltd. http://www.CraneSoftwrights.com/s/
> Training tools: Comprehensive interactive XSLT/XPath 1.0/2.0 video
> Video lesson: http://www.youtube.com/watch?v=PrNjJCh7Ppg&fmt=18
> Video overview: http://www.youtube.com/watch?v=VTiodiij6gE&fmt=18
> G. Ken Holman mailto:gkholman@xxxxxxxxxxxxxxxxxxxx
> Male Cancer Awareness Nov'07 http://www.CraneSoftwrights.com/s/bc
> Legal business disclaimers: http://www.CraneSoftwrights.com/legal

Share your photos with Windows Live Photos  Free.

Current Thread


Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
First Name
Last Name
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.