ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/background.C
(Generate patch)

Comparing rxvt-unicode/src/background.C (file contents):
Revision 1.220 by sf-exg, Fri May 25 08:27:47 2012 UTC vs.
Revision 1.230 by sf-exg, Sun Jun 3 15:50:22 2012 UTC

58# endif 58# endif
59 59
60void 60void
61rxvt_term::bg_destroy () 61rxvt_term::bg_destroy ()
62{ 62{
63# ifdef BG_IMAGE_FROM_FILE
64 for (vector<rxvt_image>::iterator bg_image = image_vec.begin (); bg_image < image_vec.end (); bg_image++)
65 bg_image->destroy ();
66# endif
67
63 if (bg_pixmap) 68 if (bg_pixmap)
64 XFreePixmap (dpy, bg_pixmap); 69 XFreePixmap (dpy, bg_pixmap);
65} 70}
66 71
67bool 72bool
298 h_align = x; 303 h_align = x;
299 v_align = y; 304 v_align = y;
300 changed = true; 305 changed = true;
301 } 306 }
302 307
303 if (!(flags & IM_TILE) 308 if (is_size_sensitive ())
304 || h_scale || v_scale
305 || (!(flags & IM_ROOT_ALIGN) && (h_align || v_align)))
306 flags |= IM_IS_SIZE_SENSITIVE; 309 flags |= IM_IS_SIZE_SENSITIVE;
307 else 310 else
308 flags &= ~IM_IS_SIZE_SENSITIVE; 311 flags &= ~IM_IS_SIZE_SENSITIVE;
309 312
310 return changed; 313 return changed;
481 return false; 484 return false;
482 485
483 bool need_blend = bg_flags & BG_IS_VALID; 486 bool need_blend = bg_flags & BG_IS_VALID;
484 487
485 if (need_blend 488 if (need_blend
486 && !(bg_flags & BG_HAS_RENDER)) 489 && !(display->flags & DISPLAY_HAS_RENDER))
487 return false; 490 return false;
488 491
489 GdkPixbuf *result; 492 GdkPixbuf *result;
490 493
491 int image_width = gdk_pixbuf_get_width (pixbuf); 494 int image_width = gdk_pixbuf_get_width (pixbuf);
600 src_x, src_y, 603 src_x, src_y,
601 dst_x, dst_y, 604 dst_x, dst_y,
602 dst_width, dst_height, need_blend); 605 dst_width, dst_height, need_blend);
603 } 606 }
604 607
608 if (image.need_blur ())
609 blur_pixmap (tmp_pixmap, new_pmap_width, new_pmap_height, need_blend, image.h_blurRadius, image.v_blurRadius);
610 if (image.need_tint ())
611 tint_pixmap (tmp_pixmap, new_pmap_width, new_pmap_height, need_blend, image.tint, image.tint_set, image.shade);
612
605#if XRENDER 613#if XRENDER
606 if (need_blend) 614 if (need_blend)
607 { 615 {
608 XRenderPictFormat *argb_format = XRenderFindStandardFormat (dpy, PictStandardARGB32); 616 XRenderPictFormat *argb_format = XRenderFindStandardFormat (dpy, PictStandardARGB32);
609 XRenderPictFormat *format = XRenderFindVisualFormat (dpy, visual); 617 XRenderPictFormat *format = XRenderFindVisualFormat (dpy, visual);
614 622
615 Picture mask = create_xrender_mask (dpy, vt, False, False); 623 Picture mask = create_xrender_mask (dpy, vt, False, False);
616 624
617 XRenderColor mask_c; 625 XRenderColor mask_c;
618 626
619 mask_c.alpha = gdk_pixbuf_get_has_alpha (image.pixbuf) ? 0xffff : image.alpha; 627 mask_c.alpha = image.alpha;
620 mask_c.red = 628 mask_c.red =
621 mask_c.green = 629 mask_c.green =
622 mask_c.blue = 0; 630 mask_c.blue = 0;
623 XRenderFillRectangle (dpy, PictOpSrc, mask, &mask_c, 0, 0, 1, 1); 631 XRenderFillRectangle (dpy, PictOpSrc, mask, &mask_c, 0, 0, 1, 1);
624 632
665 if (id >= 1) 673 if (id >= 1)
666 GET_R->parse_image (id, XrmQuarkToString (quarks[size-1]), (char *)value->addr); 674 GET_R->parse_image (id, XrmQuarkToString (quarks[size-1]), (char *)value->addr);
667 } 675 }
668 return False; 676 return False;
669} 677}
678# endif
670 679
671void 680void
672rxvt_term::parse_image (int id, const char *type, const char *arg) 681rxvt_term::parse_image (int id, const char *type, const char *arg)
673{ 682{
674 rxvt_image *image; 683 if (image_vec.size () < id + 1)
684 image_vec.resize (id + 1);
675 685
676 for (image = image_vec.begin (); image < image_vec.end (); image++) 686 rxvt_image *image = &image_vec[id];
677 if (image->id == id)
678 break;
679
680 if (image == image_vec.end ())
681 {
682 image = new_image ();
683 image->id = id;
684 }
685} 687}
686# endif
687 688
688rxvt_image::rxvt_image () 689rxvt_image::rxvt_image ()
689{ 690{
690 id = 691 alpha = 0xffff;
691 alpha =
692 flags = 692 flags = 0;
693 h_scale = 693 h_scale =
694 v_scale = 694 v_scale = defaultScale;
695 h_align = 695 h_align =
696 v_align = 0; 696 v_align = defaultAlign;
697 697
698# ifdef HAVE_PIXBUF 698# ifdef HAVE_PIXBUF
699 pixbuf.reset (0); 699 pixbuf = 0;
700# endif 700# endif
701} 701}
702 702
703bool 703bool
704rxvt_image::set_file_geometry (const char *file) 704rxvt_image::set_file_geometry (const char *file)
717 file = f; 717 file = f;
718 } 718 }
719 719
720 bool ret = set_file (file); 720 bool ret = set_file (file);
721 alpha = 0x8000; 721 alpha = 0x8000;
722 if (ret && p) 722 if (ret)
723 set_geometry (p + 1); 723 set_geometry (p ? p + 1 : "");
724 return ret; 724 return ret;
725} 725}
726 726
727bool 727bool
728rxvt_image::set_file (const char *file) 728rxvt_image::set_file (const char *file)
733 GdkPixbuf *image = gdk_pixbuf_new_from_file (file, NULL); 733 GdkPixbuf *image = gdk_pixbuf_new_from_file (file, NULL);
734 if (image) 734 if (image)
735 { 735 {
736 if (pixbuf) 736 if (pixbuf)
737 g_object_unref (pixbuf); 737 g_object_unref (pixbuf);
738 pixbuf.reset (image); 738 pixbuf = image;
739 ret = true; 739 ret = true;
740 } 740 }
741# endif 741# endif
742 742
743 if (ret) 743 if (ret)
744 { 744 flags |= IM_IS_SET;
745 alpha = 0xffff;
746 flags = IM_IS_SET | IM_IS_SIZE_SENSITIVE;
747 h_scale = v_scale = defaultScale;
748 h_align = v_align = defaultAlign;
749 }
750 745
751 return ret; 746 return ret;
752} 747}
753 748
754# endif /* BG_IMAGE_FROM_FILE */ 749# endif /* BG_IMAGE_FROM_FILE */
755 750
756# ifdef ENABLE_TRANSPARENCY
757bool 751bool
758rxvt_term::bg_set_blur (const char *geom) 752image_effects::set_blur (const char *geom)
759{ 753{
760 bool changed = false; 754 bool changed = false;
761 unsigned int hr, vr; 755 unsigned int hr, vr;
762 int junk; 756 int junk;
763 int geom_flags = XParseGeometry (geom, &junk, &junk, &hr, &vr); 757 int geom_flags = XParseGeometry (geom, &junk, &junk, &hr, &vr);
784 778
785 return changed; 779 return changed;
786} 780}
787 781
788bool 782bool
789rxvt_term::bg_set_tint (rxvt_color &new_tint) 783image_effects::set_tint (const rxvt_color &new_tint)
790{ 784{
791 if (!(bg_flags & BG_TINT_SET) || tint != new_tint) 785 if (!tint_set || tint != new_tint)
792 { 786 {
793 tint = new_tint; 787 tint = new_tint;
794 bg_flags |= BG_TINT_SET; 788 tint_set = true;
795
796 rgba c;
797 tint.get (c);
798 if ((c.r <= 0x00ff || c.r >= 0xff00)
799 && (c.g <= 0x00ff || c.g >= 0xff00)
800 && (c.b <= 0x00ff || c.b >= 0xff00))
801 bg_flags |= BG_TINT_BITAND;
802 else
803 bg_flags &= ~BG_TINT_BITAND;
804 789
805 return true; 790 return true;
806 } 791 }
807 792
808 return false; 793 return false;
809} 794}
810 795
811bool 796bool
812rxvt_term::bg_set_shade (const char *shade_str) 797image_effects::set_shade (const char *shade_str)
813{ 798{
814 int new_shade = atoi (shade_str); 799 int new_shade = atoi (shade_str);
815 800
816 clamp_it (new_shade, -100, 200); 801 clamp_it (new_shade, -100, 200);
817 if (new_shade < 0) 802 if (new_shade < 0)
848 params[i+2] = XDoubleToFixed (kernel[i] / sum); 833 params[i+2] = XDoubleToFixed (kernel[i] / sum);
849} 834}
850#endif 835#endif
851 836
852bool 837bool
853rxvt_term::blur_pixmap (Pixmap pixmap, int width, int height) 838rxvt_term::blur_pixmap (Pixmap pixmap, int width, int height, bool argb, int h_blurRadius, int v_blurRadius)
854{ 839{
855 bool ret = false; 840 bool ret = false;
856#if XRENDER 841#if XRENDER
857 if (!(bg_flags & BG_HAS_RENDER_CONV)) 842 if (!(display->flags & DISPLAY_HAS_RENDER_CONV))
858 return false; 843 return false;
859 844
860 int size = max (h_blurRadius, v_blurRadius) * 2 + 1; 845 int size = max (h_blurRadius, v_blurRadius) * 2 + 1;
861 double *kernel = (double *)malloc (size * sizeof (double)); 846 double *kernel = (double *)malloc (size * sizeof (double));
862 XFixed *params = (XFixed *)malloc ((size + 2) * sizeof (XFixed)); 847 XFixed *params = (XFixed *)malloc ((size + 2) * sizeof (XFixed));
863 848
864 XRenderPictureAttributes pa; 849 XRenderPictureAttributes pa;
865 XRenderPictFormat *format = XRenderFindVisualFormat (dpy, visual); 850 XRenderPictFormat *format = argb ? XRenderFindStandardFormat (dpy, PictStandardARGB32)
851 : XRenderFindVisualFormat (dpy, visual);
866 852
867 pa.repeat = RepeatPad; 853 pa.repeat = RepeatPad;
868 Picture src = XRenderCreatePicture (dpy, pixmap, format, CPRepeat, &pa); 854 Picture src = XRenderCreatePicture (dpy, pixmap, format, CPRepeat, &pa);
869 Pixmap tmp = XCreatePixmap (dpy, pixmap, width, height, depth); 855 Pixmap tmp = XCreatePixmap (dpy, pixmap, width, height, depth);
870 Picture dst = XRenderCreatePicture (dpy, tmp, format, CPRepeat, &pa); 856 Picture dst = XRenderCreatePicture (dpy, tmp, format, CPRepeat, &pa);
913#endif 899#endif
914 return ret; 900 return ret;
915} 901}
916 902
917bool 903bool
918rxvt_term::tint_pixmap (Pixmap pixmap, int width, int height) 904rxvt_term::tint_pixmap (Pixmap pixmap, int width, int height, bool argb, rxvt_color &tint, bool tint_set, int shade)
919{ 905{
920 bool ret = false; 906 bool ret = false;
921 907
922 if (shade == 100 && (bg_flags & BG_TINT_BITAND)) 908 rgba c (rgba::MAX_CC, rgba::MAX_CC, rgba::MAX_CC);
909
910 if (tint_set)
911 tint.get (c);
912
913 if (shade == 100
914 && (c.r <= 0x00ff || c.r >= 0xff00)
915 && (c.g <= 0x00ff || c.g >= 0xff00)
916 && (c.b <= 0x00ff || c.b >= 0xff00))
923 { 917 {
924 XGCValues gcv; 918 XGCValues gcv;
925 GC gc; 919 GC gc;
926 920
927 /* In this case we can tint image server-side getting significant 921 /* In this case we can tint image server-side getting significant
937 ret = true; 931 ret = true;
938 XFreeGC (dpy, gc); 932 XFreeGC (dpy, gc);
939 } 933 }
940 } 934 }
941# if XRENDER 935# if XRENDER
942 else if (bg_flags & BG_HAS_RENDER) 936 else if (display->flags & DISPLAY_HAS_RENDER)
943 { 937 {
944 rgba c (rgba::MAX_CC, rgba::MAX_CC, rgba::MAX_CC);
945
946 if (bg_flags & BG_TINT_SET)
947 tint.get (c);
948
949 if (shade <= 100) 938 if (shade <= 100)
950 { 939 {
951 c.r = c.r * shade / 100; 940 c.r = c.r * shade / 100;
952 c.g = c.g * shade / 100; 941 c.g = c.g * shade / 100;
953 c.b = c.b * shade / 100; 942 c.b = c.b * shade / 100;
957 c.r = c.r * (200 - shade) / 100; 946 c.r = c.r * (200 - shade) / 100;
958 c.g = c.g * (200 - shade) / 100; 947 c.g = c.g * (200 - shade) / 100;
959 c.b = c.b * (200 - shade) / 100; 948 c.b = c.b * (200 - shade) / 100;
960 } 949 }
961 950
962 XRenderPictFormat *format = XRenderFindVisualFormat (dpy, visual); 951 XRenderPictFormat *format = argb ? XRenderFindStandardFormat (dpy, PictStandardARGB32)
952 : XRenderFindVisualFormat (dpy, visual);
963 953
964 Picture back_pic = XRenderCreatePicture (dpy, pixmap, format, 0, 0); 954 Picture back_pic = XRenderCreatePicture (dpy, pixmap, format, 0, 0);
965 955
966 Picture overlay_pic = create_xrender_mask (dpy, pixmap, True, False); 956 Picture overlay_pic = create_xrender_mask (dpy, pixmap, True, False);
967 957
1003# endif 993# endif
1004 994
1005 return ret; 995 return ret;
1006} 996}
1007 997
998# ifdef ENABLE_TRANSPARENCY
1008/* 999/*
1009 * Builds a pixmap of the same size as the terminal window that contains 1000 * Builds a pixmap of the same size as the terminal window that contains
1010 * the tiled portion of the root pixmap that is supposed to be covered by 1001 * the tiled portion of the root pixmap that is supposed to be covered by
1011 * our window. 1002 * our window.
1012 */ 1003 */
1013bool 1004bool
1014rxvt_term::make_transparency_pixmap () 1005rxvt_term::render_root_image ()
1015{ 1006{
1016 bool ret = false; 1007 bool ret = false;
1017 1008
1018 /* root dimensions may change from call to call - but Display structure should 1009 /* root dimensions may change from call to call - but Display structure should
1019 * be always up-to-date, so let's use it : 1010 * be always up-to-date, so let's use it :
1055 Pixmap recoded_root_pmap = root_pixmap; 1046 Pixmap recoded_root_pmap = root_pixmap;
1056 1047
1057 if (root_pixmap != None && root_depth != depth) 1048 if (root_pixmap != None && root_depth != depth)
1058 { 1049 {
1059#if XRENDER 1050#if XRENDER
1060 if (bg_flags & BG_HAS_RENDER) 1051 if (display->flags & DISPLAY_HAS_RENDER)
1061 { 1052 {
1062 recoded_root_pmap = XCreatePixmap (dpy, vt, root_pmap_width, root_pmap_height, depth); 1053 recoded_root_pmap = XCreatePixmap (dpy, vt, root_pmap_width, root_pmap_height, depth);
1063 1054
1064 XRenderPictFormat *src_format = XRenderFindVisualFormat (dpy, DefaultVisual (dpy, screen)); 1055 XRenderPictFormat *src_format = XRenderFindVisualFormat (dpy, DefaultVisual (dpy, screen));
1065 Picture src = XRenderCreatePicture (dpy, root_pixmap, src_format, 0, 0); 1056 Picture src = XRenderCreatePicture (dpy, root_pixmap, src_format, 0, 0);
1103 1094
1104 if (gc) 1095 if (gc)
1105 { 1096 {
1106 XFillRectangle (dpy, bg_pixmap, gc, 0, 0, window_width, window_height); 1097 XFillRectangle (dpy, bg_pixmap, gc, 0, 0, window_width, window_height);
1107 ret = true; 1098 ret = true;
1108 bool need_blur = h_blurRadius && v_blurRadius; 1099 bool need_blur = root_effects.need_blur ();
1109 bool need_tint = shade != 100 || (bg_flags & BG_TINT_SET); 1100 bool need_tint = root_effects.need_tint ();
1110 1101
1111 if (!(bg_flags & BG_CLIENT_RENDER))
1112 {
1113 if (need_blur) 1102 if (need_blur)
1103 {
1104 if (blur_pixmap (bg_pixmap, window_width, window_height, false,
1105 root_effects.h_blurRadius, root_effects.v_blurRadius))
1106 need_blur = false;
1107 }
1108 if (need_tint)
1109 {
1110 if (tint_pixmap (bg_pixmap, window_width, window_height, false,
1111 root_effects.tint, root_effects.tint_set, root_effects.shade))
1112 need_tint = false;
1113 }
1114 if (need_tint)
1115 {
1116 XImage *ximage = XGetImage (dpy, bg_pixmap, 0, 0, bg_pmap_width, bg_pmap_height, AllPlanes, ZPixmap);
1117 if (ximage)
1114 { 1118 {
1115 if (blur_pixmap (bg_pixmap, window_width, window_height)) 1119 /* our own client-side tinting */
1116 need_blur = false; 1120 tint_ximage (ximage, root_effects.tint, root_effects.tint_set, root_effects.shade);
1121
1122 XPutImage (dpy, bg_pixmap, gc, ximage, 0, 0, 0, 0, ximage->width, ximage->height);
1123 XDestroyImage (ximage);
1117 } 1124 }
1118 if (need_tint)
1119 {
1120 if (tint_pixmap (bg_pixmap, window_width, window_height))
1121 need_tint = false;
1122 } 1125 }
1123 if (need_tint)
1124 {
1125 XImage *ximage = XGetImage (dpy, bg_pixmap, 0, 0, bg_pmap_width, bg_pmap_height, AllPlanes, ZPixmap);
1126 if (ximage)
1127 {
1128 /* our own client-side tinting */
1129 tint_ximage (ximage);
1130
1131 XPutImage (dpy, bg_pixmap, gc, ximage, 0, 0, 0, 0, ximage->width, ximage->height);
1132 XDestroyImage (ximage);
1133 }
1134 }
1135 } /* server side rendering completed */
1136 1126
1137 XFreeGC (dpy, gc); 1127 XFreeGC (dpy, gc);
1138 } 1128 }
1139 1129
1140 if (recoded_root_pmap != root_pixmap) 1130 if (recoded_root_pmap != root_pixmap)
1160 bg_invalidate (); 1150 bg_invalidate ();
1161# ifdef ENABLE_TRANSPARENCY 1151# ifdef ENABLE_TRANSPARENCY
1162 if (bg_flags & BG_IS_TRANSPARENT) 1152 if (bg_flags & BG_IS_TRANSPARENT)
1163 { 1153 {
1164 /* we need to re-generate transparency pixmap in that case ! */ 1154 /* we need to re-generate transparency pixmap in that case ! */
1165 if (make_transparency_pixmap ()) 1155 if (render_root_image ())
1166 bg_flags |= BG_IS_VALID; 1156 bg_flags |= BG_IS_VALID;
1167 } 1157 }
1168# endif 1158# endif
1169 1159
1170# ifdef BG_IMAGE_FROM_FILE 1160# ifdef BG_IMAGE_FROM_FILE
1193} 1183}
1194 1184
1195void 1185void
1196rxvt_term::bg_init () 1186rxvt_term::bg_init ()
1197{ 1187{
1198#ifdef ENABLE_TRANSPARENCY
1199 shade = 100;
1200#endif
1201
1202 bg_flags &= ~(BG_HAS_RENDER | BG_HAS_RENDER_CONV);
1203#if XRENDER
1204 int major, minor;
1205 if (XRenderQueryVersion (dpy, &major, &minor))
1206 bg_flags |= BG_HAS_RENDER;
1207 XFilters *filters = XRenderQueryFilters (dpy, vt);
1208 if (filters)
1209 {
1210 for (int i = 0; i < filters->nfilter; i++)
1211 if (!strcmp (filters->filter[i], FilterConvolution))
1212 bg_flags |= BG_HAS_RENDER_CONV;
1213
1214 XFree (filters);
1215 }
1216#endif
1217
1218#ifdef BG_IMAGE_FROM_FILE 1188#ifdef BG_IMAGE_FROM_FILE
1219 if (rs[Rs_backgroundPixmap]) 1189 if (rs[Rs_backgroundPixmap])
1220 { 1190 {
1221 rxvt_image *image = new_image (); 1191 rxvt_image *image = new_image ();
1222 if (!image->set_file_geometry (rs[Rs_backgroundPixmap])) 1192 if (!image->set_file_geometry (rs[Rs_backgroundPixmap]))
1223 image_vec.pop_back (); 1193 image_vec.pop_back ();
1224 } 1194 }
1225 1195
1226# ifndef NO_RESOURCES 1196# ifndef NO_RESOURCES
1227 find_resources ("image", "Image", XrmEnumAllLevels, rxvt_define_image); 1197 find_resources ("image", "Image", XrmEnumAllLevels, rxvt_define_image);
1198# endif
1199
1228 vector<rxvt_image>::iterator bg_image = image_vec.begin (); 1200 vector<rxvt_image>::iterator bg_image = image_vec.begin ();
1229 while (bg_image != image_vec.end ()) 1201 while (bg_image != image_vec.end ())
1230 { 1202 {
1231 if (!(bg_image->flags & IM_IS_SET)) 1203 if (!(bg_image->flags & IM_IS_SET))
1232 bg_image = image_vec.erase (bg_image); 1204 bg_image = image_vec.erase (bg_image);
1233 else 1205 else
1206 {
1207 if (bg_image->is_size_sensitive ())
1208 bg_image->flags |= IM_IS_SIZE_SENSITIVE;
1209
1234 bg_image++; 1210 bg_image++;
1211 }
1235 } 1212 }
1236# endif
1237 1213
1238 if (image_vec.size () > 0 1214 if (image_vec.size () > 0
1239 && !bg_window_position_sensitive ()) 1215 && !bg_window_position_sensitive ())
1240 update_background (); 1216 update_background ();
1241#endif 1217#endif
1242} 1218}
1243 1219
1244#endif /* HAVE_BG_PIXMAP */
1245
1246#ifdef ENABLE_TRANSPARENCY
1247/* based on code from aterm-0.4.2 */ 1220/* based on code from aterm-0.4.2 */
1248 1221
1249static inline void 1222static inline void
1250fill_lut (uint32_t *lookup, uint32_t mask, int sh, unsigned short low, unsigned short high) 1223fill_lut (uint32_t *lookup, uint32_t mask, int sh, unsigned short low, unsigned short high)
1251{ 1224{
1257 lookup[i] = (tmp / 0xffff) << sh; 1230 lookup[i] = (tmp / 0xffff) << sh;
1258 } 1231 }
1259} 1232}
1260 1233
1261void 1234void
1262rxvt_term::tint_ximage (XImage *ximage) 1235rxvt_term::tint_ximage (XImage *ximage, rxvt_color &tint, bool tint_set, int shade)
1263{ 1236{
1264 unsigned int size_r, size_g, size_b; 1237 unsigned int size_r, size_g, size_b;
1265 int sh_r, sh_g, sh_b; 1238 int sh_r, sh_g, sh_b;
1266 uint32_t mask_r, mask_g, mask_b; 1239 uint32_t mask_r, mask_g, mask_b;
1267 uint32_t *lookup, *lookup_r, *lookup_g, *lookup_b; 1240 uint32_t *lookup, *lookup_r, *lookup_g, *lookup_b;
1292 lookup_g = lookup + size_r; 1265 lookup_g = lookup + size_r;
1293 lookup_b = lookup + size_r + size_g; 1266 lookup_b = lookup + size_r + size_g;
1294 1267
1295 rgba c (rgba::MAX_CC, rgba::MAX_CC, rgba::MAX_CC); 1268 rgba c (rgba::MAX_CC, rgba::MAX_CC, rgba::MAX_CC);
1296 1269
1297 if (bg_flags & BG_TINT_SET) 1270 if (tint_set)
1298 tint.get (c); 1271 tint.get (c);
1299 1272
1300 /* prepare limits for color transformation (each channel is handled separately) */ 1273 /* prepare limits for color transformation (each channel is handled separately) */
1301 if (shade > 100) 1274 if (shade > 100)
1302 { 1275 {
1352 } 1325 }
1353 } 1326 }
1354 1327
1355 free (lookup); 1328 free (lookup);
1356} 1329}
1357#endif /* ENABLE_TRANSPARENCY */ 1330
1331#endif /* HAVE_BG_PIXMAP */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines