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

Comparing rxvt-unicode/src/init.C (file contents):
Revision 1.283 by sf-exg, Wed Oct 13 23:04:57 2010 UTC vs.
Revision 1.292 by sf-exg, Thu Jan 27 17:37:19 2011 UTC

143 143
144 return rval; 144 return rval;
145} 145}
146#endif 146#endif
147 147
148const char *const def_colorName[] = 148static const char *const def_colorName[] =
149 { 149 {
150 COLOR_FOREGROUND, 150 COLOR_FOREGROUND,
151 COLOR_BACKGROUND, 151 COLOR_BACKGROUND,
152 /* low-intensity colors */ 152 /* low-intensity colors */
153 "rgb:00/00/00", // 0: black (Black) 153 "rgb:00/00/00", // 0: black (Black)
634 set_output_threshold (OUTPUT_LEVEL_WARNING); 634 set_output_threshold (OUTPUT_LEVEL_WARNING);
635#endif 635#endif
636 636
637#ifdef HAVE_PIXBUF 637#ifdef HAVE_PIXBUF
638 g_type_init (); 638 g_type_init ();
639 gdk_pixbuf_xlib_init (dpy, display->screen);
640#endif 639#endif
641 640
642#if ENABLE_PERL 641#if ENABLE_PERL
643 if (!rs[Rs_perl_ext_1]) 642 if (!rs[Rs_perl_ext_1])
644 rs[Rs_perl_ext_1] = "default"; 643 rs[Rs_perl_ext_1] = "default";
812 811
813 if (option (Opt_scrollBar)) 812 if (option (Opt_scrollBar))
814 scrollBar.resize (); /* create and map scrollbar */ 813 scrollBar.resize (); /* create and map scrollbar */
815#ifdef HAVE_BG_PIXMAP 814#ifdef HAVE_BG_PIXMAP
816 { 815 {
817 bgPixmap.set_target (this); 816 bg_init ();
818 bgPixmap.invalidate ();
819 817
820#ifdef ENABLE_TRANSPARENCY 818#ifdef ENABLE_TRANSPARENCY
821 if (option (Opt_transparent)) 819 if (option (Opt_transparent))
822 { 820 {
823 bgPixmap.set_transparent (); 821 bg_set_transparent ();
824 822
825 if (rs [Rs_blurradius]) 823 if (rs [Rs_blurradius])
826 bgPixmap.set_blur_radius (rs [Rs_blurradius]); 824 bg_set_blur (rs [Rs_blurradius]);
827 825
828 if (ISSET_PIXCOLOR (Color_tint)) 826 if (ISSET_PIXCOLOR (Color_tint))
829 bgPixmap.set_tint (pix_colors_focused [Color_tint]); 827 bg_set_tint (pix_colors_focused [Color_tint]);
830 828
831 if (rs [Rs_shade]) 829 if (rs [Rs_shade])
832 bgPixmap.set_shade (rs [Rs_shade]); 830 bg_set_shade (rs [Rs_shade]);
833 831
834 bgPixmap.set_root_pixmap (); 832 bg_set_root_pixmap ();
835 XSelectInput (dpy, display->root, PropertyChangeMask); 833 XSelectInput (dpy, display->root, PropertyChangeMask);
836 rootwin_ev.start (display, display->root); 834 rootwin_ev.start (display, display->root);
837 } 835 }
838#endif 836#endif
839 837
843 const char *p = rs[Rs_backgroundPixmap]; 841 const char *p = rs[Rs_backgroundPixmap];
844 842
845 if ((p = strchr (p, ';')) != 0) 843 if ((p = strchr (p, ';')) != 0)
846 { 844 {
847 p++; 845 p++;
848 bgPixmap.set_geometry (p); 846 bg_set_geometry (p);
849 } 847 }
850 else 848 else
851 bgPixmap.set_defaultGeometry (); 849 bg_set_default_geometry ();
852 850
853 if (bgPixmap.set_file (rs[Rs_backgroundPixmap])) 851 if (bg_set_file (rs[Rs_backgroundPixmap]))
854 if (!bgPixmap.window_position_sensitive ()) 852 if (!bg_window_position_sensitive ())
855 update_background (); 853 update_background ();
856 } 854 }
857#endif 855#endif
858 } 856 }
859#endif 857#endif
891 889
892/*----------------------------------------------------------------------*/ 890/*----------------------------------------------------------------------*/
893void 891void
894rxvt_term::init_env () 892rxvt_term::init_env ()
895{ 893{
896 int i;
897 char *val; 894 char *val;
898 895
899#ifdef DISPLAY_IS_IP 896#ifdef DISPLAY_IS_IP
900 /* Fixup display_name for export over pty to any interested terminal 897 /* Fixup display_name for export over pty to any interested terminal
901 * clients via "ESC[7n" (e.g. shells). Note we use the pure IP number 898 * clients via "ESC[7n" (e.g. shells). Note we use the pure IP number
915 val = XDisplayString (dpy); 912 val = XDisplayString (dpy);
916 913
917 if (rs[Rs_display_name] == NULL) 914 if (rs[Rs_display_name] == NULL)
918 rs[Rs_display_name] = val; /* use broken `:0' value */ 915 rs[Rs_display_name] = val; /* use broken `:0' value */
919 916
920 i = strlen (val);
921 env_display = (char *)rxvt_malloc (i + 9); 917 env_display = (char *)rxvt_malloc (strlen (val) + 9);
922 918
923 sprintf (env_display, "DISPLAY=%s", val); 919 sprintf (env_display, "DISPLAY=%s", val);
924 920
925 sprintf (env_windowid, "WINDOWID=%lu", (unsigned long)parent[0]); 921 sprintf (env_windowid, "WINDOWID=%lu", (unsigned long)parent[0]);
926 922
1508#if ENABLE_EWMH 1504#if ENABLE_EWMH
1509 xa[XA_NET_WM_PING], 1505 xa[XA_NET_WM_PING],
1510#endif 1506#endif
1511 }; 1507 };
1512 1508
1513 XSetWMProtocols (dpy, top, protocols, sizeof (protocols) / sizeof (protocols[0])); 1509 XSetWMProtocols (dpy, top, protocols, ARRAY_LENGTH(protocols));
1514 1510
1515#if ENABLE_FRILLS 1511#if ENABLE_FRILLS
1516 if (rs[Rs_transient_for]) 1512 if (rs[Rs_transient_for])
1517 XSetTransientForHint (dpy, top, (Window)strtol (rs[Rs_transient_for], 0, 0)); 1513 XSetTransientForHint (dpy, top, (Window)strtol (rs[Rs_transient_for], 0, 0));
1518#endif 1514#endif

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines