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

Comparing rxvt-unicode/src/command.C (file contents):
Revision 1.338 by ayin, Tue Jul 31 17:39:39 2007 UTC vs.
Revision 1.344 by root, Fri Aug 10 23:52:12 2007 UTC

1485 if (szHint.width != ev.xconfigure.width || szHint.height != ev.xconfigure.height) 1485 if (szHint.width != ev.xconfigure.width || szHint.height != ev.xconfigure.height)
1486 { 1486 {
1487 seen_resize = 1; 1487 seen_resize = 1;
1488 resize_all_windows (ev.xconfigure.width, ev.xconfigure.height, 1); 1488 resize_all_windows (ev.xconfigure.width, ev.xconfigure.height, 1);
1489#ifdef XPM_BACKGROUND 1489#ifdef XPM_BACKGROUND
1490 /* TODO: replace with update_pixmap() that should unify transparency and bg image handling ! */
1490 if (!option (Opt_transparent) && bgPixmap.auto_resize) 1491 if (!option (Opt_transparent) && bgPixmap.window_size_sensitive ())
1491 { 1492 {
1492 resize_pixmap (); 1493 bgPixmap.render_background ();
1493 scr_touch (true); 1494 scr_touch (true);
1494 } 1495 }
1495#endif 1496#endif
1496 } 1497 }
1497 1498
1498 HOOK_INVOKE ((this, HOOK_CONFIGURE_NOTIFY, DT_XEVENT, &ev, DT_END)); 1499 HOOK_INVOKE ((this, HOOK_CONFIGURE_NOTIFY, DT_XEVENT, &ev, DT_END));
1499 1500
1500#ifdef ENABLE_TRANSPARENCY 1501#ifdef ENABLE_TRANSPARENCY
1501 if (option (Opt_transparent)) 1502 if (option (Opt_transparent))
1502 check_our_parents (); 1503 bgPixmap.render_background ();
1503#endif 1504#endif
1504 } 1505 }
1505 break; 1506 break;
1506 1507
1507 case PropertyNotify: 1508 case PropertyNotify:
1834 case PropertyNotify: 1835 case PropertyNotify:
1835 /* 1836 /*
1836 * if user used some Esetroot compatible prog to set the root bg, 1837 * if user used some Esetroot compatible prog to set the root bg,
1837 * use the property to determine the pixmap. We use it later on. 1838 * use the property to determine the pixmap. We use it later on.
1838 */ 1839 */
1839 if (ev.xproperty.atom != xa[XA_XROOTPMAP_ID] 1840 if (ev.xproperty.atom == xa[XA_XROOTPMAP_ID]
1840 && ev.xproperty.atom != xa[XA_ESETROOT_PMAP_ID]) 1841 || ev.xproperty.atom == xa[XA_ESETROOT_PMAP_ID])
1841 return; 1842 {
1842 1843 bgPixmap.set_root_pixmap ();
1843 /* FALLTHROUGH */ 1844 bgPixmap.render_background ();
1844 case ReparentNotify: 1845 }
1845 if (option (Opt_transparent))
1846 check_our_parents ();
1847 break; 1846 break;
1848 } 1847 }
1849# endif 1848# endif
1850} 1849}
1851#endif 1850#endif
3431 break; 3430 break;
3432 case URxvt_Color_IT: 3431 case URxvt_Color_IT:
3433 process_color_seq (op, Color_IT, str, resp); 3432 process_color_seq (op, Color_IT, str, resp);
3434 break; 3433 break;
3435#endif 3434#endif
3436#if ENABLE_TRANSPARENCY && TINTING 3435#if ENABLE_TRANSPARENCY
3437 case URxvt_Color_tint: 3436 case URxvt_Color_tint:
3438 process_color_seq (op, Color_tint, str, resp); 3437 process_color_seq (op, Color_tint, str, resp);
3439
3440 check_our_parents ();
3441
3442 if (am_transparent)
3443 want_full_refresh = want_refresh = 1;
3444
3445 break;
3446#endif
3447
3448 case Rxvt_Pixmap:
3449 {
3450 if (*str != ';')
3451 { 3438 {
3452#if XPM_BACKGROUND
3453 scale_pixmap (""); /* reset to default scaling */
3454 set_bgPixmap (str); /* change pixmap */
3455 scr_touch (true);
3456#endif
3457 }
3458
3459 int changed = 0; 3439 bool changed = false;
3460 3440 if (ISSET_PIXCOLOR (Color_tint))
3461 while ((str = strchr (str, ';')) != NULL) 3441 changed = bgPixmap.set_tint (pix_colors_focused [Color_tint]);
3462 { 3442 else
3463 str++; 3443 changed = bgPixmap.unset_tint ();
3464#if XPM_BACKGROUND
3465 changed += scale_pixmap (str);
3466#endif
3467 }
3468
3469 if (changed) 3444 if (changed)
3470 { 3445 {
3471#ifdef XPM_BACKGROUND 3446 bgPixmap.render_background ();
3472 resize_pixmap (); 3447 if (am_transparent)
3473 scr_touch (true); 3448 want_full_refresh = want_refresh = 1;
3474#endif
3475 } 3449 }
3476#if ENABLE_TRANSPARENCY && defined(HAVE_AFTERIMAGE) 3450 }
3477 if (option (Opt_transparent)) 3451
3478 check_our_parents (); 3452 break;
3479#endif 3453#endif
3454
3455#if XPM_BACKGROUND
3456 case Rxvt_Pixmap:
3457 if (!strcmp (str, "?"))
3458 {
3459 char str[256];
3460
3461 sprintf (str, "[%dx%d+%d+%d]", /* can't presume snprintf () ! */
3462 min (bgPixmap.h_scale, 32767), min (bgPixmap.v_scale, 32767),
3463 min (bgPixmap.h_align, 32767), min (bgPixmap.v_align, 32767));
3464 process_xterm_seq (XTerm_title, str, CHAR_ST);
3480 } 3465 }
3466 else
3467 {
3468 int changed = 0;
3469
3470 if (*str != ';')
3471 {
3472 /* reset to default scaling :*/
3473 bgPixmap.unset_geometry ();
3474 if (bgPixmap.set_file (str)) /* change pixmap */
3475 changed++;
3476 str = strchr (str, ';');
3477 if (str == NULL)
3478 bgPixmap.set_defaultGeometry ();
3479 }
3480 while (str)
3481 {
3482 str++;
3483 if (bgPixmap.set_geometry (str))
3484 changed++;
3485 str = strchr (str, ';');
3486 }
3487 if (changed)
3488 {
3489 bgPixmap.render_background ();
3490 scr_touch (true);
3491 }
3492 }
3481 break; 3493 break;
3494#endif
3482 3495
3483 case Rxvt_restoreFG: 3496 case Rxvt_restoreFG:
3484 set_window_color (Color_fg, str); 3497 set_window_color (Color_fg, str);
3485 break; 3498 break;
3486 case Rxvt_restoreBG: 3499 case Rxvt_restoreBG:
3608{ 3621{
3609 unsigned int i, j; 3622 unsigned int i, j;
3610 int state; 3623 int state;
3611 3624
3612 static const struct 3625 static const struct
3613 { 3626 {
3614 const int argval; 3627 const int argval;
3615 const unsigned long bit; 3628 const unsigned long bit;
3616 }
3617
3618 argtopriv[] = { 3629 } argtopriv[] = {
3619 { 1, PrivMode_aplCUR }, 3630 { 1, PrivMode_aplCUR },
3620 { 2, PrivMode_vt52 }, 3631 { 2, PrivMode_vt52 },
3621 { 3, PrivMode_132 }, 3632 { 3, PrivMode_132 },
3622 { 4, PrivMode_smoothScroll }, 3633 { 4, PrivMode_smoothScroll },
3623 { 5, PrivMode_rVideo }, 3634 { 5, PrivMode_rVideo },

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines