[4/4] dwrite: Support itemization up to codepoint 0x2ff (Latin range)

Nikolay Sivov nsivov at codeweavers.com
Mon Oct 29 07:33:46 CDT 2012


Support itemization up to codepoint 0x2ff (Latin range)
-------------- next part --------------
>From d903a546d69d04387cb66056a8a75e75a4e29900 Mon Sep 17 00:00:00 2001
From: Nikolay Sivov <nsivov at codeweavers.com>
Date: Mon, 29 Oct 2012 11:15:43 -0400
Subject: [PATCH 5/5] Support itemization up to codepoint 0x2ff (Latin range)

---
 dlls/dwrite/analyzer.c       |    9 +++++++++
 dlls/dwrite/tests/analyzer.c |   30 +++++++++++++++++++++++++++++-
 2 files changed, 38 insertions(+), 1 deletion(-)

diff --git a/dlls/dwrite/analyzer.c b/dlls/dwrite/analyzer.c
index 211a84a..095e1ad 100644
--- a/dlls/dwrite/analyzer.c
+++ b/dlls/dwrite/analyzer.c
@@ -29,6 +29,7 @@ WINE_DEFAULT_DEBUG_CHANNEL(dwrite);
 
 enum scriptcode {
     Script_Arabic = 0,
+    Script_C1Controls = 12,
     Script_Latin  = 38,
     Script_Latin_Symb = 77,
     Script_Unknown = (UINT16)-1
@@ -54,6 +55,14 @@ static const struct script_range script_ranges[] = {
     { Script_Latin, 0x61, 0x7a },
     /* ASCII punctuation and symbols, control char DEL: U+007B–U+007F */
     { Script_Latin_Symb, 0x7b, 0x7f },
+    /* C1 Controls: U+0080–U+009F */
+    { Script_C1Controls, 0x80, 0x9f },
+    /* Latin-1 Supplement: U+00A0–U+00FF */
+    /* Latin Extended-A: U+0100–U+017F */
+    /* Latin Extended-B: U+0180–U+024F */
+    /* IPA Extensions: U+0250–U+02AF */
+    /* Spacing Modifier Letters: U+02B0–U+02FF */
+    { Script_Latin, 0xa0, 0x2ff },
     /* Arabic: U+0600–U+06FF */
     { Script_Arabic, 0x600, 0x6ef },
     /* unsuppoted range */
diff --git a/dlls/dwrite/tests/analyzer.c b/dlls/dwrite/tests/analyzer.c
index 440237a..eddea41 100644
--- a/dlls/dwrite/tests/analyzer.c
+++ b/dlls/dwrite/tests/analyzer.c
@@ -398,6 +398,7 @@ struct sa_test {
 
 enum scriptcode {
     Script_Arabic = 0,
+    Script_C1Controls = 12,
     Script_Latin  = 38,
     Script_Latin_Symb = 77
 };
@@ -433,7 +434,7 @@ static struct sa_test sa_tests[] = {
     {
       /* Arabic, Latin */
       {'1','2','3','-','5','2',0x064a,0x064f,0x0633,0x0627,0x0648,0x0650,0x064a,'7','1','.',0}, 1,
-          { { 0, 16, { 0, DWRITE_SCRIPT_SHAPES_DEFAULT } }}
+          { { 0, 16, { Script_Arabic, DWRITE_SCRIPT_SHAPES_DEFAULT } }}
     },
     {
       /* Arabic, English */
@@ -456,6 +457,33 @@ static struct sa_test sa_tests[] = {
             { 7, 4, { Script_Arabic, DWRITE_SCRIPT_SHAPES_DEFAULT } },
           }
     },
+    {
+      /* C1 Controls, Latin-1 Supplement */
+      {0x80,0x90,0x9f,0xa0,0xc0,0xb8,0xbf,0xc0,0xff,0}, 2,
+          { { 0, 3, { Script_C1Controls, DWRITE_SCRIPT_SHAPES_DEFAULT } },
+            { 3, 6, { Script_Latin, DWRITE_SCRIPT_SHAPES_DEFAULT } },
+          }
+    },
+    {
+      /* Latin Extended-A */
+      {0x100,0x120,0x130,0x140,0x150,0x160,0x170,0x17f,0}, 1,
+          { { 0, 8, { Script_Latin, DWRITE_SCRIPT_SHAPES_DEFAULT } }}
+    },
+    {
+      /* Latin Extended-B */
+      {0x180,0x190,0x1bf,0x1c0,0x1c3,0x1c4,0x1cc,0x1dc,0x1ff,0x217,0x21b,0x24f,0}, 1,
+          { { 0, 12, { Script_Latin, DWRITE_SCRIPT_SHAPES_DEFAULT } }}
+    },
+    {
+      /* IPA Extensions */
+      {0x250,0x260,0x270,0x290,0x2af,0}, 1,
+          { { 0, 5, { Script_Latin, DWRITE_SCRIPT_SHAPES_DEFAULT } }}
+    },
+    {
+      /* Spacing Modifier Letters */
+      {0x2b0,0x2ba,0x2d7,0x2dd,0x2ef,0x2ff,0}, 1,
+          { { 0, 6, { Script_Latin, DWRITE_SCRIPT_SHAPES_DEFAULT } }}
+    },
     /* keep this as end marker */
     { {0} }
 };
-- 
1.7.10.4




More information about the wine-patches mailing list