2002-12-06 01:40:42 +00:00
|
|
|
# Copyright (c) 2002, International Business Machines Corporation and
|
|
|
|
# others. All Rights Reserved.
|
2002-06-25 17:23:07 +00:00
|
|
|
#
|
|
|
|
# Title Casing Break Rules
|
|
|
|
#
|
|
|
|
|
|
|
|
$CaseIgnorable = [[:Mn:][:Me:][:Cf:][:Lm:][:Sk:] \u0027 \u00AD \u2019];
|
|
|
|
$OtherUpperCase = [\u2160-\u216f \u24b6-\u24cf];
|
|
|
|
$OtherLowerCase = [\u02b0-\u02b8 \u02c0-\u02c1 \u02e0-\u02e4 \u0345\u037a \u2170-\u217f \u24d0-\u24e9];
|
|
|
|
$Cased = [[:Lu:][:Lt:][:Ll:] $OtherUpperCase $OtherLowerCase - $CaseIgnorable];
|
2003-05-20 18:38:41 +00:00
|
|
|
$NotCased = [^ $Cased];
|
2002-06-25 17:23:07 +00:00
|
|
|
|
|
|
|
#
|
|
|
|
# If the iterator starts on a cased item, advance through all adjacent cased items plus
|
2003-05-20 18:38:41 +00:00
|
|
|
# any non-cased stuff, to reach the start of the next (cased) word.
|
2002-06-25 17:23:07 +00:00
|
|
|
#
|
2003-05-20 18:38:41 +00:00
|
|
|
($Cased | $CaseIgnorable)* $NotCased*;
|
2002-06-25 17:23:07 +00:00
|
|
|
|
|
|
|
#
|
|
|
|
# Reverse Rules
|
|
|
|
#
|
2003-05-20 18:38:41 +00:00
|
|
|
!$NotCased* ($Cased | $CaseIgnorable)* $NotCased?;
|
2002-06-25 17:23:07 +00:00
|
|
|
|