diff options
-rw-r--r-- | xlib/ximage.c | 54 |
1 files changed, 5 insertions, 49 deletions
diff --git a/xlib/ximage.c b/xlib/ximage.c index 057e973..0f40bf3 100644 --- a/xlib/ximage.c +++ b/xlib/ximage.c @@ -21,6 +21,11 @@ * * Construct a single plane pixmap from bitmap data. * + * NOTE: This procedure has the correct behavior on Windows and + * the Macintosh, but not on UNIX. This is probably because the + * emulation for XPutImage on those platforms compensates for whatever + * is wrong here :-) + * * Results: * Returns a new Pixmap. * @@ -64,52 +69,3 @@ XCreateBitmapFromData(display, d, data, width, height) XFreeGC(display, gc); return pix; } - -/* - *---------------------------------------------------------------------- - * - * XReadBitmapFile -- - * - * Loads a bitmap image in X bitmap format into the specified - * drawable. - * - * Results: - * Sets the size, hotspot, and bitmap on success. - * - * Side effects: - * Creates a new bitmap from the file data. - * - *---------------------------------------------------------------------- - */ - -int -XReadBitmapFile(display, d, filename, width_return, height_return, - bitmap_return, x_hot_return, y_hot_return) - Display* display; - Drawable d; - _Xconst char* filename; - unsigned int* width_return; - unsigned int* height_return; - Pixmap* bitmap_return; - int* x_hot_return; - int* y_hot_return; -{ - Tcl_Interp *dummy; - char *data; - - dummy = Tcl_CreateInterp(); - - data = TkGetBitmapData(dummy, NULL, (char *) filename, - (int *) width_return, (int *) height_return, x_hot_return, - y_hot_return); - if (data == NULL) { - return BitmapFileInvalid; - } - - *bitmap_return = XCreateBitmapFromData(display, d, data, *width_return, - *height_return); - - Tcl_DeleteInterp(dummy); - ckfree(data); - return BitmapSuccess; -} |