Back to index

plt-scheme  4.2.1
CrDatFrP.c File Reference
#include "xpmP.h"
#include <strings.h>

Go to the source code of this file.


int XpmCreateDataFromPixmap (Display *display, char ***data_return, Pixmap pixmap, Pixmap shapemask, XpmAttributes *attributes)

Function Documentation

int XpmCreateDataFromPixmap ( Display *  display,
char ***  data_return,
Pixmap  pixmap,
Pixmap  shapemask,
XpmAttributes attributes 

Definition at line 43 of file CrDatFrP.c.

    XImage *ximage = NULL;
    XImage *shapeimage = NULL;
    unsigned int width = 0;
    unsigned int height = 0;
    int ErrorStatus;

    /* get geometry */
    if (attributes && attributes->valuemask & XpmSize) {
       width = attributes->width;
       height = attributes->height;
    /* get the ximages */
    if (pixmap)
       xpmCreateImageFromPixmap(display, pixmap, &ximage, &width, &height);
    if (shapemask)
       xpmCreateImageFromPixmap(display, shapemask, &shapeimage,
                             &width, &height);

    /* create the data */
    ErrorStatus = XpmCreateDataFromImage(display, data_return, ximage,
                                    shapeimage, attributes);

    /* destroy the ximages */
    if (ximage)
    if (shapeimage)

    return (ErrorStatus);

Here is the call graph for this function: