Make :first-letter include following punctuation but not first letters that are neither letters nor digits. Bug 399941, r+sr=roc

--HG--
rename : layout/generic/punct_marks.ccmap => layout/generic/punct_marks.x-ccmap
This commit is contained in:
Simon Montagu 2008-07-02 19:28:43 +03:00
parent bcbdbaaa58
commit cdb351e3a9
24 changed files with 768 additions and 40 deletions

View File

@ -58,6 +58,7 @@
#include "nsIScriptGlobalObject.h"
#include "nsIDOMEvent.h"
#include "nsTArray.h"
#include "nsTextFragment.h"
struct nsNativeKeyEvent; // Don't include nsINativeKeyBindings.h here: it will force strange compilation error!
@ -98,6 +99,7 @@ class nsIPref;
class nsVoidArray;
struct JSRuntime;
class nsICaseConversion;
class nsIUGenCategory;
class nsIWidget;
class nsPIDOMWindow;
#ifdef MOZ_XTF
@ -364,10 +366,16 @@ public:
PRBool aTrimTrailing = PR_TRUE);
/**
* Returns true if aChar is of class Ps, Pi, Po, Pf, or Pe. (Does not
* currently handle non-BMP characters.)
* Returns true if aChar is of class Ps, Pi, Po, Pf, or Pe.
*/
static PRBool IsPunctuationMark(PRUnichar aChar);
static PRBool IsPunctuationMark(PRUint32 aChar);
static PRBool IsPunctuationMarkAt(const nsTextFragment* aFrag, PRUint32 aOffset);
/**
* Returns true if aChar is of class Lu, Ll, Lt, Lm, Lo, Nd, Nl or No
*/
static PRBool IsAlphanumeric(PRUint32 aChar);
static PRBool IsAlphanumericAt(const nsTextFragment* aFrag, PRUint32 aOffset);
/*
* Is the character an HTML whitespace character?
@ -577,6 +585,11 @@ public:
return sCaseConv;
}
static nsIUGenCategory* GetGenCat()
{
return sGenCat;
}
/**
* @return PR_TRUE if aContent has an attribute aName in namespace aNameSpaceID,
* and the attribute value is non-empty.
@ -1352,6 +1365,7 @@ private:
static nsILineBreaker* sLineBreaker;
static nsIWordBreaker* sWordBreaker;
static nsICaseConversion* sCaseConv;
static nsIUGenCategory* sGenCat;
// Holds pointers to nsISupports* that should be released at shutdown
static nsVoidArray* sPtrsToPtrsToRelease;

View File

@ -154,6 +154,7 @@ static NS_DEFINE_CID(kXTFServiceCID, NS_XTFSERVICE_CID);
#include "nsGenericHTMLElement.h"
#include "nsAttrValue.h"
#include "nsReferencedElement.h"
#include "nsIUGenCategory.h"
#ifdef IBMBIDI
#include "nsIBidiKeyboard.h"
@ -195,6 +196,7 @@ PRBool nsContentUtils::sTriedToGetContentPolicy = PR_FALSE;
nsILineBreaker *nsContentUtils::sLineBreaker;
nsIWordBreaker *nsContentUtils::sWordBreaker;
nsICaseConversion *nsContentUtils::sCaseConv;
nsIUGenCategory *nsContentUtils::sGenCat;
nsVoidArray *nsContentUtils::sPtrsToPtrsToRelease;
nsIScriptRuntime *nsContentUtils::sScriptRuntimes[NS_STID_ARRAY_UBOUND];
PRInt32 nsContentUtils::sScriptRootCount[NS_STID_ARRAY_UBOUND];
@ -298,6 +300,9 @@ nsContentUtils::Init()
rv = CallGetService(NS_UNICHARUTIL_CONTRACTID, &sCaseConv);
NS_ENSURE_SUCCESS(rv, rv);
rv = CallGetService(NS_UNICHARCATEGORY_CONTRACTID, &sGenCat);
NS_ENSURE_SUCCESS(rv, rv);
// Ignore failure and just don't load images
rv = CallGetService("@mozilla.org/image/loader;1", &sImgLoader);
if (NS_FAILED(rv)) {
@ -676,15 +681,55 @@ nsContentUtils::CopyNewlineNormalizedUnicodeTo(nsReadingIterator<PRUnichar>& aSr
// Updated to fix the regression (bug 263411). The list contains
// characters of the following Unicode character classes : Ps, Pi, Po, Pf, Pe.
// (ref.: http://www.w3.org/TR/2004/CR-CSS21-20040225/selector.html#first-letter)
// Note that the file does NOT yet include non-BMP characters.
#include "punct_marks.ccmap"
DEFINE_CCMAP(gPuncCharsCCMap, const);
#include "punct_marks.x-ccmap"
DEFINE_X_CCMAP(gPuncCharsCCMapExt, const);
// static
PRBool
nsContentUtils::IsPunctuationMark(PRUnichar aChar)
nsContentUtils::IsPunctuationMark(PRUint32 aChar)
{
return CCMAP_HAS_CHAR(gPuncCharsCCMap, aChar);
return CCMAP_HAS_CHAR_EXT(gPuncCharsCCMapExt, aChar);
}
// static
PRBool
nsContentUtils::IsPunctuationMarkAt(const nsTextFragment* aFrag, PRUint32 aOffset)
{
PRUnichar h = aFrag->CharAt(aOffset);
if (!IS_SURROGATE(h)) {
return IsPunctuationMark(h);
}
if (NS_IS_HIGH_SURROGATE(h) && aOffset + 1 < aFrag->GetLength()) {
PRUnichar l = aFrag->CharAt(aOffset + 1);
if (NS_IS_LOW_SURROGATE(l)) {
return IsPunctuationMark(SURROGATE_TO_UCS4(h, l));
}
}
return PR_FALSE;
}
// static
PRBool nsContentUtils::IsAlphanumeric(PRUint32 aChar)
{
nsIUGenCategory::nsUGenCategory cat = sGenCat->Get(aChar);
return (cat == nsIUGenCategory::kLetter || cat == nsIUGenCategory::kNumber);
}
// static
PRBool nsContentUtils::IsAlphanumericAt(const nsTextFragment* aFrag, PRUint32 aOffset)
{
PRUnichar h = aFrag->CharAt(aOffset);
if (!IS_SURROGATE(h)) {
return IsAlphanumeric(h);
}
if (NS_IS_HIGH_SURROGATE(h) && aOffset + 1 < aFrag->GetLength()) {
PRUnichar l = aFrag->CharAt(aOffset + 1);
if (NS_IS_LOW_SURROGATE(l)) {
return IsAlphanumeric(SURROGATE_TO_UCS4(h, l));
}
}
return PR_FALSE;
}
/* static */
@ -802,6 +847,7 @@ nsContentUtils::Shutdown()
NS_IF_RELEASE(sLineBreaker);
NS_IF_RELEASE(sWordBreaker);
NS_IF_RELEASE(sCaseConv);
NS_IF_RELEASE(sGenCat);
#ifdef MOZ_XTF
NS_IF_RELEASE(sXTFService);
#endif

