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

Comparing rxvt-unicode/src/rxvtperl.xs (file contents):
Revision 1.171 by root, Tue Jun 5 22:23:07 2012 UTC vs.
Revision 1.175 by root, Wed Jun 6 20:55:37 2012 UTC

400 400
401 ENTER; 401 ENTER;
402 SAVETMPS; 402 SAVETMPS;
403 403
404 dSP; 404 dSP;
405 PUSHMARK (SP);
405 EXTEND (SP, 2); 406 EXTEND (SP, 2);
406 PUSHs (sv_2mortal (newSVterm (term))); 407 PUSHs (sv_2mortal (newSVterm (term)));
407 PUSHs (sv_2mortal (newSViv (type))); 408 PUSHs (sv_2mortal (newSViv (type)));
408 PUTBACK; 409 PUTBACK;
409 call_pv ("urxvt::usage", G_VOID | G_DISCARD | G_EVAL); 410 call_pv ("urxvt::usage", G_VOID | G_DISCARD);
410 411
411 FREETMPS; 412 FREETMPS;
412 LEAVE; 413 LEAVE;
413} 414}
414 415
415uint8_t 416uint8_t
416rxvt_perl_interp::resource (rxvt_term *term, const char *name, bool arg, bool longopt, bool flag, const char *value) 417rxvt_perl_interp::parse_resource (rxvt_term *term, const char *name, bool arg, bool longopt, bool flag, const char *value)
417{ 418{
418 localise_env set_environ (perl_environ); 419 localise_env set_environ (perl_environ);
419 420
420 ENTER; 421 ENTER;
421 SAVETMPS; 422 SAVETMPS;
422 423
423 dSP; 424 dSP;
425 PUSHMARK (SP);
424 EXTEND (SP, 6); 426 EXTEND (SP, 6);
425 PUSHs (sv_2mortal (newSVterm (term))); 427 PUSHs (sv_2mortal (newSVterm (term)));
426 PUSHs (sv_2mortal (newSVpv (name, 0))); 428 PUSHs (sv_2mortal (newSVpv (name, 0)));
427 PUSHs (arg ? &PL_sv_yes : &PL_sv_no); 429 PUSHs (arg ? &PL_sv_yes : &PL_sv_no);
428 PUSHs (longopt ? &PL_sv_yes : &PL_sv_no); 430 PUSHs (longopt ? &PL_sv_yes : &PL_sv_no);
429 PUSHs (flag ? &PL_sv_yes : &PL_sv_no); 431 PUSHs (flag ? &PL_sv_yes : &PL_sv_no);
430 PUSHs (value ? sv_2mortal (newSVpv (value, 0)) : &PL_sv_undef); 432 PUSHs (value ? sv_2mortal (newSVpv (value, 0)) : &PL_sv_undef);
431 PUTBACK; 433 PUTBACK;
432 call_pv ("urxvt::resource", G_SCALAR | G_EVAL); 434 call_pv ("urxvt::parse_resource", G_SCALAR);
435 SPAGAIN;
433 436
434 uint8_t ret = POPi; 437 uint8_t ret = POPi;
435 438
436 FREETMPS; 439 FREETMPS;
437 LEAVE; 440 LEAVE;
1061 if (count) 1064 if (count)
1062 THIS->get_window_origin (THIS->parent_x, THIS->parent_y); 1065 THIS->get_window_origin (THIS->parent_x, THIS->parent_y);
1063 } 1066 }
1064 } 1067 }
1065 1068
1069void
1070rxvt_term::put_option_db (octet_string specifier, octet_string value)
1071 CODE:
1072 XrmPutStringResource (&THIS->option_db, specifier, value);
1073
1066int 1074int
1067rxvt_term::grab_button (int button, U32 modifiers, Window window = THIS->vt) 1075rxvt_term::grab_button (int button, U32 modifiers, Window window = THIS->vt)
1068 CODE: 1076 CODE:
1069 RETVAL = XGrabButton (THIS->dpy, button, modifiers, window, 1, 1077 RETVAL = XGrabButton (THIS->dpy, button, modifiers, window, 1,
1070 ButtonPressMask | ButtonReleaseMask | EnterWindowMask | LeaveWindowMask | PointerMotionMask, 1078 ButtonPressMask | ButtonReleaseMask | EnterWindowMask | LeaveWindowMask | PointerMotionMask,
2046 OUTPUT: 2054 OUTPUT:
2047 RETVAL 2055 RETVAL
2048 2056
2049#if ENABLE_TRANSPARENCY 2057#if ENABLE_TRANSPARENCY
2050 2058
2051#if 0
2052
2053rxvt_img * 2059rxvt_img *
2054rxvt_term::new_img_from_root () 2060rxvt_term::new_img_from_root ()
2055 CODE: 2061 CODE:
2056 RETVAL = rxvt_img::new_from_root (THIS); 2062 RETVAL = rxvt_img::new_from_root (THIS);
2057 OUTPUT: 2063 OUTPUT:
2058 RETVAL 2064 RETVAL
2059
2060#endif
2061 2065
2062#endif 2066#endif
2063 2067
2064#if HAVE_PIXBUF 2068#if HAVE_PIXBUF
2065 2069
2088 THIS->bg_pixmap = None; 2092 THIS->bg_pixmap = None;
2089 THIS->bg_flags &= ~rxvt_term::BG_NEEDS_REFRESH; 2093 THIS->bg_flags &= ~rxvt_term::BG_NEEDS_REFRESH;
2090 2094
2091 if (img) // TODO: cannot be false 2095 if (img) // TODO: cannot be false
2092 { 2096 {
2097 XRenderPictFormat *f = XRenderFindVisualFormat (THIS->dpy, THIS->visual);
2098 rxvt_img *img2 = 0;
2099
2100 if (f != img->format)
2101 img = img2 = img->convert_to (f, THIS->pix_colors [Color_bg]);
2102
2093 img->unshare (); 2103 img->unshare ();
2094 THIS->bg_pixmap = img->steal (); 2104 THIS->bg_pixmap = img->steal ();
2095 THIS->bg_flags |= rxvt_term::BG_NEEDS_REFRESH; 2105 THIS->bg_flags |= rxvt_term::BG_NEEDS_REFRESH;
2096 THIS->bg_valid_since = ev::now (); // TODO: extra bloat 2106 THIS->bg_valid_since = ev::now (); // TODO: extra bloat
2107
2108 delete img2;
2097 } 2109 }
2098 2110
2099#endif 2111#endif
2100 2112
2101#endif 2113#endif

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines