#include "specifier.h"
#include "window.h"
-#ifdef HAVE_XPM
+#if defined (HAVE_XPM) && !defined (HAVE_GTK)
#include <X11/xpm.h>
#endif
print_internal
(IMAGE_INSTANCE_WIDGET_FACE (ii), printcharfun, 0);
}
-
+ /* fallthrough */
case IMAGE_SUBWINDOW:
sprintf (buf, " %dx%d", IMAGE_INSTANCE_WIDTH (ii),
int* width, int* height, int* descent, Lisp_Object domain)
{
struct font_metric_info fm;
- unsigned char charsets[NUM_LEADING_BYTES];
+ Charset_ID charsets[NUM_LEADING_BYTES];
struct face_cachel frame_cachel;
struct face_cachel *cachel;
Lisp_Object frame = DOMAIN_FRAME (domain);
+ CHECK_STRING (string);
+
/* Compute height */
if (height)
{
Lisp_Object
query_string_font (Lisp_Object string, Lisp_Object face, Lisp_Object domain)
{
- unsigned char charsets[NUM_LEADING_BYTES];
+ Charset_ID charsets[NUM_LEADING_BYTES];
struct face_cachel frame_cachel;
struct face_cachel *cachel;
int i;
* XPM *
**********************************************************************/
+#ifdef HAVE_GTK
+/* Gtk has to be gratuitously different, eh? */
+Lisp_Object
+pixmap_to_lisp_data (Lisp_Object name, int ok_if_data_invalid)
+{
+ return (make_string_from_file (name));
+}
+#else
Lisp_Object
pixmap_to_lisp_data (Lisp_Object name, int ok_if_data_invalid)
{
return Qnil; /* not reached */
}
+#endif /* !HAVE_GTK */
static void
check_valid_xpm_color_symbols (Lisp_Object data)
we have to check for overlaps. Being conservative, we will
check for exposures wholly contained by the subwindow - this
might give us what we want.*/
- if (ei->x <= x && ei->y <= y
- && ei->x + ei->width >= x + width
- && ei->y + ei->height >= y + height)
+ if (ei->x <= (unsigned) x && ei->y <= (unsigned) y
+ && ei->x + ei->width >= (unsigned) (x + width)
+ && ei->y + ei->height >= (unsigned) (y + height))
{
#ifdef DEBUG_WIDGETS
stderr_out ("ignored %d+%d, %dx%d for exposure %d+%d, %dx%d\n",
if (IMAGE_INSTANCE_SUBWINDOW_DISPLAYEDP (ii)
&&
- IMAGE_INSTANCE_DISPLAY_X (ii) <= x
+ IMAGE_INSTANCE_DISPLAY_X (ii) <= (unsigned) x
&&
- IMAGE_INSTANCE_DISPLAY_Y (ii) <= y
+ IMAGE_INSTANCE_DISPLAY_Y (ii) <= (unsigned) y
&&
IMAGE_INSTANCE_DISPLAY_X (ii)
- + IMAGE_INSTANCE_DISPLAY_WIDTH (ii) >= x + width
+ + IMAGE_INSTANCE_DISPLAY_WIDTH (ii) >= (unsigned) (x + width)
&&
IMAGE_INSTANCE_DISPLAY_Y (ii)
- + IMAGE_INSTANCE_DISPLAY_HEIGHT (ii) >= y + height)
+ + IMAGE_INSTANCE_DISPLAY_HEIGHT (ii) >= (unsigned) (y + height))
{
return 1;
}