View File

@ -4993,6 +4993,28 @@ nsTextFrame::GetOffsets(PRInt32 &start, PRInt32 &end) const
return NS_OK;
}
static PRInt32
FindEndOfPunctuationRun(const nsTextFragment* aFrag,
gfxTextRun* aTextRun,
gfxSkipCharsIterator* aIter,
PRInt32 aOffset,
PRInt32 aStart,
PRInt32 aEnd)
{
PRInt32 i;
for (i = aStart; i < aEnd - aOffset; ++i) {
if (nsContentUtils::IsPunctuationMarkAt(aFrag, aOffset + i)) {
aIter->SetOriginalOffset(aOffset + i);
FindClusterEnd(aTextRun, aEnd, aIter);
i = aIter->GetOriginalOffset() - aOffset;
} else {
break;
}
}
return i;
}
/**
* Returns PR_TRUE if this text frame completes the first-letter, PR_FALSE
* if it does not contain a true "letter".
@ -5004,7 +5026,7 @@ nsTextFrame::GetOffsets(PRInt32 &start, PRInt32 &end) const
*
* @param aLength an in/out parameter: on entry contains the maximum length to
* return, on exit returns length of the first-letter fragment (which may
* include leading punctuation, for example)
* include leading and trailing punctuation, for example)
*/
static PRBool
FindFirstLetterRange(const nsTextFragment* aFrag,
@ -5012,28 +5034,36 @@ FindFirstLetterRange(const nsTextFragment* aFrag,
PRInt32 aOffset, const gfxSkipCharsIterator& aIter,
PRInt32* aLength)
{
// Find first non-whitespace, non-punctuation cluster, and stop after it
PRInt32 i;
PRInt32 length = *aLength;
for (i = 0; i < length; ++i) {
if (!IsTrimmableSpace(aFrag, aOffset + i) &&
!nsContentUtils::IsPunctuationMark(aFrag->CharAt(aOffset + i)))
break;
}
PRInt32 endOffset = aOffset + length;
gfxSkipCharsIterator iter(aIter);
// skip leading whitespace, then consume clusters that start with punctuation
i = FindEndOfPunctuationRun(aFrag, aTextRun, &iter, aOffset,
GetTrimmableWhitespaceCount(aFrag, aOffset, length, 1),
endOffset);
if (i == length)
return PR_FALSE;
// Advance to the end of the cluster
gfxSkipCharsIterator iter(aIter);
PRInt32 nextClusterStart;
for (nextClusterStart = i + 1; nextClusterStart < length; ++nextClusterStart) {
iter.SetOriginalOffset(aOffset + nextClusterStart);
if (iter.IsOriginalCharSkipped() ||
aTextRun->IsClusterStart(iter.GetSkippedOffset()))
break;
// If the next character is not a letter or number, there is no first-letter.
// Return PR_TRUE so that we don't go on looking, but set aLength to 0.
if (!nsContentUtils::IsAlphanumericAt(aFrag, aOffset + i)) {
*aLength = 0;
return PR_TRUE;
}
*aLength = nextClusterStart;
// consume another cluster (the actual first letter)
iter.SetOriginalOffset(aOffset + i);
FindClusterEnd(aTextRun, endOffset, &iter);
i = iter.GetOriginalOffset() - aOffset;
if (i + 1 == length)
return PR_TRUE;
// consume clusters that start with punctuation
i = FindEndOfPunctuationRun(aFrag, aTextRun, &iter, aOffset, i + 1, endOffset);
if (i < length)
*aLength = i;
return PR_TRUE;
}
@ -5521,8 +5551,10 @@ nsTextFrame::Reflow(nsPresContext* aPresContext,
// Restrict to just the first-letter if necessary
PRBool completedFirstLetter = PR_FALSE;
if (lineLayout.GetFirstLetterStyleOK()) {
AddStateBits(TEXT_FIRST_LETTER);
completedFirstLetter = FindFirstLetterRange(frag, mTextRun, offset, iter, &length);
if (length) {
AddStateBits(TEXT_FIRST_LETTER);
}
}
/////////////////////////////////////////////////////////////////////

View File

@ -52,7 +52,7 @@
In addition, the input file can have the following optional lines that
read
VARIABLE::gPuncCharsCCMap
VARIABLE::gPuncCharsCCMapExt
CLASS::punct_marks
DESCRIPTION:: description of a character class
FILE:: mozilla source file to include the output file
@ -60,10 +60,10 @@
Then, run the following in the current directory.
perl ccmapbin.pl input_file [gPuncCharsCCMap [punct_marks]]
perl ccmapbin.pl input_file [gPuncCharsCCMapExt [punct_marks]]
which will generate punct_marks.ccmap (or punct_marks.x-ccmap if the ccmap
includes non-BMP characters.). gPuncCharsCCMap is used as the prefix
includes non-BMP characters.). gPuncCharsCCMapExt is used as the prefix
in macros for the array initializer and the array size.
(see bug 180266, bug 167136, and bug 224337)
@ -73,15 +73,13 @@
(see bug 263411 for details)
cut -d ';' -f 1-3 UnicodeData-4.0.1.txt | egrep 'Ps|Pe|Po|Pf|Pi' | cut -d ';' -f 1-2 \
| egrep -v '[1-9A-F]{5,}' \
| sed -e 's/;/ : /' -e 's/^/ 0X/'
*/
/*
VARIABLE:: gPuncCharsCCMap
VARIABLE:: gPuncCharsCCMapExt
CLASS:: punct_marks
DESCRIPTION:: Punctuation Marks (Unicode char. classes: Ps, Pe, Po, Pi, Pf)
FILE:: layout/html/base/src/nsTextFrame.cpp
0X000021 : EXCLAMATION MARK
0X000022 : QUOTATION MARK
@ -494,13 +492,31 @@
0X00FF63 : HALFWIDTH RIGHT CORNER BRACKET
0X00FF64 : HALFWIDTH IDEOGRAPHIC COMMA
0X00FF65 : HALFWIDTH KATAKANA MIDDLE DOT
0X010100 : AEGEAN WORD SEPARATOR LINE
0X010101 : AEGEAN WORD SEPARATOR DOT
0X01039F : UGARITIC WORD DIVIDER
0X0103D0 : OLD PERSIAN WORD DIVIDER
0X01091F : PHOENICIAN WORD SEPARATOR
0X010A50 : KHAROSHTHI PUNCTUATION DOT
0X010A51 : KHAROSHTHI PUNCTUATION SMALL CIRCLE
0X010A52 : KHAROSHTHI PUNCTUATION CIRCLE
0X010A53 : KHAROSHTHI PUNCTUATION CRESCENT BAR
0X010A54 : KHAROSHTHI PUNCTUATION MANGALAM
0X010A55 : KHAROSHTHI PUNCTUATION LOTUS
0X010A56 : KHAROSHTHI PUNCTUATION DANDA
0X010A57 : KHAROSHTHI PUNCTUATION DOUBLE DANDA
0X010A58 : KHAROSHTHI PUNCTUATION LINES
0X012470 : CUNEIFORM PUNCTUATION SIGN OLD ASSYRIAN WORD DIVIDER
0X012471 : CUNEIFORM PUNCTUATION SIGN VERTICAL COLON
0X012472 : CUNEIFORM PUNCTUATION SIGN DIAGONAL COLON
0X012473 : CUNEIFORM PUNCTUATION SIGN DIAGONAL TRICOLON
*/
#if (defined(IS_LITTLE_ENDIAN) || ALU_SIZE == 16)
// Precompiled CCMap for Little Endian(16/32/64bit)
// and Big Endian(16bit)
#define gPuncCharsCCMap_SIZE 592
#define gPuncCharsCCMap_INITIALIZER \
#if (defined(IS_LITTLE_ENDIAN) && ALU_SIZE == 64)
// Precompiled CCMap for Little Endian(64bit)
#define gPuncCharsCCMapExt_SIZE 804
#define gPuncCharsCCMapExt_INITIALIZER \
/* EXTFLG */ 0x0001,0x0000,0x0250,0x0000, \
/* 000000 */ 0x0030,0x00D0,0x0160,0x01D0,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x01F0,0x0010,0x0010,0x0010,0x0010,0x0210, \
/* 000010 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
@ -574,11 +590,248 @@
/* 000230 */ 0x0000,0x03FF,0x0000,0xFFE1,0x1FFF,0xFEF7,0x0D03,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000240 */ 0xD7EE,0x8C00,0x0001,0x3800,0x0000,0xA800,0x003F,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000250 */ 0x0280,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000, \
0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000, \
/* 000260 */ 0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000, \
0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000, \
/* 000270 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000280 */ 0x0030,0x0010,0x0080,0x0010,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010, \
/* 000290 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002a0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002b0 */ 0x0020,0x0040,0x0020,0x0050,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0060,0x0070,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002c0 */ 0x0003,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002d0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x8000,0x0000,0x0000,0x0000,0x0001,0x0000,0x0000, \
/* 0002e0 */ 0x0000,0x8000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002f0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x01FF,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000300 */ 0x0020,0x0020,0x0020,0x0020,0x0090,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 000310 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x000F, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
#elif defined(IS_LITTLE_ENDIAN)
// Precompiled CCMap for Little Endian(16/32bit)
#define gPuncCharsCCMapExt_SIZE 802
#define gPuncCharsCCMapExt_INITIALIZER \
/* EXTFLG */ 0x0001,0x0250, \
/* 000000 */ 0x0030,0x00D0,0x0160,0x01D0,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x01F0,0x0010,0x0010,0x0010,0x0010,0x0210, \
/* 000010 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 000020 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000030 */ 0x0040,0x0020,0x0020,0x0050,0x0020,0x0060,0x0070,0x0080, \
0x0020,0x0090,0x0020,0x0020,0x0020,0x00A0,0x00B0,0x00C0, \
/* 000040 */ 0x0000,0x0000,0xD7EE,0x8C00,0x0001,0x3800,0x0000,0x2800, \
0x0000,0x0000,0x0802,0x8880,0x0000,0x0000,0x0000,0x0000, \
/* 000050 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x4000, \
0x0080,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000060 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0xFC00,0x0000,0x0000, \
0x0200,0x0000,0x0000,0x4000,0x0049,0x0000,0x0000,0x0018, \
/* 000070 */ 0x3000,0xC800,0x0000,0x0000,0x0000,0x0000,0x3C00,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0010,0x0000,0x0000, \
/* 000080 */ 0x3FFF,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0380, \
/* 000090 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0030,0x0001, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0000a0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0010, \
/* 0000b0 */ 0x0000,0x0000,0x0000,0x0000,0x8000,0x0C00,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0000c0 */ 0xFFF0,0x0007,0x0000,0x3C00,0x0000,0x0000,0x0000,0x0000, \
0x0020,0x0000,0x0000,0x0000,0x0000,0x0003,0x0000,0x0000, \
/* 0000d0 */ 0x00E0,0x0020,0x0020,0x00F0,0x0020,0x0020,0x0100,0x0110, \
0x0120,0x0130,0x0140,0x0150,0x0020,0x0020,0x0020,0x0020, \
/* 0000e0 */ 0x0000,0x0000,0x0000,0x0000,0xFC00,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0800, \
/* 0000f0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x01FE,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000100 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6000,0x0000, \
0x0000,0x1800,0x0000,0x0000,0x0000,0x0000,0x3800,0x0000, \
/* 000110 */ 0x0000,0x0000,0x0000,0x0060,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0770,0x0000,0x0000, \
/* 000120 */ 0x07BF,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000130 */ 0x0000,0x0000,0x0000,0x0000,0x0030,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0xC000,0x0000,0x0000, \
/* 000140 */ 0x0000,0xC000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000150 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0xFC00,0x0001,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000160 */ 0x0170,0x0020,0x0020,0x0180,0x0020,0x0020,0x0020,0x0190, \
0x0020,0x01A0,0x0020,0x0020,0x01B0,0x0020,0x01C0,0x0020, \
/* 000170 */ 0x0000,0xFFC0,0x00FF,0x7FFF,0xFFEE,0x7FEB,0x0000,0x6000, \
0x6000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000180 */ 0x0000,0x0000,0x0600,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000190 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xFF00,0x003F, \
0x0000,0x0000,0x0000,0x0000,0x0060,0x0000,0x0FC0,0x0000, \
/* 0001a0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0xFFF8,0x01FF,0x0000,0x0000,0x0000,0x0F00,0x0000,0x3000, \
/* 0001b0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xDE00, \
/* 0001c0 */ 0xFFFF,0x307F,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0001d0 */ 0x01E0,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0001e0 */ 0xFF0E,0xEFF3,0x0000,0x2000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0800, \
/* 0001f0 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0200,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 000200 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x00F0, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000210 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0220,0x0230,0x0240, \
/* 000220 */ 0x0000,0x0000,0x0000,0xC000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000230 */ 0x0000,0x03FF,0x0000,0xFFE1,0x1FFF,0xFEF7,0x0D03,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000240 */ 0xD7EE,0x8C00,0x0001,0x3800,0x0000,0xA800,0x003F,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000250 */ 0x0280,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000, \
0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000, \
/* 000260 */ 0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000, \
0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000, \
/* 000270 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000280 */ 0x0030,0x0010,0x0080,0x0010,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010, \
/* 000290 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002a0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002b0 */ 0x0020,0x0040,0x0020,0x0050,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0060,0x0070,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002c0 */ 0x0003,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002d0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x8000,0x0000,0x0000,0x0000,0x0001,0x0000,0x0000, \
/* 0002e0 */ 0x0000,0x8000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002f0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x01FF,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000300 */ 0x0020,0x0020,0x0020,0x0020,0x0090,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 000310 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x000F, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
#elif (ALU_SIZE == 16)
// Precompiled CCMap for Big Endian(16bit)
#define gPuncCharsCCMapExt_SIZE 802
#define gPuncCharsCCMapExt_INITIALIZER \
/* EXTFLG */ 0x0001,0x0250, \
/* 000000 */ 0x0030,0x00D0,0x0160,0x01D0,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x01F0,0x0010,0x0010,0x0010,0x0010,0x0210, \
/* 000010 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 000020 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000030 */ 0x0040,0x0020,0x0020,0x0050,0x0020,0x0060,0x0070,0x0080, \
0x0020,0x0090,0x0020,0x0020,0x0020,0x00A0,0x00B0,0x00C0, \
/* 000040 */ 0x0000,0x0000,0xD7EE,0x8C00,0x0001,0x3800,0x0000,0x2800, \
0x0000,0x0000,0x0802,0x8880,0x0000,0x0000,0x0000,0x0000, \
/* 000050 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x4000, \
0x0080,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000060 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0xFC00,0x0000,0x0000, \
0x0200,0x0000,0x0000,0x4000,0x0049,0x0000,0x0000,0x0018, \
/* 000070 */ 0x3000,0xC800,0x0000,0x0000,0x0000,0x0000,0x3C00,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0010,0x0000,0x0000, \
/* 000080 */ 0x3FFF,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0380, \
/* 000090 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0030,0x0001, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0000a0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0010, \
/* 0000b0 */ 0x0000,0x0000,0x0000,0x0000,0x8000,0x0C00,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0000c0 */ 0xFFF0,0x0007,0x0000,0x3C00,0x0000,0x0000,0x0000,0x0000, \
0x0020,0x0000,0x0000,0x0000,0x0000,0x0003,0x0000,0x0000, \
/* 0000d0 */ 0x00E0,0x0020,0x0020,0x00F0,0x0020,0x0020,0x0100,0x0110, \
0x0120,0x0130,0x0140,0x0150,0x0020,0x0020,0x0020,0x0020, \
/* 0000e0 */ 0x0000,0x0000,0x0000,0x0000,0xFC00,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0800, \
/* 0000f0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x01FE,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000100 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x6000,0x0000, \
0x0000,0x1800,0x0000,0x0000,0x0000,0x0000,0x3800,0x0000, \
/* 000110 */ 0x0000,0x0000,0x0000,0x0060,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0770,0x0000,0x0000, \
/* 000120 */ 0x07BF,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000130 */ 0x0000,0x0000,0x0000,0x0000,0x0030,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0xC000,0x0000,0x0000, \
/* 000140 */ 0x0000,0xC000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000150 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0xFC00,0x0001,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000160 */ 0x0170,0x0020,0x0020,0x0180,0x0020,0x0020,0x0020,0x0190, \
0x0020,0x01A0,0x0020,0x0020,0x01B0,0x0020,0x01C0,0x0020, \
/* 000170 */ 0x0000,0xFFC0,0x00FF,0x7FFF,0xFFEE,0x7FEB,0x0000,0x6000, \
0x6000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000180 */ 0x0000,0x0000,0x0600,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000190 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xFF00,0x003F, \
0x0000,0x0000,0x0000,0x0000,0x0060,0x0000,0x0FC0,0x0000, \
/* 0001a0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0xFFF8,0x01FF,0x0000,0x0000,0x0000,0x0F00,0x0000,0x3000, \
/* 0001b0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0xDE00, \
/* 0001c0 */ 0xFFFF,0x307F,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0001d0 */ 0x01E0,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0001e0 */ 0xFF0E,0xEFF3,0x0000,0x2000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0800, \
/* 0001f0 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0200,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 000200 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x00F0, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000210 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0220,0x0230,0x0240, \
/* 000220 */ 0x0000,0x0000,0x0000,0xC000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000230 */ 0x0000,0x03FF,0x0000,0xFFE1,0x1FFF,0xFEF7,0x0D03,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000240 */ 0xD7EE,0x8C00,0x0001,0x3800,0x0000,0xA800,0x003F,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000250 */ 0x0000,0x0280,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
/* 000260 */ 0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
/* 000270 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000280 */ 0x0030,0x0010,0x0080,0x0010,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010, \
/* 000290 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002a0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002b0 */ 0x0020,0x0040,0x0020,0x0050,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0060,0x0070,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002c0 */ 0x0003,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002d0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x8000,0x0000,0x0000,0x0000,0x0001,0x0000,0x0000, \
/* 0002e0 */ 0x0000,0x8000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002f0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x01FF,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000300 */ 0x0020,0x0020,0x0020,0x0020,0x0090,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 000310 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x000F, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
#elif (ALU_SIZE == 32)
// Precompiled CCMap for Big Endian(32bit)
#define gPuncCharsCCMap_SIZE 592
#define gPuncCharsCCMap_INITIALIZER \
#define gPuncCharsCCMapExt_SIZE 802
#define gPuncCharsCCMapExt_INITIALIZER \
/* EXTFLG */ 0x0001,0x0250, \
/* 000000 */ 0x0030,0x00D0,0x0160,0x01D0,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x01F0,0x0010,0x0010,0x0010,0x0010,0x0210, \
/* 000010 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
@ -652,11 +905,38 @@
/* 000230 */ 0x03FF,0x0000,0xFFE1,0x0000,0xFEF7,0x1FFF,0x0000,0x0D03, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000240 */ 0x8C00,0xD7EE,0x3800,0x0001,0xA800,0x0000,0x0000,0x003F, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000250 */ 0x0000,0x0280,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
/* 000260 */ 0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
/* 000270 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000280 */ 0x0030,0x0010,0x0080,0x0010,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010, \
/* 000290 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002a0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002b0 */ 0x0020,0x0040,0x0020,0x0050,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0060,0x0070,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002c0 */ 0x0000,0x0003,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002d0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x8000,0x0000,0x0000,0x0000,0x0001,0x0000,0x0000,0x0000, \
/* 0002e0 */ 0x8000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002f0 */ 0x0000,0x0000,0x0000,0x0000,0x01FF,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000300 */ 0x0020,0x0020,0x0020,0x0020,0x0090,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 000310 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x000F,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
#elif (ALU_SIZE == 64)
// Precompiled CCMap for Big Endian(64bit)
#define gPuncCharsCCMap_SIZE 592
#define gPuncCharsCCMap_INITIALIZER \
#define gPuncCharsCCMapExt_SIZE 804
#define gPuncCharsCCMapExt_INITIALIZER \
/* EXTFLG */ 0x0000,0x0001,0x0000,0x0250, \
/* 000000 */ 0x0030,0x00D0,0x0160,0x01D0,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x01F0,0x0010,0x0010,0x0010,0x0010,0x0210, \
/* 000010 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
@ -730,6 +1010,32 @@
/* 000230 */ 0xFFE1,0x0000,0x03FF,0x0000,0x0000,0x0D03,0xFEF7,0x1FFF, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000240 */ 0x3800,0x0001,0x8C00,0xD7EE,0x0000,0x003F,0xA800,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000250 */ 0x0000,0x0280,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
/* 000260 */ 0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
0x0000,0x0270,0x0000,0x0270,0x0000,0x0270,0x0000,0x0270, \
/* 000270 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000280 */ 0x0030,0x0010,0x0080,0x0010,0x0010,0x0010,0x0010,0x0010, \
0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010,0x0010, \
/* 000290 */ 0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002a0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002b0 */ 0x0020,0x0040,0x0020,0x0050,0x0020,0x0020,0x0020,0x0020, \
0x0020,0x0060,0x0070,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 0002c0 */ 0x0000,0x0000,0x0000,0x0003,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002d0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x8000,0x0000,0x0000,0x0000,0x0001,0x0000, \
/* 0002e0 */ 0x0000,0x0000,0x8000,0x0000,0x0000,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 0002f0 */ 0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x01FF,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000, \
/* 000300 */ 0x0020,0x0020,0x0020,0x0020,0x0090,0x0020,0x0020,0x0020, \
0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020,0x0020, \
/* 000310 */ 0x0000,0x0000,0x0000,0x0000,0x000F,0x0000,0x0000,0x0000, \
0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,0x0000,
#else
#error "We don't support this architecture."

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
span.fake-first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Leading and trailing punctuation should all be included -->
<p><span class="fake-first-letter">"I!,"</span> said the Fly,</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
p:first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Leading and trailing punctuation should all be included -->
<p>"I!," said the Fly,</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
span.fake-first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Punctuation in class Pc should not be included: there is no first-letter here -->
<p>_I_, said the Fly,</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
p:first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Punctuation in class Pc should not be included: there is no first-letter here -->
<p>_I_, said the Fly,</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
span.fake-first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Test non-ASCII punctuation -->
<p><span class="fake-first-letter">¿C</span>ómo está usted?</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
p:first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Test non-ASCII punctuation -->
<p>¿Cómo está usted?</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
span.fake-first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Test 16-bit punctuation -->
<p><span class="fake-first-letter">&#x201c;I!,&#x201d;</span> said the Fly,</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
p:first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Test 16-bit punctuation -->
<p>&#x201c;I!,&#x201d; said the Fly,</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
span.fake-first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- If there is whitespace between the punctuation and the first letter, there is no first-letter -->
<p>"*" is an asterix</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
p:first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- If there is whitespace between the punctuation and the first letter, there is no first-letter -->
<p>"*" is an asterix</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
span.fake-first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- :first-letter applies to digits (and following punctuation) -->
<p><span class="fake-first-letter">2,</span>000 miles</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
p:first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- :first-letter applies to digits (and following punctuation) -->
<p>2,000 miles</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
span.fake-first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- :first-letter doesn't apply to symbols -->
<p>$64,000</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
p:first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- :first-letter doesn't apply to symbols -->
<p>$64,000</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
span.fake-first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Test SMP characters -->
<p><span class="fake-first-letter">&#x10900;</span>&#x10901;&#x10909; is Phoenician</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
p:first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Test SMP characters -->
<p>&#x10900;&#x10901;&#x10909; is Phoenician</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
span.fake-first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Test SMP characters and punctuation -->
<p><span class="fake-first-letter">&#x12470;&#x12000;&#x12470;</span>&#x12041; is cuneiform with punctuation</p>
</body>
</html>

View File

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Test case for bug 399941.html</title>
<style type="text/css">
p:first-letter {
color: lime;
background-color: olive;
}
</style>
</head>
<body>
<!-- Test SMP characters and punctuation -->
<p>&#x12470;&#x12000;&#x12470;&#x12041; is cuneiform with punctuation</p>
</body>
</html>

View File

@ -0,0 +1,14 @@
<!DOCTYPE html>
<html>
<head>
<style>
div { color: black; }
div::first-letter { color: green; }
</style>
</head>
<body>
<div>
<span>T</span>his is text
</div>
</body>
</html>

View File

@ -12,6 +12,7 @@
== nested-1d.html nested-1-ref.html
== nested-1e.html nested-1-ref.html
== nested-1f.html nested-1-ref.html
== nested-1g.html nested-1-ref.html
== quote-1a.html quote-1-ref.html
fails == quote-1b.html quote-1-ref.html
fails == quote-1c.html quote-1-ref.html
@ -33,3 +34,12 @@ random-if(MOZ_WIDGET_TOOLKIT=="gtk2") == 329069-1.html 329069-1-ref.html # failu
== 229764-2.html 229764-ref.html
== 342120-1.xhtml 342120-1-ref.xhtml
== 379799-1.html 379799-1-ref.html
== 399941-1.html 399941-1-ref.html
== 399941-2.html 399941-2-ref.html
== 399941-3.html 399941-3-ref.html
== 399941-4.html 399941-4-ref.html
== 399941-5.html 399941-5-ref.html
== 399941-6.html 399941-6-ref.html
== 399941-7.html 399941-7-ref.html
== 399941-8.html 399941-8-ref.html
== 399941-9.html 399941-9-ref.html