40#define GET_BE_WORD(x) (x)
41#define GET_BE_DWORD(x) (x)
43#define GET_BE_WORD(x) RtlUshortByteSwap(x)
44#define GET_BE_DWORD(x) RtlUlongByteSwap(x)
47#define round(x) (((x) < 0) ? (int)((x) - 0.5) : (int)((x) + 0.5))
50#define CMAP_TAG MS_MAKE_TAG('c', 'm', 'a', 'p')
633 if (!
psc->CMAP_Table)
646 CMAP_Table =
psc->CMAP_Table;
676 if (utf32c < 0x10000)
682 if (!
psc->CMAP_format12_Table)
686 *glyph_index = 0xffffu;
690 if (
psc->CMAP_format12_Table)
719 if (!
table)
return 0;
754 void *glyph_class_table =
NULL;
803 ERR(
"Unknown glyph class %i\n",
class);
829 TRACE(
"Coverage Format 1, %i glyphs\n",
count);
843 TRACE(
"Coverage Format 2, %i ranges\n",
count);
885 TRACE(
"Single Substitution Subtable\n");
899 return glyph_index + write_dir;
921 return glyph_index + write_dir;
931 TRACE(
"Multiple Substitution Subtable\n");
949 TRACE(
" Glyph 0x%x (+%i)->",
glyphs[glyph_index],(sub_count-1));
951 for (
j = (*glyph_count)+(sub_count-1);
j > glyph_index;
j--)
954 for (
j = 0;
j < sub_count;
j++)
960 *glyph_count = *glyph_count + (sub_count - 1);
964 for (
j = 0;
j < sub_count;
j++)
970 return glyph_index + sub_count;
972 return glyph_index - 1;
981 TRACE(
"Alternate Substitution Subtable\n");
1005 return glyph_index + write_dir;
1015 TRACE(
"Ligature Substitution Subtable\n");
1033 TRACE(
" LigatureSet has %i members\n",
count);
1037 int CompCount,
l,CompIndex;
1042 CompIndex = glyph_index+write_dir;
1043 for (
l = 0; l < CompCount && CompIndex >= 0 && CompIndex < *glyph_count;
l++)
1047 if (CompGlyph !=
glyphs[CompIndex])
1049 CompIndex += write_dir;
1053 int replaceIdx = glyph_index;
1055 replaceIdx = glyph_index - CompCount;
1057 TRACE(
" Glyph is 0x%x (+%i) ->",
glyphs[glyph_index],CompCount);
1062 unsigned int j = replaceIdx + 1;
1064 *glyph_count = *glyph_count - CompCount;
1066 return replaceIdx + write_dir;
1077 TRACE(
"Context Substitution Subtable\n");
1086 TRACE(
"Context Substitution Subtable: Class 1\n");
1104 int newIndex = glyph_index;
1109 TRACE(
" SubRule has %i glyphs\n",g_count);
1111 g = glyph_index + write_dir * (g_count - 1);
1112 if (
g >= *glyph_count)
1115 for (
l = 0;
l < g_count-1;
l++)
1120 TRACE(
" Rule does not match\n");
1124 TRACE(
" Rule matches\n");
1132 g = glyph_index + write_dir * sequence_index;
1133 if (
g >= *glyph_count)
1135 WARN(
"Invalid sequence index %u (glyph index %u, write dir %d).\n",
1136 sequence_index, glyph_index, write_dir);
1140 TRACE(
" SUBST: %u -> %u %u.\n",
l, sequence_index, lookup_index);
1144 ERR(
" Chain failed to generate a glyph\n");
1155 const void *glyph_class_table;
1159 TRACE(
"Context Substitution Subtable: Class 2\n");
1169 glyph_class_table = (
const BYTE *)csf2 +
offset;
1176 TRACE(
" No class rule table for class %i\n",
class);
1181 TRACE(
" SubClassSet has %i members\n",
count);
1188 int newIndex = glyph_index;
1193 TRACE(
" SubClassRule has %i glyphs classes\n",g_count);
1195 g = glyph_index + write_dir * (g_count - 1);
1196 if (
g >= *glyph_count)
1199 for (
l = 0;
l < g_count-1;
l++)
1207 TRACE(
" Rule does not match\n");
1211 TRACE(
" Rule matches\n");
1219 g = glyph_index + write_dir * sequence_index;
1220 if (
g >= *glyph_count)
1222 WARN(
"Invalid sequence index %u (glyph index %u, write dir %d).\n",
1223 sequence_index, glyph_index, write_dir);
1227 TRACE(
" SUBST: %u -> %u %u.\n",
l, sequence_index, lookup_index);
1231 ERR(
" Chain failed to generate a glyph\n");
1249 TRACE(
"Chaining Contextual Substitution Subtable\n");
1254 int dirLookahead = write_dir;
1255 int dirBacktrack = -1 * write_dir;
1262 FIXME(
" TODO: subtype 1 (Simple context glyph substitution)\n");
1268 const void *backtrack_class_table;
1269 const void *input_class_table;
1270 const void *lookahead_class_table;
1277 TRACE(
" subtype 2 (Class-based Chaining Context Glyph Substitution)\n");
1283 TRACE(
"Glyph not covered\n");
1287 backtrack_class_table = (
const BYTE*)ccsf2+
offset;
1289 input_class_table = (
const BYTE*)ccsf2+
offset;
1291 lookahead_class_table = (
const BYTE*)ccsf2+
offset;
1299 TRACE(
"No rules for class\n");
1310 WORD backtrack_count, input_count, lookahead_count, substitute_count;
1321 k = glyph_index + dirBacktrack * backtrack_count;
1322 if (k < 0 || k >= *glyph_count)
1327 k = glyph_index + write_dir * input_count;
1328 if (k < 0 || k >= *glyph_count)
1333 k = glyph_index + dirLookahead * (input_count + lookahead_count);
1334 if (k < 0 || k >= *glyph_count)
1339 for (
k = 0;
k < backtrack_count; ++
k)
1343 if (target_class != glyph_class)
1346 if (
k != backtrack_count)
1348 TRACE(
"Matched Backtrack\n");
1350 for (
k = 0;
k < input_count; ++
k)
1354 if (target_class != glyph_class)
1357 if (
k != input_count)
1359 TRACE(
"Matched IndexGlyphs\n");
1361 for (
k = 0;
k < lookahead_count; ++
k)
1365 glyphs[glyph_index + (dirLookahead * (input_count +
k + 1))]);
1366 if (target_class != glyph_class)
1369 if (
k != lookahead_count)
1371 TRACE(
"Matched LookAhead\n");
1374 for (
k = 0;
k < substitute_count; ++
k)
1378 unsigned int g = glyph_index + write_dir * sequence_index;
1380 if (
g >= *glyph_count)
1382 WARN(
"Skipping invalid sequence index %u (glyph index %u, write dir %d).\n",
1383 sequence_index, glyph_index, write_dir);
1387 TRACE(
"SUBST: %u -> %u %u.\n",
k, sequence_index, lookup_index);
1390 ERR(
"Chain failed to generate a glyph.\n");
1397 WORD backtrack_count, input_count, lookahead_count, substitution_count;
1405 TRACE(
" subtype 3 (Coverage-based Chaining Context Glyph Substitution)\n");
1409 k = glyph_index + dirBacktrack * backtrack_count;
1410 if (k < 0 || k >= *glyph_count)
1415 k = glyph_index + write_dir * (input_count - 1);
1416 if (k < 0 || k >= *glyph_count)
1421 k = glyph_index + dirLookahead * (input_count + lookahead_count - 1);
1422 if (k < 0 || k >= *glyph_count)
1427 for (
k = 0;
k < backtrack_count; ++
k)
1431 glyphs[glyph_index + (dirBacktrack * (
k + 1))]) == -1)
1434 if (
k != backtrack_count)
1436 TRACE(
"Matched Backtrack\n");
1438 for (
k = 0;
k < input_count; ++
k)
1442 glyphs[glyph_index + (write_dir *
k)]) == -1)
1445 if (
k != input_count)
1447 TRACE(
"Matched IndexGlyphs\n");
1449 for (
k = 0;
k < lookahead_count; ++
k)
1453 glyphs[glyph_index + (dirLookahead * (input_count +
k))]) == -1)
1456 if (
k != lookahead_count)
1458 TRACE(
"Matched LookAhead\n");
1461 for (
k = 0;
k < substitution_count; ++
k)
1465 unsigned int g = glyph_index + write_dir * sequence_index;
1467 if (
g >= *glyph_count)
1469 WARN(
"Skipping invalid sequence index %u (glyph index %u, write dir %d).\n",
1470 sequence_index, glyph_index, write_dir);
1474 TRACE(
"SUBST: %u -> %u %u.\n",
k, sequence_index, lookup_index);
1477 ERR(
"Chain failed to generate a glyph.\n");
1494 TRACE(
"type %#x, flag %#x, subtables %u.\n",
type,
1514 WARN(
"lookup type is Extension Substitution but no extension subtable exists\n");
1532 FIXME(
"Extension Substitution types not valid here\n");
1535 FIXME(
"Unhandled GSUB lookup type %#x.\n",
type);
1541 unsigned int glyph_index,
int write_dir,
int *glyph_count)
1554 unsigned int lookup_index,
const WORD *
glyphs,
unsigned int glyph_index,
unsigned int glyph_count,
1559 static const WORD mask[3] = {3,0xf,0xff};
1568 if (format < 1 || format > 3)
1592 TRACE(
"Anchor Format 1\n");
1600 TRACE(
"Anchor Format 2\n");
1609 TRACE(
"Anchor Format 3\n");
1613 TRACE(
"ppem %i\n",ppem);
1637 int desX,
int desY,
double *devX,
double *devY)
1641 TRACE(
"emHeight %i lfWidth %i\n",emHeight, logfont->
lfWidth);
1642 *devX = (desX * emHeight) / (
double)otm->
otmEMSquare;
1643 *devY = (desY * emHeight) / (
double)otm->
otmEMSquare;
1645 FIXME(
"Font with lfWidth set not handled properly.\n");
1663 WORD ValueFormat,
unsigned int ppem,
POINT *ptPlacement,
POINT *ptAdvance)
1665 if (ValueFormat & 0x0001) ptPlacement->
x += (
short)ValueRecord->
XPlacement;
1673 if (ValueFormat & 0xFF00)
FIXME(
"Unhandled Value Format %x\n",ValueFormat&0xFF00);
1696 const WORD *
glyphs,
unsigned int glyph_index,
unsigned int glyph_count,
unsigned int ppem,
1701 TRACE(
"Single Adjustment Positioning Subtable\n");
1771 const WORD *
glyphs,
unsigned int glyph_index,
unsigned int glyph_count,
unsigned int ppem,
1777 if (glyph_index + write_dir >= glyph_count)
1780 TRACE(
"Pair Adjustment Positioning Subtable\n");
1805 for (
k = 0;
k < pair_count;
k++)
1808 if (
glyphs[glyph_index+write_dir] == second_glyph)
1811 TRACE(
"Format 1: Found Pair %x,%x\n",
glyphs[glyph_index],
glyphs[glyph_index+write_dir]);
1814 if (ValueFormat2)
next++;
1836 WORD class1, class2;
1839 if (class1 < class1_count && class2 < class2_count)
1841 const WORD *pair_val = ppf2->
Class1Record + (class1 * class2_count + class2) * (val_fmt1_size + val_fmt2_size);
1844 TRACE(
"Format 2: Found Pair %x,%x\n",
glyphs[glyph_index],
glyphs[glyph_index + write_dir] );
1847 if (ValueFormat2)
next++;
1859 const WORD *
glyphs,
unsigned int glyph_index,
unsigned int glyph_count,
unsigned int ppem,
POINT *
pt)
1864 if (glyph_index + write_dir >= glyph_count)
1867 TRACE(
"Cursive Attachment Positioning Subtable\n");
1874 int index_exit, index_entry;
1882 POINT exit_pt, entry_pt;
1888 pt->x = entry_pt.
x - exit_pt.
x;
1889 pt->y = entry_pt.
y - exit_pt.
y;
1902 unsigned int glyph_count,
unsigned int ppem,
POINT *
pt)
1906 const void *glyph_class_table =
NULL;
1917 TRACE(
"MarkToBase Attachment Positioning Subtable\n");
1927 if (mark_index != -1)
1930 int base_glyph = glyph_index - write_dir;
1932 if (glyph_class_table)
1935 base_glyph -= write_dir;
1940 if (base_index != -1)
1948 int baserecord_size;
1951 TRACE(
"Mark %x(%i) and base %x(%i)\n",
glyphs[glyph_index], mark_index,
glyphs[base_glyph], base_index);
1956 ERR(
"Mark index exceeded mark count\n");
1961 TRACE(
"Mark Class %i total classes %i\n",mark_class,class_count);
1964 baserecord_size = class_count *
sizeof(
WORD);
1972 pt->x += base_pt.
x - mark_pt.
x;
1973 pt->y += base_pt.
y - mark_pt.
y;
1986 const WORD *
glyphs,
unsigned int glyph_index,
unsigned int glyph_count,
unsigned int ppem,
POINT *
pt)
1991 TRACE(
"MarkToLigature Attachment Positioning Subtable\n");
2001 if (mark_index != -1)
2006 if (ligature_index != -1)
2021 TRACE(
"Mark %x(%i) and ligature %x(%i)\n",
glyphs[glyph_index], mark_index,
glyphs[glyph_index - write_dir], ligature_index);
2026 ERR(
"Mark index exceeded mark count\n");
2031 TRACE(
"Mark Class %i total classes %i\n",mark_class,class_count);
2036 ERR(
"Ligature index exceeded ligature count\n");
2049 for (
k = 0;
k < class_count && !
offset;
k++)
2055 ERR(
"Failed to find available ligature connection point\n");
2064 pt->x += ligature_pt.
x - mark_pt.
x;
2065 pt->y += ligature_pt.
y - mark_pt.
y;
2076 const WORD *
glyphs,
unsigned int glyph_index,
unsigned int glyph_count,
unsigned int ppem,
POINT *
pt)
2082 TRACE(
"MarkToMark Attachment Positioning Subtable\n");
2092 if (mark_index != -1)
2097 if (mark2_index != -1)
2105 int mark2record_size;
2108 TRACE(
"Mark %x(%i) and Mark2 %x(%i)\n",
glyphs[glyph_index], mark_index,
glyphs[glyph_index - write_dir], mark2_index);
2113 ERR(
"Mark index exceeded mark count\n");
2118 TRACE(
"Mark Class %i total classes %i\n",mark_class,class_count);
2121 mark2record_size = class_count *
sizeof(
WORD);
2129 pt->x += mark2_pt.
x - mark_pt.
x;
2130 pt->y += mark2_pt.
y - mark_pt.
y;
2150 TRACE(
"Contextual Positioning Subtable\n");
2160 FIXME(
" TODO: subtype 1\n");
2168 TRACE(
"Contextual Positioning Subtable: Format 2\n");
2176 const void *glyph_class_table =
NULL;
2179 glyph_class_table = (
const BYTE *)cpf2 +
offset;
2186 TRACE(
"No class rule table for class %i\n",
class);
2202 TRACE(
"PosClassRule has %i glyphs classes\n",g_count);
2204 g = glyph_index + write_dir * (g_count - 1);
2205 if (
g >= glyph_count)
2208 for (
l = 0;
l < g_count-1;
l++)
2216 TRACE(
"Rule does not match\n");
2220 TRACE(
"Rule matches\n");
2228 g = glyph_index + write_dir * sequence_index;
2229 if (
g >= glyph_count)
2231 WARN(
"Invalid sequence index %u (glyph index %u, write dir %d).\n",
2232 sequence_index, glyph_index, write_dir);
2236 TRACE(
"Position: %u -> %u %u.\n",
l, sequence_index, lookup_index);
2245 TRACE(
"Not covered\n");
2252 FIXME(
" TODO: subtype 3\n");
2269 TRACE(
"Chaining Contextual Positioning Subtable\n");
2275 int dirLookahead = write_dir;
2276 int dirBacktrack = -1 * write_dir;
2282 FIXME(
" TODO: subtype 1 (Simple Chaining Context Glyph Positioning)\n");
2289 FIXME(
" TODO: subtype 2 (Class-based Chaining Context Glyph Positioning)\n");
2294 WORD backtrack_count, input_count, lookahead_count, positioning_count;
2300 TRACE(
" subtype 3 (Coverage-based Chaining Context Glyph Positioning)\n");
2303 k = glyph_index + dirBacktrack * backtrack_count;
2304 if (k < 0 || k >= glyph_count)
2309 k = glyph_index + write_dir * (input_count - 1);
2310 if (k < 0 || k >= glyph_count)
2315 k = glyph_index + dirLookahead * (input_count + lookahead_count - 1);
2316 if (k < 0 || k >= glyph_count)
2321 for (
k = 0;
k < backtrack_count; ++
k)
2325 glyphs[glyph_index + (dirBacktrack * (
k + 1))]) == -1)
2328 if (
k != backtrack_count)
2330 TRACE(
"Matched Backtrack\n");
2332 for (
k = 0;
k < input_count; ++
k)
2336 glyphs[glyph_index + (write_dir *
k)]) == -1)
2339 if (
k != input_count)
2341 TRACE(
"Matched IndexGlyphs\n");
2343 for (
k = 0;
k < lookahead_count; ++
k)
2347 glyphs[glyph_index + (dirLookahead * (input_count +
k))]) == -1)
2350 if (
k != lookahead_count)
2352 TRACE(
"Matched LookAhead\n");
2357 for (
k = 0;
k < positioning_count; ++
k)
2361 unsigned int g = glyph_index + write_dir * sequence_index;
2363 if (
g >= glyph_count)
2365 WARN(
"Skipping invalid sequence index %u (glyph index %u, write dir %d).\n",
2366 sequence_index, glyph_index, write_dir);
2370 TRACE(
"Position: %u -> %u %u.\n",
k, sequence_index, lookup_index);
2372 glyphs,
g, glyph_count, goffset);
2374 return input_count + lookahead_count;
2384 unsigned int lookup_index,
const WORD *
glyphs,
unsigned int glyph_index,
unsigned int glyph_count,
2395 TRACE(
"type %#x, flag %#x, subtables %u.\n",
type,
2415 WARN(
"lookup type is Extension Positioning but no extension subtable exists\n");
2423 POINT adjust = {0,0};
2426 if (adjust.
x || adjust.
y)
2429 pGoffset[glyph_index].
du +=
round(devX);
2430 pGoffset[glyph_index].
dv +=
round(devY);
2435 piAdvance[glyph_index] +=
round(devX);
2437 FIXME(
"Unhandled adjustment to Y advancement\n");
2445 POINT adjust[2]= {{0,0},{0,0}};
2452 glyph_index, glyph_count, ppem, adjust,
advance);
2453 if (adjust[0].
x || adjust[0].
y)
2456 pGoffset[glyph_index].
du +=
round(devX) * offset_sign;
2457 pGoffset[glyph_index].
dv +=
round(devY);
2462 piAdvance[glyph_index] +=
round(devX);
2464 if (adjust[1].
x || adjust[1].
y)
2467 pGoffset[glyph_index + write_dir].
du +=
round(devX) * offset_sign;
2468 pGoffset[glyph_index + write_dir].
dv +=
round(devY);
2473 piAdvance[glyph_index + write_dir] +=
round(devX);
2475 return index_offset;
2485 if (desU.
x || desU.
y)
2489 pGoffset[glyph_index].
dv =
round(devY) + pGoffset[glyph_index+write_dir].
dv;
2499 glyphs, glyph_index, glyph_count, ppem, &desU);
2500 if (base_index != -1)
2503 if (!analysis->
fRTL) pGoffset[glyph_index].
du =
round(devX) - piAdvance[base_index];
2507 pGoffset[glyph_index].
du =
round(devX);
2509 pGoffset[glyph_index].
dv =
round(devY);
2519 if (desU.
x || desU.
y)
2522 pGoffset[glyph_index].
du = (
round(devX) - piAdvance[glyph_index-1]);
2523 pGoffset[glyph_index].
dv =
round(devY);
2537 pGoffset[glyph_index].
du =
round(devX) + pGoffset[glyph_index - write_dir].
du;
2538 pGoffset[glyph_index].
dv =
round(devY) + pGoffset[glyph_index - write_dir].
dv;
2545 lookup, look,
glyphs, glyph_index, glyph_count, pGoffset);
2549 lookup, look,
glyphs, glyph_index, glyph_count, pGoffset);
2552 FIXME(
"Unhandled GPOS lookup type %#x.\n",
type);
2559 const WORD *
glyphs,
unsigned int glyph_index,
unsigned int glyph_count,
GOFFSET *goffset)
2565 lookup_index,
glyphs, glyph_index, glyph_count, goffset);
2575 ERR(
"Failed to grow scripts array.\n");
2605 TRACE(
"script_cache %p, table %#x, list %p.\n", script_cache,
table,
list);
2616 list->ScriptRecord[
i].ScriptTag[1],
2617 list->ScriptRecord[
i].ScriptTag[2],
2618 list->ScriptRecord[
i].ScriptTag[3]);
2636 if ((gsub_header = script_cache->
GSUB_Table))
2640 if ((gpos_header = script_cache->
GPOS_Table))
2683 script->language_count + 1,
sizeof(*
script->languages)))
2685 ERR(
"Failed to grow languages array.\n");
2689 language = &
script->languages[
script->language_count++];
2699 for (
i = 0;
i <
script->language_count; ++
i)
2730 initial_count =
script->language_count;
2734 list->LangSysRecord[
i].LangSysTag[1],
2735 list->LangSysRecord[
i].LangSysTag[2],
2736 list->LangSysRecord[
i].LangSysTag[3]);
2750 if (
script->languages_initialized)
2773 if (!searchingFor && cMaxTags < script->language_count)
2775 else if (searchingFor)
2780 for (
i = 0;
i <
script->language_count;
i++)
2783 pLanguageTags[
i] =
script->languages[
i].tag;
2787 if (searchingFor ==
script->languages[
i].tag)
2789 pLanguageTags[0] =
script->languages[
i].tag;
2800 pLanguageTags[
i] =
script->default_language.tag;
2802 if (searchingFor &&
FAILED(rc))
2804 pLanguageTags[0] =
script->default_language.tag;
2819 TRACE(
"table_type %#x, %u features.\n", table_type,
count);
2891 language = &
script->default_language;
2916 else if (searchingFor)
static VOID Substitute(_Out_writes_bytes_(BufferSize) PWCHAR Buffer, _In_ ULONG BufferSize, _In_ PCWSTR Template, _In_ PCWSTR SystemDriveName, _In_ PCWSTR SystemRootName)
_STLP_MOVE_TO_STD_NAMESPACE void _STLP_CALL advance(_InputIterator &__i, _Distance __n)
struct outqueuenode * head
static void * heap_alloc(size_t len)
static const char * wine_dbgstr_point(const POINT *ppt)
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
void ls(int argc, const char *argv[])
unsigned int component_count
unsigned int component_size
static const WCHAR *const ext[]
#define MS_MAKE_TAG(ch0, ch1, ch2, ch3)
static void Lookup(RTF_Info *, char *)
BOOL usp10_array_reserve(void **elements, SIZE_T *capacity, SIZE_T count, SIZE_T size)
int USP10_FindGlyphInLogClust(const WORD *pwLogClust, int cChars, WORD target)
unsigned short(__cdecl typeof(TIFFCurrentDirectory))(struct tiff *)
struct nls_table * tables
GLint GLint GLint GLint GLint x
GLuint GLuint GLsizei count
GLuint GLuint GLsizei GLenum type
GLint GLint GLint GLint GLint GLint y
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
GLdouble GLdouble GLdouble GLdouble top
GLboolean GLboolean GLboolean b
GLuint GLsizei GLsizei * length
GLboolean GLboolean GLboolean GLboolean a
GLenum GLenum GLenum input
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble * u
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint j
ROSDATA LIGATURE2 Ligature[]
#define memmove(s1, s2, n)
static UINT UINT LPWORD glyphs
INTERNETFEATURELIST feature
static SCRIPT_CACHE SCRIPT_ANALYSIS OPENTYPE_TAG OPENTYPE_TAG int TEXTRANGE_PROPERTIES int const WCHAR int cChars
static SCRIPT_CACHE * psc
static SCRIPT_CACHE SCRIPT_ANALYSIS OPENTYPE_TAG OPENTYPE_TAG int OPENTYPE_TAG * pFeatureTags
static int int const SCRIPT_CONTROL const SCRIPT_STATE SCRIPT_ITEM ULONG * pScriptTags
static SCRIPT_CACHE SCRIPT_ANALYSIS OPENTYPE_TAG OPENTYPE_TAG int TEXTRANGE_PROPERTIES int const WCHAR int int WORD * pwLogClust
static SCRIPT_CACHE SCRIPT_ANALYSIS int cMaxTags
static SCRIPT_CACHE SCRIPT_ANALYSIS int OPENTYPE_TAG int * pcTags
static int GSUB_is_glyph_covered(const void *table, unsigned int glyph)
static void GPOS_apply_SingleAdjustment(const OT_LookupTable *look, const SCRIPT_ANALYSIS *analysis, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, unsigned int ppem, POINT *adjust, POINT *advance)
static INT GSUB_apply_ContextSubst(const OT_LookupList *lookup, const OT_LookupTable *look, WORD *glyphs, INT glyph_index, INT write_dir, INT *glyph_count)
static void apply_pair_value(const void *pos_table, WORD val_fmt1, WORD val_fmt2, const WORD *pair, INT ppem, POINT *adjust, POINT *advance)
static void usp10_language_add_feature_list(LoadedLanguage *language, char table_type, const OT_LangSys *lang, const OT_FeatureList *feature_list)
@ GPOS_LOOKUP_POSITION_CONTEXT_CHAINED
@ GPOS_LOOKUP_ATTACH_MARK_TO_LIGATURE
@ GPOS_LOOKUP_ADJUST_SINGLE
@ GPOS_LOOKUP_ADJUST_PAIR
@ GPOS_LOOKUP_ATTACH_MARK_TO_BASE
@ GPOS_LOOKUP_POSITION_EXTENSION
@ GPOS_LOOKUP_ATTACH_MARK_TO_MARK
@ GPOS_LOOKUP_ATTACH_CURSIVE
@ GPOS_LOOKUP_POSITION_CONTEXT
static int GPOS_apply_PairAdjustment(const OT_LookupTable *look, const SCRIPT_ANALYSIS *analysis, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, unsigned int ppem, POINT *adjust, POINT *advance)
HRESULT OpenType_GetFontFeatureTags(ScriptCache *psc, OPENTYPE_TAG script_tag, OPENTYPE_TAG language_tag, BOOL filtered, OPENTYPE_TAG searchingFor, char tableType, int cMaxTags, OPENTYPE_TAG *pFeatureTags, int *pcTags, LoadedFeature **feature)
static INT GSUB_apply_ChainContextSubst(const OT_LookupList *lookup, const OT_LookupTable *look, WORD *glyphs, INT glyph_index, INT write_dir, INT *glyph_count)
static void _initialize_script_cache(ScriptCache *script_cache)
HRESULT OpenType_GetFontLanguageTags(ScriptCache *psc, OPENTYPE_TAG script_tag, OPENTYPE_TAG searchingFor, int cMaxTags, OPENTYPE_TAG *pLanguageTags, int *pcTags)
static void _initialize_language_cache(LoadedScript *script)
static LoadedLanguage * usp10_script_add_language(LoadedScript *script, OPENTYPE_TAG tag)
static INT GPOS_get_value_record(WORD ValueFormat, const WORD data[], GPOS_ValueRecord *record)
static unsigned int GPOS_apply_ChainContextPos(const ScriptCache *script_cache, const OUTLINETEXTMETRICW *otm, const LOGFONTW *logfont, const SCRIPT_ANALYSIS *analysis, int *advance, const OT_LookupList *lookup, const OT_LookupTable *look, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, GOFFSET *goffset)
static void GPOS_apply_CursiveAttachment(const OT_LookupTable *look, const SCRIPT_ANALYSIS *analysis, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, unsigned int ppem, POINT *pt)
static INT GSUB_apply_LigatureSubst(const OT_LookupTable *look, WORD *glyphs, INT glyph_index, INT write_dir, INT *glyph_count)
static WORD OT_get_glyph_class(const void *table, WORD glyph)
static void usp10_script_add_language_list(LoadedScript *script, enum usp10_language_table table, const OT_Script *list)
static void usp10_script_cache_add_script_list(ScriptCache *script_cache, enum usp10_script_table table, const OT_ScriptList *list)
static const BYTE * GSUB_get_subtable(const OT_LookupTable *look, int index)
static INT GSUB_apply_SingleSubst(const OT_LookupTable *look, WORD *glyphs, INT glyph_index, INT write_dir, INT *glyph_count)
@ GSUB_LOOKUP_CONTEXT_CHAINED_REVERSE
@ GSUB_LOOKUP_CONTEXT_CHAINED
static int GPOS_apply_MarkToBase(const ScriptCache *script_cache, const OT_LookupTable *look, const SCRIPT_ANALYSIS *analysis, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, unsigned int ppem, POINT *pt)
static LoadedScript * usp10_script_cache_get_script(ScriptCache *script_cache, OPENTYPE_TAG tag)
static void GPOS_convert_design_units_to_device(const OUTLINETEXTMETRICW *otm, const LOGFONTW *logfont, int desX, int desY, double *devX, double *devY)
static void GPOS_apply_MarkToLigature(const OT_LookupTable *look, const SCRIPT_ANALYSIS *analysis, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, unsigned int ppem, POINT *pt)
unsigned int OpenType_apply_GPOS_lookup(const ScriptCache *script_cache, const OUTLINETEXTMETRICW *otm, const LOGFONTW *logfont, const SCRIPT_ANALYSIS *analysis, int *advance, unsigned int lookup_index, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, GOFFSET *goffset)
static void GPOS_get_anchor_values(const void *table, POINT *pt, WORD ppem)
static unsigned int GPOS_apply_lookup(const ScriptCache *script_cache, const OUTLINETEXTMETRICW *otm, const LOGFONTW *logfont, const SCRIPT_ANALYSIS *analysis, int *advance, const OT_LookupList *lookup, unsigned int lookup_index, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, GOFFSET *goffset)
static INT GSUB_apply_lookup(const OT_LookupList *lookup, INT lookup_index, WORD *glyphs, INT glyph_index, INT write_dir, INT *glyph_count)
static BOOL GPOS_apply_MarkToMark(const OT_LookupTable *look, const SCRIPT_ANALYSIS *analysis, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, unsigned int ppem, POINT *pt)
static void _initialize_feature_cache(ScriptCache *psc, LoadedLanguage *language)
void OpenType_GDEF_UpdateGlyphProps(ScriptCache *psc, const WORD *pwGlyphs, const WORD cGlyphs, WORD *pwLogClust, const WORD cChars, SCRIPT_GLYPHPROP *pGlyphProp)
static void GPOS_get_value_record_offsets(const BYTE *head, GPOS_ValueRecord *ValueRecord, WORD ValueFormat, unsigned int ppem, POINT *ptPlacement, POINT *ptAdvance)
static INT GSUB_apply_MultipleSubst(const OT_LookupTable *look, WORD *glyphs, INT glyph_index, INT write_dir, INT *glyph_count)
static VOID * load_CMAP_format12_table(HDC hdc, ScriptCache *psc)
DWORD OpenType_CMAP_GetGlyphIndex(HDC hdc, ScriptCache *psc, DWORD utf32c, WORD *glyph_index, DWORD flags)
static LoadedLanguage * usp10_script_get_language(LoadedScript *script, OPENTYPE_TAG tag)
static INT GSUB_apply_AlternateSubst(const OT_LookupTable *look, WORD *glyphs, INT glyph_index, INT write_dir, INT *glyph_count)
static LoadedScript * usp10_script_cache_add_script(ScriptCache *script_cache, OPENTYPE_TAG tag)
static const BYTE * GPOS_get_subtable(const OT_LookupTable *look, int index)
int OpenType_apply_GSUB_lookup(const void *table, unsigned int lookup_index, WORD *glyphs, unsigned int glyph_index, int write_dir, int *glyph_count)
HRESULT OpenType_GetFontScriptTags(ScriptCache *psc, OPENTYPE_TAG searchingFor, int cMaxTags, OPENTYPE_TAG *pScriptTags, int *pcTags)
static unsigned int GPOS_apply_ContextPos(const ScriptCache *script_cache, const OUTLINETEXTMETRICW *otm, const LOGFONTW *logfont, const SCRIPT_ANALYSIS *analysis, int *advance, const OT_LookupList *lookup, const OT_LookupTable *look, const WORD *glyphs, unsigned int glyph_index, unsigned int glyph_count, GOFFSET *goffset)
static int __cdecl compare_group(const void *a, const void *b)
static INT GPOS_get_device_table_value(const OT_DeviceTable *DeviceTable, WORD ppem)
static unsigned __int64 next
static void * heap_calloc(SIZE_T count, SIZE_T size)
GPOS_PosLookupRecord PosLookupRecord[1]
GPOS_ComponentRecord ComponentRecord[1]
GPOS_MarkRecord MarkRecord[1]
GPOS_PairValueRecord PairValueRecord[1]
GPOS_PosLookupRecord PosLookupRecord[1]
WORD ChainSubRuleSetCount
GSUB_SubstLookupRecord SubstLookupRecord[1]
GSUB_SubstLookupRecord SubstLookupRecord[1]
WORD ChainSubClassRule[1]
WORD ChainSubClassRuleCnt