summaryrefslogtreecommitdiff
path: root/Build/source/texk/dvisvgm/dvisvgm-0.8.7-PATCHES/patch-07-libdvisvgm-uint32
blob: 16373281d02f3c046a61b40e59b801faf1c9514d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
diff -ur dvisvgm-0.8.7.orig/src/FontEngine.cpp dvisvgm-0.8.7/src/FontEngine.cpp
--- dvisvgm-0.8.7.orig/src/FontEngine.cpp	2009-11-06 22:17:58.000000000 +0100
+++ dvisvgm-0.8.7/src/FontEngine.cpp	2010-05-31 20:39:11.000000000 +0200
@@ -59,11 +59,15 @@
  * @param[out] reverseMap the resulting map */
 static void build_reverse_map (FT_Face face, map<UInt32, UInt32> &reverseMap) {
 	UInt32 glyphIndex;
-	UInt32 charcode = FT_Get_First_Char(face, &glyphIndex);
+	/* The explicit cast is necessary with the AIX compiler,
+	   which considers the dvisvgm definition signed,
+	   and incompatible with the freetype definition.  */
+	UInt32 charcode = FT_Get_First_Char(face, (FT_UInt *) &glyphIndex);
 	while (glyphIndex) {
 //		if (reverseMap.find(glyphIndex) == reverseMap.end())
 		reverseMap[glyphIndex] = charcode;
-		charcode = FT_Get_Next_Char(face, charcode, &glyphIndex);
+		charcode = FT_Get_Next_Char(face, charcode,
+                                            (FT_UInt *) &glyphIndex);
 	}
 }
 
@@ -112,10 +116,12 @@
 
 	FT_Set_Charmap(_currentFace, unicodeMap);
 	UInt32 glyphIndex;
-	UInt32 charcode = FT_Get_First_Char(_currentFace, &glyphIndex);
+	UInt32 charcode = FT_Get_First_Char(_currentFace,
+                                            (FT_UInt *) &glyphIndex);
 	while (glyphIndex) {
 		translationMap[reverseMap[glyphIndex]] = charcode;
-		charcode = FT_Get_Next_Char(_currentFace, charcode, &glyphIndex);
+		charcode = FT_Get_Next_Char(_currentFace, charcode,
+                                            (FT_UInt *) &glyphIndex);
 	}
 	FT_Set_Charmap(_currentFace, customMap);
 }