diff options
Diffstat (limited to 'src/image.c')
| -rw-r--r-- | src/image.c | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/src/image.c b/src/image.c index 1271376bcab..f0f7ff4b01f 100644 --- a/src/image.c +++ b/src/image.c | |||
| @@ -161,13 +161,13 @@ XPutPixel (XImagePtr ximage, int x, int y, unsigned long pixel) | |||
| 161 | int | 161 | int |
| 162 | x_bitmap_height (struct frame *f, ptrdiff_t id) | 162 | x_bitmap_height (struct frame *f, ptrdiff_t id) |
| 163 | { | 163 | { |
| 164 | return FRAME_X_DISPLAY_INFO (f)->bitmaps[id - 1].height; | 164 | return FRAME_DISPLAY_INFO (f)->bitmaps[id - 1].height; |
| 165 | } | 165 | } |
| 166 | 166 | ||
| 167 | int | 167 | int |
| 168 | x_bitmap_width (struct frame *f, ptrdiff_t id) | 168 | x_bitmap_width (struct frame *f, ptrdiff_t id) |
| 169 | { | 169 | { |
| 170 | return FRAME_X_DISPLAY_INFO (f)->bitmaps[id - 1].width; | 170 | return FRAME_DISPLAY_INFO (f)->bitmaps[id - 1].width; |
| 171 | } | 171 | } |
| 172 | 172 | ||
| 173 | #if defined (HAVE_X_WINDOWS) || defined (HAVE_NTGUI) | 173 | #if defined (HAVE_X_WINDOWS) || defined (HAVE_NTGUI) |
| @@ -175,7 +175,7 @@ ptrdiff_t | |||
| 175 | x_bitmap_pixmap (struct frame *f, ptrdiff_t id) | 175 | x_bitmap_pixmap (struct frame *f, ptrdiff_t id) |
| 176 | { | 176 | { |
| 177 | /* HAVE_NTGUI needs the explicit cast here. */ | 177 | /* HAVE_NTGUI needs the explicit cast here. */ |
| 178 | return (ptrdiff_t) FRAME_X_DISPLAY_INFO (f)->bitmaps[id - 1].pixmap; | 178 | return (ptrdiff_t) FRAME_DISPLAY_INFO (f)->bitmaps[id - 1].pixmap; |
| 179 | } | 179 | } |
| 180 | #endif | 180 | #endif |
| 181 | 181 | ||
| @@ -183,7 +183,7 @@ x_bitmap_pixmap (struct frame *f, ptrdiff_t id) | |||
| 183 | int | 183 | int |
| 184 | x_bitmap_mask (struct frame *f, ptrdiff_t id) | 184 | x_bitmap_mask (struct frame *f, ptrdiff_t id) |
| 185 | { | 185 | { |
| 186 | return FRAME_X_DISPLAY_INFO (f)->bitmaps[id - 1].mask; | 186 | return FRAME_DISPLAY_INFO (f)->bitmaps[id - 1].mask; |
| 187 | } | 187 | } |
| 188 | #endif | 188 | #endif |
| 189 | 189 | ||
| @@ -192,7 +192,7 @@ x_bitmap_mask (struct frame *f, ptrdiff_t id) | |||
| 192 | static ptrdiff_t | 192 | static ptrdiff_t |
| 193 | x_allocate_bitmap_record (struct frame *f) | 193 | x_allocate_bitmap_record (struct frame *f) |
| 194 | { | 194 | { |
| 195 | Display_Info *dpyinfo = FRAME_X_DISPLAY_INFO (f); | 195 | Display_Info *dpyinfo = FRAME_DISPLAY_INFO (f); |
| 196 | ptrdiff_t i; | 196 | ptrdiff_t i; |
| 197 | 197 | ||
| 198 | if (dpyinfo->bitmaps_last < dpyinfo->bitmaps_size) | 198 | if (dpyinfo->bitmaps_last < dpyinfo->bitmaps_size) |
| @@ -213,7 +213,7 @@ x_allocate_bitmap_record (struct frame *f) | |||
| 213 | void | 213 | void |
| 214 | x_reference_bitmap (struct frame *f, ptrdiff_t id) | 214 | x_reference_bitmap (struct frame *f, ptrdiff_t id) |
| 215 | { | 215 | { |
| 216 | ++FRAME_X_DISPLAY_INFO (f)->bitmaps[id - 1].refcount; | 216 | ++FRAME_DISPLAY_INFO (f)->bitmaps[id - 1].refcount; |
| 217 | } | 217 | } |
| 218 | 218 | ||
| 219 | /* Create a bitmap for frame F from a HEIGHT x WIDTH array of bits at BITS. */ | 219 | /* Create a bitmap for frame F from a HEIGHT x WIDTH array of bits at BITS. */ |
| @@ -221,7 +221,7 @@ x_reference_bitmap (struct frame *f, ptrdiff_t id) | |||
| 221 | ptrdiff_t | 221 | ptrdiff_t |
| 222 | x_create_bitmap_from_data (struct frame *f, char *bits, unsigned int width, unsigned int height) | 222 | x_create_bitmap_from_data (struct frame *f, char *bits, unsigned int width, unsigned int height) |
| 223 | { | 223 | { |
| 224 | Display_Info *dpyinfo = FRAME_X_DISPLAY_INFO (f); | 224 | Display_Info *dpyinfo = FRAME_DISPLAY_INFO (f); |
| 225 | ptrdiff_t id; | 225 | ptrdiff_t id; |
| 226 | 226 | ||
| 227 | #ifdef HAVE_X_WINDOWS | 227 | #ifdef HAVE_X_WINDOWS |
| @@ -235,8 +235,8 @@ x_create_bitmap_from_data (struct frame *f, char *bits, unsigned int width, unsi | |||
| 235 | #ifdef HAVE_NTGUI | 235 | #ifdef HAVE_NTGUI |
| 236 | Pixmap bitmap; | 236 | Pixmap bitmap; |
| 237 | bitmap = CreateBitmap (width, height, | 237 | bitmap = CreateBitmap (width, height, |
| 238 | FRAME_X_DISPLAY_INFO (XFRAME (frame))->n_planes, | 238 | FRAME_DISPLAY_INFO (XFRAME (frame))->n_planes, |
| 239 | FRAME_X_DISPLAY_INFO (XFRAME (frame))->n_cbits, | 239 | FRAME_DISPLAY_INFO (XFRAME (frame))->n_cbits, |
| 240 | bits); | 240 | bits); |
| 241 | if (! bitmap) | 241 | if (! bitmap) |
| 242 | return -1; | 242 | return -1; |
| @@ -280,7 +280,7 @@ x_create_bitmap_from_data (struct frame *f, char *bits, unsigned int width, unsi | |||
| 280 | ptrdiff_t | 280 | ptrdiff_t |
| 281 | x_create_bitmap_from_file (struct frame *f, Lisp_Object file) | 281 | x_create_bitmap_from_file (struct frame *f, Lisp_Object file) |
| 282 | { | 282 | { |
| 283 | Display_Info *dpyinfo = FRAME_X_DISPLAY_INFO (f); | 283 | Display_Info *dpyinfo = FRAME_DISPLAY_INFO (f); |
| 284 | 284 | ||
| 285 | #ifdef HAVE_NTGUI | 285 | #ifdef HAVE_NTGUI |
| 286 | return -1; /* W32_TODO : bitmap support */ | 286 | return -1; /* W32_TODO : bitmap support */ |
| @@ -379,7 +379,7 @@ free_bitmap_record (Display_Info *dpyinfo, Bitmap_Record *bm) | |||
| 379 | void | 379 | void |
| 380 | x_destroy_bitmap (struct frame *f, ptrdiff_t id) | 380 | x_destroy_bitmap (struct frame *f, ptrdiff_t id) |
| 381 | { | 381 | { |
| 382 | Display_Info *dpyinfo = FRAME_X_DISPLAY_INFO (f); | 382 | Display_Info *dpyinfo = FRAME_DISPLAY_INFO (f); |
| 383 | 383 | ||
| 384 | if (id > 0) | 384 | if (id > 0) |
| 385 | { | 385 | { |
| @@ -454,7 +454,7 @@ x_create_bitmap_mask (struct frame *f, ptrdiff_t id) | |||
| 454 | unsigned long x, y, xp, xm, yp, ym; | 454 | unsigned long x, y, xp, xm, yp, ym; |
| 455 | GC gc; | 455 | GC gc; |
| 456 | 456 | ||
| 457 | Display_Info *dpyinfo = FRAME_X_DISPLAY_INFO (f); | 457 | Display_Info *dpyinfo = FRAME_DISPLAY_INFO (f); |
| 458 | 458 | ||
| 459 | if (!(id > 0)) | 459 | if (!(id > 0)) |
| 460 | return; | 460 | return; |
| @@ -3421,7 +3421,7 @@ xpm_image_p (Lisp_Object object) | |||
| 3421 | ptrdiff_t | 3421 | ptrdiff_t |
| 3422 | x_create_bitmap_from_xpm_data (struct frame *f, const char **bits) | 3422 | x_create_bitmap_from_xpm_data (struct frame *f, const char **bits) |
| 3423 | { | 3423 | { |
| 3424 | Display_Info *dpyinfo = FRAME_X_DISPLAY_INFO (f); | 3424 | Display_Info *dpyinfo = FRAME_DISPLAY_INFO (f); |
| 3425 | ptrdiff_t id; | 3425 | ptrdiff_t id; |
| 3426 | int rc; | 3426 | int rc; |
| 3427 | XpmAttributes attrs; | 3427 | XpmAttributes attrs; |
| @@ -4325,7 +4325,7 @@ lookup_rgb_color (struct frame *f, int r, int g, int b) | |||
| 4325 | two orders of magnitude. Freeing colors on TrueColor visuals is | 4325 | two orders of magnitude. Freeing colors on TrueColor visuals is |
| 4326 | a nop, and pixel colors specify RGB values directly. See also | 4326 | a nop, and pixel colors specify RGB values directly. See also |
| 4327 | the Xlib spec, chapter 3.1. */ | 4327 | the Xlib spec, chapter 3.1. */ |
| 4328 | dpyinfo = FRAME_X_DISPLAY_INFO (f); | 4328 | dpyinfo = FRAME_DISPLAY_INFO (f); |
| 4329 | if (dpyinfo->red_bits > 0) | 4329 | if (dpyinfo->red_bits > 0) |
| 4330 | { | 4330 | { |
| 4331 | unsigned long pr, pg, pb; | 4331 | unsigned long pr, pg, pb; |
| @@ -4820,7 +4820,7 @@ x_edge_detection (struct frame *f, struct image *img, Lisp_Object matrix, | |||
| 4820 | static void | 4820 | static void |
| 4821 | x_disable_image (struct frame *f, struct image *img) | 4821 | x_disable_image (struct frame *f, struct image *img) |
| 4822 | { | 4822 | { |
| 4823 | Display_Info *dpyinfo = FRAME_X_DISPLAY_INFO (f); | 4823 | Display_Info *dpyinfo = FRAME_DISPLAY_INFO (f); |
| 4824 | #ifdef HAVE_NTGUI | 4824 | #ifdef HAVE_NTGUI |
| 4825 | int n_planes = dpyinfo->n_planes * dpyinfo->n_cbits; | 4825 | int n_planes = dpyinfo->n_planes * dpyinfo->n_cbits; |
| 4826 | #else | 4826 | #else |