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.159 by root, Mon Jan 30 02:21:20 2006 UTC vs.
Revision 1.163 by root, Tue Jan 31 16:57:35 2006 UTC

299 if (!(display = displays.get (rs[Rs_display_name]))) 299 if (!(display = displays.get (rs[Rs_display_name])))
300 rxvt_fatal ("can't open display %s, aborting.\n", rs[Rs_display_name]); 300 rxvt_fatal ("can't open display %s, aborting.\n", rs[Rs_display_name]);
301 301
302 xa = display->xa; 302 xa = display->xa;
303 303
304#if ENABLE_FRILLS 304#if XFT
305 if (rs[Rs_depth]) 305 if (rs[Rs_depth])
306 set (display, strtol (rs[Rs_depth], 0, 0)); 306 set (display, strtol (rs[Rs_depth], 0, 0));
307 else 307 else
308#endif 308#endif
309 set (display); 309 set (display);
660 rxvt_color xcol; 660 rxvt_color xcol;
661 661
662 if (!rs[Rs_color + i]) 662 if (!rs[Rs_color + i])
663 continue; 663 continue;
664 664
665 if (!rXParseAllocColor (&xcol, rs[Rs_color + i])) 665 if (!set_color (xcol, rs[Rs_color + i]))
666 { 666 {
667#ifndef XTERM_REVERSE_VIDEO 667#ifndef XTERM_REVERSE_VIDEO
668 if (i < 2 && OPTION (Opt_reverseVideo)) 668 if (i < 2 && OPTION (Opt_reverseVideo))
669 rs[Rs_color + i] = def_colorName[!i]; 669 rs[Rs_color + i] = def_colorName[!i];
670 else 670 else
672 rs[Rs_color + i] = def_colorName[i]; 672 rs[Rs_color + i] = def_colorName[i];
673 673
674 if (!rs[Rs_color + i]) 674 if (!rs[Rs_color + i])
675 continue; 675 continue;
676 676
677 if (!rXParseAllocColor (&xcol, rs[Rs_color + i])) 677 if (!set_color (xcol, rs[Rs_color + i]))
678 { 678 {
679 switch (i) 679 switch (i)
680 { 680 {
681 case Color_fg: 681 case Color_fg:
682 case Color_bg: 682 case Color_bg:
683 /* fatal: need bg/fg color */ 683 /* fatal: need bg/fg color */
684 rxvt_fatal ("unable to get foreground/background colour, aborting.\n"); 684 rxvt_warn ("unable to get foreground/background colour, continuing.\n");
685 /* NOTREACHED */
686 break; 685 break;
687#ifndef NO_CURSORCOLOR 686#ifndef NO_CURSORCOLOR
688 case Color_cursor2: 687 case Color_cursor2:
689 xcol = pix_colors[Color_fg]; 688 xcol = pix_colors[Color_fg];
690 break; 689 break;
704 } 703 }
705 704
706#ifdef OFF_FOCUS_FADING 705#ifdef OFF_FOCUS_FADING
707 if (rs[Rs_fade]) 706 if (rs[Rs_fade])
708 for (i = 0; i < (depth <= 2 ? 2 : NRS_COLORS); i++) 707 for (i = 0; i < (depth <= 2 ? 2 : NRS_COLORS); i++)
708 {
709 rxvt_rgba c;
710 pix_colors[Color_fade].get (this, c);
709 pix_colors_unfocused[i] = pix_colors_focused[i].fade (this, atoi (rs[Rs_fade]), pix_colors[Color_fade]); 711 pix_colors_focused[i].fade (this, atoi (rs[Rs_fade]), pix_colors_unfocused[i],c);
712 }
710#endif 713#endif
711 714
712 if (depth <= 2) 715 if (depth <= 2)
713 { 716 {
714 if (!rs[Rs_color + Color_pointer_fg]) pix_colors[Color_pointer_fg] = pix_colors[Color_fg]; 717 if (!rs[Rs_color + Color_pointer_fg]) pix_colors[Color_pointer_fg] = pix_colors[Color_fg];
744 rxvt_rgba c0, c1; 747 rxvt_rgba c0, c1;
745 748
746 xcol[0].get (this, c0); 749 xcol[0].get (this, c0);
747 xcol[1].get (this, c1); 750 xcol[1].get (this, c1);
748 751
749 pix_colors[Color_bottomShadow] = xcol[1].fade (this, 50); 752 xcol[1].fade (this, 50, pix_colors[Color_bottomShadow]);
750 753
751 /* topShadowColor */ 754 /* topShadowColor */
752 if (!xcol[1].set (this, 755 if (!xcol[1].set (this,
753 rxvt_rgba ( 756 rxvt_rgba (
754 min (c0.r, max (c1.r / 5, c1.r) * 7 / 5), 757 min (c0.r, max (c1.r / 5, c1.r) * 7 / 5),

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines