comparison src/glyphs-x.c @ 444:576fb035e263 r21-2-37

Import from CVS: tag r21-2-37
author cvs
date Mon, 13 Aug 2007 11:36:19 +0200
parents abe6d1db359e
children 1ccc32a20af4
comparison
equal deleted inserted replaced
443:a8296e22da4e 444:576fb035e263
998 corresponding X object. */ 998 corresponding X object. */
999 999
1000 static Pixmap 1000 static Pixmap
1001 pixmap_from_xbm_inline (Lisp_Object device, int width, int height, 1001 pixmap_from_xbm_inline (Lisp_Object device, int width, int height,
1002 /* Note that data is in ext-format! */ 1002 /* Note that data is in ext-format! */
1003 const Extbyte *bits) 1003 const char *bits)
1004 { 1004 {
1005 return XCreatePixmapFromBitmapData (DEVICE_X_DISPLAY (XDEVICE(device)), 1005 return XCreatePixmapFromBitmapData
1006 XtWindow (DEVICE_XT_APP_SHELL (XDEVICE (device))), 1006 (DEVICE_X_DISPLAY (XDEVICE (device)),
1007 (char *) bits, width, height, 1007 XtWindow (DEVICE_XT_APP_SHELL (XDEVICE (device))),
1008 1, 0, 1); 1008 (char *) bits, width, height,
1009 1, 0, 1);
1009 } 1010 }
1010 1011
1011 /* Given inline data for a mono pixmap, initialize the given 1012 /* Given inline data for a mono pixmap, initialize the given
1012 image instance accordingly. */ 1013 image instance accordingly. */
1013 1014
1166 1167
1167 LISP_STRING_TO_EXTERNAL (XCAR (XCDR (XCDR (mask_data))), ext_data, Qbinary); 1168 LISP_STRING_TO_EXTERNAL (XCAR (XCDR (XCDR (mask_data))), ext_data, Qbinary);
1168 mask = pixmap_from_xbm_inline (IMAGE_INSTANCE_DEVICE (ii), 1169 mask = pixmap_from_xbm_inline (IMAGE_INSTANCE_DEVICE (ii),
1169 XINT (XCAR (mask_data)), 1170 XINT (XCAR (mask_data)),
1170 XINT (XCAR (XCDR (mask_data))), 1171 XINT (XCAR (XCDR (mask_data))),
1171 (const unsigned char *) ext_data); 1172 ext_data);
1172 } 1173 }
1173 1174
1174 init_image_instance_from_xbm_inline (ii, width, height, bits, 1175 init_image_instance_from_xbm_inline (ii, width, height, bits,
1175 instantiator, pointer_fg, pointer_bg, 1176 instantiator, pointer_fg, pointer_bg,
1176 dest_mask, mask, mask_file); 1177 dest_mask, mask, mask_file);
2207 /* Assume the lotus position, breath deeply and chant to 2208 /* Assume the lotus position, breath deeply and chant to
2208 yourself lwlibsux, lwlibsux ... lw_get_all_values returns a 2209 yourself lwlibsux, lwlibsux ... lw_get_all_values returns a
2209 reference to the real values rather than a copy thus any 2210 reference to the real values rather than a copy thus any
2210 changes we make to the values we get back will look like they 2211 changes we make to the values we get back will look like they
2211 have already been applied. If we rebuild the widget tree then 2212 have already been applied. If we rebuild the widget tree then
2212 we may lose propertie. */ 2213 we may lose properties. */
2213 wv = copy_widget_value_tree (lw_get_all_values 2214 wv = copy_widget_value_tree (lw_get_all_values
2214 (IMAGE_INSTANCE_X_WIDGET_LWID (p)), 2215 (IMAGE_INSTANCE_X_WIDGET_LWID (p)),
2215 NO_CHANGE); 2216 NO_CHANGE);
2216 } 2217 }
2217 2218
2218 /* Possibly update the colors and font */ 2219 /* Possibly update the colors and font */
2978 Fadd_spec_to_specifier \ 2979 Fadd_spec_to_specifier \
2979 (GLYPH_IMAGE (XGLYPH (variable)), \ 2980 (GLYPH_IMAGE (XGLYPH (variable)), \
2980 vector3 (Qxbm, Q_data, \ 2981 vector3 (Qxbm, Q_data, \
2981 list3 (make_int (name##_width), \ 2982 list3 (make_int (name##_width), \
2982 make_int (name##_height), \ 2983 make_int (name##_height), \
2983 make_ext_string (name##_bits, \ 2984 make_ext_string ((Extbyte *) name##_bits, \
2984 sizeof (name##_bits), \ 2985 sizeof (name##_bits), \
2985 Qbinary))), \ 2986 Qbinary))), \
2986 Qglobal, Qx, Qnil) 2987 Qglobal, Qx, Qnil)
2987 2988
2988 BUILD_GLYPH_INST (Vtruncation_glyph, truncator); 2989 BUILD_GLYPH_INST (Vtruncation_glyph, truncator);