/* x11base.c */
-extern struct xvisual * allocate_x_visual (Visual * visual);
-extern void x_visual_deallocate (struct xvisual * xv);
extern void x_close_display (struct xdisplay * xd);
extern void x_close_all_displays (void);
extern int x_window_set_input_hint (struct xwindow * xw, int input_hint);
extern struct xdisplay * x_open_display (char * display_name);
extern void x_display_get_size (struct xdisplay * xd, long screen,
int * results);
-extern void x_close_window (struct xwindow * xw);
extern int x_set_default_font (struct xdisplay * xd, const char * name);
extern int x_display_descriptor (struct xdisplay * xd);
extern long x_max_request_size (struct xdisplay * xd);
extern int x_change_property (struct xdisplay * wd,
Window window, Atom property,
Atom type, int format, int mode,
- char * data, unsigned long dlen);
+ unsigned char * data, unsigned long dlen);
extern void x_delete_property (struct xdisplay * xd,
Window window, Atom property);
extern void x_set_selection_owner (struct xdisplay * xd,
XPoint * points);
extern struct ximage * x_create_image (struct xwindow * xw,
uint width, uint height);
-extern int x_bytes_into_image (char * vector, int length,
+extern int x_bytes_into_image (unsigned char * vector, int length,
struct ximage * ximage);
extern long x_get_pixel_from_image (struct ximage * xi, int x, int y);
extern int x_set_pixel_in_image (struct ximage * xi,
int c, unsigned int hl);
extern int xterm_write_substring (struct xwindow * xw,
unsigned int x, unsigned int y,
- char * string, unsigned int start,
+ unsigned char * string, unsigned int start,
unsigned int end, unsigned int hl);
extern int xterm_clear_rectangle (struct xwindow * xw,
unsigned int x_start, unsigned int x_end,
static void initialize_once (void);
-static void move_window (struct xwindow *, int, int);
static void check_expected_move (struct xwindow *);
\f
/* Allocation Tables */
return (length);
}
-static void *
-allocation_item (unsigned int num, struct allocation_table * table)
-{
- void * item;
- if ((num < 0) || (num >= table->length))
- return (NULL);
- return ((table->items) [num]);
-}
-
static struct xwindow *
x_window_to_xw (Display * display, Window window)
{
int
x_change_property (struct xdisplay * xd, Window window,
Atom property, Atom type, int format, int mode,
- char * data, unsigned long dlen)
+ unsigned char * data, unsigned long dlen)
{
Display * display = (XD_DISPLAY (xd));
}
int
-x_bytes_into_image (char * vector, int length, struct ximage *ximage)
+x_bytes_into_image (unsigned char * vector, int length, struct ximage *ximage)
{
XImage * image = (XI_IMAGE (ximage));
unsigned long width = (image -> width);
unsigned long x;
unsigned long y;
if (length != (width * height))
- return (0);
+ return (1);
vscan = vector;
for (y = 0; (y < height); y += 1)
for (x = 0; (x < width); x += 1)
XPutPixel (image, x, y, ((unsigned long) (*vscan++)));
+ return (0);
}
\f
long
int
xterm_write_substring (struct xwindow * xw, unsigned int x, unsigned int y,
- char * string, unsigned int start, unsigned int end,
+ unsigned char * string,
+ unsigned int start, unsigned int end,
unsigned int hl)
{
unsigned int length, index;
}
}
}
+ return (0);
}
\f
static void
}
}
}
+ return (0);
}
\f
int
char * contents)
{
unsigned int x_length;
- unsigned int string_length;
if (x_end >= ((XW_X_CSIZE (xw)) + 1))
return (1);
if (y_start >= (y_end + 1))
return (4);
x_length = (x_end - x_start);
- string_length = (2 * x_length * (y_end - y_start));
{
char * string_scan = contents;
}
}
}
+ return (0);
}
int