summaryrefslogtreecommitdiff
path: root/graphics/magicpoint/patches/patch-ae
blob: f6a7dfbfa9e952d5e087bc68bebc053f1b40d16c (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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
$NetBSD: patch-ae,v 1.4 2011/02/25 17:02:53 wiz Exp $

--- draw.c.orig	2008-01-24 15:43:17.000000000 +0000
+++ draw.c
@@ -31,7 +31,7 @@
 
 #include "mgp.h"
 #ifdef USE_IMLIB
-#include <Imlib.h>
+#include <Imlib2.h>
 #endif
 
 /* state associated with the window - how should we treat this? */
@@ -83,8 +83,8 @@ static int obj_new_xfont __P((struct ren
 	u_int, char *));
 static int obj_new_image __P((struct render_state *, int, int, Image *, int, int));
 #ifdef USE_IMLIB
-ImlibImage *search_imdata __P((char *));
-static int obj_new_image2 __P((struct render_state *, int, int, Image *, int, int, ImlibImage *, int));
+Imlib_Image *search_imdata __P((char *));
+static int obj_new_image2 __P((struct render_state *, int, int, Image *, int, int, Imlib_Image *, int));
 #endif
 static int obj_new_icon __P((struct render_state *, int, int, u_int, u_int, u_long, u_int, XPoint *));
 static Pixel obj_image_color __P((Image *, Image *, Pixel, int *));
@@ -168,7 +168,7 @@ static void regist_zimage_position __P((
 static void clear_zimage __P((int));
 static void clear_region __P((int, int, int, int));
 #define ZIMAGENUM 100
-static ImlibImage *zimage[ZIMAGENUM];
+static Imlib_Image *zimage[ZIMAGENUM];
 static int zonzoom[ZIMAGENUM];
 static int zpage[ZIMAGENUM];
 static int zx[ZIMAGENUM];
@@ -1819,7 +1819,7 @@ obj_new_image2(state, x, y, image, xzoom
 	int x, y;
 	Image *image;
 	int xzoom, yzoom;
-	ImlibImage *imimage;
+	Imlib_Image *imimage;
 	int zoomonclk;
 {
 	struct render_object *obj;
@@ -3212,7 +3212,7 @@ image_load(state, filename, numcolor, xi
 	static char backfile[MAXPATHLEN];
 	static int backzoom, backnumcolor, backx, backy;
 #ifdef USE_IMLIB
-	ImlibImage *imimage;
+	Imlib_Image *imimage;
 #endif
 
 	if (!caching){
@@ -5243,7 +5243,7 @@ xft_draw_fragment(state, p, len, registr
 	static char prefix[3][20] = { "\033$B", "\033$A", "\033$(C"};
 	char buf16[1024], *p16;
 	char out16[1024], *o16;
-	int ileft, oleft;
+	size_t ileft, oleft;
 #ifdef HAVE_ICONV
 	static iconv_t icv[3];
 #endif
@@ -5471,12 +5471,12 @@ xft_setfont(xfontarg, csize, registry)
 		    XFT_FAMILY, XftTypeString, font,
 		    XFT_ENCODING, XftTypeString, registry,
 		    XFT_STYLE, XftTypeString, style,
-		    XFT_PIXEL_SIZE, XftTypeDouble, (float)csize, 0);
+		    XFT_PIXEL_SIZE, XftTypeDouble, (double)csize, NULL);
 	} else {
 		xftfont = XftFontOpen(display, screen,
 		    XFT_FAMILY, XftTypeString, font,
 		    XFT_ENCODING, XftTypeString, registry,
-		    XFT_PIXEL_SIZE, XftTypeDouble, (float)csize, 0);
+		    XFT_PIXEL_SIZE, XftTypeDouble, (double)csize, NULL);
 	}
 	if (xftfont == 0) {
 		free(xfont);