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.212 by sf-exg, Sat Jan 19 10:04:34 2013 UTC vs.
Revision 1.219 by sf-exg, Fri May 2 20:34:24 2014 UTC

793 static const struct { 793 static const struct {
794 const char *name; 794 const char *name;
795 IV iv; 795 IV iv;
796 } *civ, const_iv[] = { 796 } *civ, const_iv[] = {
797# define const_iv(name) { # name, (IV)name } 797# define const_iv(name) { # name, (IV)name }
798 const_iv (HOOK_INIT),
799 const_iv (HOOK_DESTROY),
800 const_iv (HOOK_KEYBOARD_DISPATCH),
801
798 const_iv (NUM_RESOURCES), 802 const_iv (NUM_RESOURCES),
799 const_iv (DEFAULT_RSTYLE), 803 const_iv (DEFAULT_RSTYLE),
800 const_iv (OVERLAY_RSTYLE), 804 const_iv (OVERLAY_RSTYLE),
801 const_iv (Color_Bits), 805 const_iv (Color_Bits),
802 const_iv (RS_bgShift), const_iv (RS_bgMask), 806 const_iv (RS_bgShift), const_iv (RS_bgMask),
812 const_iv (RS_Bold), 816 const_iv (RS_Bold),
813 const_iv (RS_Italic), 817 const_iv (RS_Italic),
814 const_iv (RS_Blink), 818 const_iv (RS_Blink),
815 const_iv (RS_RVid), 819 const_iv (RS_RVid),
816 const_iv (RS_Uline), 820 const_iv (RS_Uline),
821
822 // TODO: should support all colour constants, create colorinc.h &c
823 const_iv (Color_fg),
824 const_iv (Color_bg),
825#if OFF_FOCUS_FADING
826 const_iv (Color_fade),
827#endif
828 const_iv (Color_pointer_fg),
829 const_iv (Color_pointer_bg),
830 const_iv (Color_border),
831 const_iv (NRS_COLORS),
832 const_iv (TOTAL_COLORS),
817 833
818 const_iv (CurrentTime), 834 const_iv (CurrentTime),
819 const_iv (ShiftMask), 835 const_iv (ShiftMask),
820 const_iv (LockMask), 836 const_iv (LockMask),
821 const_iv (ControlMask), 837 const_iv (ControlMask),
1815} 1831}
1816 OUTPUT: 1832 OUTPUT:
1817 RETVAL 1833 RETVAL
1818 1834
1819bool 1835bool
1820rxvt_term::parse_keysym (char *keysym, char *str) 1836rxvt_term::bind_action (char *keysym, char *str)
1837 ALIAS:
1838 parse_keysym = 1
1821 CODE: 1839 CODE:
1822 RETVAL = 0 < THIS->parse_keysym (keysym, str); 1840 RETVAL = 0 < THIS->bind_action (keysym, str);
1823 THIS->keyboard->register_done (); 1841 THIS->keyboard->register_done ();
1824 OUTPUT: 1842 OUTPUT:
1825 RETVAL 1843 RETVAL
1826 1844
1827void 1845void
1879 1897
1880 if (ix) 1898 if (ix)
1881 { 1899 {
1882 THIS->selection.screen = THIS->current_screen; 1900 THIS->selection.screen = THIS->current_screen;
1883 1901
1884 THIS->want_refresh = 1; 1902 THIS->selection_changed ();
1885 THIS->refresh_check (); 1903 THIS->refresh_check ();
1886 } 1904 }
1887 } 1905 }
1888} 1906}
1889 1907
1893 RETVAL = THIS->selection.screen; 1911 RETVAL = THIS->selection.screen;
1894 if (screen >= 0) 1912 if (screen >= 0)
1895 THIS->selection.screen = screen; 1913 THIS->selection.screen = screen;
1896 OUTPUT: 1914 OUTPUT:
1897 RETVAL 1915 RETVAL
1916
1917void
1918rxvt_term::selection_request (Time tm, int selnum)
1898 1919
1899void 1920void
1900rxvt_term::selection_clear (bool clipboard = false) 1921rxvt_term::selection_clear (bool clipboard = false)
1901 1922
1902void 1923void
2397 rxvt_img::nv *vparams = 0; 2418 rxvt_img::nv *vparams = 0;
2398 int nparams = 0; 2419 int nparams = 0;
2399 2420
2400 if (SvOK (params)) 2421 if (SvOK (params))
2401 { 2422 {
2402 // we overlay rxvt_temp_buf, what a hack
2403 assert (sizeof (rxvt_img::nv) >= sizeof (int));
2404
2405 if (!SvROK (params) || SvTYPE (SvRV (params)) != SVt_PVAV) 2423 if (!SvROK (params) || SvTYPE (SvRV (params)) != SVt_PVAV)
2406 croak ("rxvt_img::filter: params must be an array reference with parameter values"); 2424 croak ("rxvt_img::filter: params must be an array reference with parameter values");
2407 2425
2408 nparams = av_len ((AV *)SvRV (params)) + 1; 2426 nparams = av_len ((AV *)SvRV (params)) + 1;
2409 vparams = rxvt_temp_buf<rxvt_img::nv> (nparams); 2427 vparams = (rxvt_img::nv *)malloc (nparams * sizeof (rxvt_img::nv));
2410 2428
2411 for (int i = 0; i < nparams; ++i) 2429 for (int i = 0; i < nparams; ++i)
2412 vparams [i] = SvNV (*av_fetch ((AV *)SvRV (params), i, 1)); 2430 vparams [i] = SvNV (*av_fetch ((AV *)SvRV (params), i, 1));
2413 } 2431 }
2414 2432
2415 RETVAL = THIS->filter (name, nparams, vparams); 2433 RETVAL = THIS->filter (name, nparams, vparams);
2434 free (vparams);
2416 OUTPUT: 2435 OUTPUT:
2417 RETVAL 2436 RETVAL
2418 2437
2419#endif 2438#endif
2420 2439

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines