Mercurial > emacs
comparison src/macfns.c @ 53332:21301d0e0505
(Qimage): Remove extern (now in lisp.h).
(valid_image_p, parse_image_spec): Use IMAGEP macro.
author | Kim F. Storm <storm@cua.dk> |
---|---|
date | Sun, 28 Dec 2003 00:11:49 +0000 |
parents | 695cf19ef79e |
children | 0093eae529e8 |
comparison
equal
deleted
inserted
replaced
53331:db670c1b5944 | 53332:21301d0e0505 |
---|---|
3458 /* List of supported image types. Use define_image_type to add new | 3458 /* List of supported image types. Use define_image_type to add new |
3459 types. Use lookup_image_type to find a type for a given symbol. */ | 3459 types. Use lookup_image_type to find a type for a given symbol. */ |
3460 | 3460 |
3461 static struct image_type *image_types; | 3461 static struct image_type *image_types; |
3462 | 3462 |
3463 /* The symbol `image' which is the car of the lists used to represent | |
3464 images in Lisp. */ | |
3465 | |
3466 extern Lisp_Object Qimage; | |
3467 | |
3468 /* The symbol `xbm' which is used as the type symbol for XBM images. */ | 3463 /* The symbol `xbm' which is used as the type symbol for XBM images. */ |
3469 | 3464 |
3470 Lisp_Object Qxbm; | 3465 Lisp_Object Qxbm; |
3471 | 3466 |
3472 /* Keywords. */ | 3467 /* Keywords. */ |
3541 valid_image_p (object) | 3536 valid_image_p (object) |
3542 Lisp_Object object; | 3537 Lisp_Object object; |
3543 { | 3538 { |
3544 int valid_p = 0; | 3539 int valid_p = 0; |
3545 | 3540 |
3546 if (CONSP (object) && EQ (XCAR (object), Qimage)) | 3541 if (IMAGEP (object)) |
3547 { | 3542 { |
3548 Lisp_Object symbol = Fplist_get (XCDR (object), QCtype); | 3543 Lisp_Object symbol = Fplist_get (XCDR (object), QCtype); |
3549 struct image_type *type = lookup_image_type (symbol); | 3544 struct image_type *type = lookup_image_type (symbol); |
3550 | 3545 |
3551 if (type) | 3546 if (type) |
3631 Lisp_Object type; | 3626 Lisp_Object type; |
3632 { | 3627 { |
3633 int i; | 3628 int i; |
3634 Lisp_Object plist; | 3629 Lisp_Object plist; |
3635 | 3630 |
3636 if (!CONSP (spec) || !EQ (XCAR (spec), Qimage)) | 3631 if (!IMAGEP (spec)) |
3637 return 0; | 3632 return 0; |
3638 | 3633 |
3639 plist = XCDR (spec); | 3634 plist = XCDR (spec); |
3640 while (CONSP (plist)) | 3635 while (CONSP (plist)) |
3641 { | 3636 { |