LFUNC(ExtensionsSize, int, (XpmExtension *ext, unsigned int num));
LFUNC(CommentsSize, int, (XpmInfo *info));
+#ifdef __OS2__
+/* Visual Age cannot deal with old, non-ansi, code */
+int XpmCreateBufferFromImage(
+ Display* display
+, char** buffer_return
+, XImage* image
+, XImage* shapeimage
+, XpmAttributes* attributes
+)
+#else
int
XpmCreateBufferFromImage(display, buffer_return, image, shapeimage, attributes)
Display *display;
XImage *image;
XImage *shapeimage;
XpmAttributes *attributes;
+#endif
{
XpmImage xpmimage;
XpmInfo info;
goto error; \
}
+#ifdef __OS2__
+/* Visual Age cannot deal with old, non-ansi, code */
+int XpmCreateBufferFromXpmImage(char** buffer_return, XpmImage* image, XpmInfo* info)
+#else
int
XpmCreateBufferFromXpmImage(buffer_return, image, info)
char **buffer_return;
XpmImage *image;
XpmInfo *info;
+#endif
{
/* calculation variables */
int ErrorStatus;
}
ErrorStatus = WriteColors(&ptr, &ptr_size, &used_size,
image->colorTable, image->ncolors, image->cpp);
-
+
if (ErrorStatus != XpmSuccess)
RETURN(ErrorStatus);
return (ErrorStatus);
}
+#ifdef __OS2__
+/* Visual Age cannot deal with old, non-ansi, code */
+static int WriteColors(
+ char** dataptr
+, unsigned int* data_size
+, unsigned int* used_size
+, XpmColor* colors
+, unsigned int ncolors
+, unsigned int cpp
+)
+#else
static int
WriteColors(dataptr, data_size, used_size, colors, ncolors, cpp)
char **dataptr;
XpmColor *colors;
unsigned int ncolors;
unsigned int cpp;
+#endif
{
char buf[BUFSIZ];
unsigned int a, key, l;
return (XpmSuccess);
}
+#ifdef __OS2__
+/* Visual Age cannot deal with old, non-ansi, code */
+static void WritePixels(
+ char* dataptr
+, unsigned int* used_size
+, unsigned int width
+, unsigned int height
+, unsigned int cpp
+, unsigned int* pixels
+, XpmColor* colors
+)
+#else
static void
WritePixels(dataptr, used_size, width, height, cpp, pixels, colors)
char *dataptr;
unsigned int cpp;
unsigned int *pixels;
XpmColor *colors;
+#endif
{
char *s = dataptr;
unsigned int x, y, h;
*used_size += s - dataptr;
}
+#ifdef __OS2__
+/* Visual Age cannot deal with old, non-ansi, code */
+static int
+ExtensionsSize(XpmExtension* ext, unsigned int num)
+#else
static int
ExtensionsSize(ext, num)
XpmExtension *ext;
unsigned int num;
+#endif
{
unsigned int x, y, a, size;
char **line;
return size + 13;
}
+#ifdef __OS2__
+/* Visual Age cannot deal with old, non-ansi, code */
+static void WriteExtensions(
+ char* dataptr
+, unsigned int* used_size
+, XpmExtension* ext
+, unsigned int num
+)
+#else
static void
WriteExtensions(dataptr, used_size, ext, num)
char *dataptr;
unsigned int *used_size;
XpmExtension *ext;
unsigned int num;
+#endif
{
unsigned int x, y, a;
char **line;
*used_size += s - dataptr + 13;
}
-static int
-CommentsSize(info)
+#ifdef __OS2__
+/* Visual Age cannot deal with old, non-ansi, code */
+static int CommentsSize(XpmInfo* info)
+#else
+static int CommentsSize(info)
XpmInfo *info;
+#endif
{
int size = 0;