--- rxvt-unicode/src/rxvtperl.xs 2019/09/17 20:38:14 1.245 +++ rxvt-unicode/src/rxvtperl.xs 2021/07/24 11:58:27 1.253 @@ -84,15 +84,15 @@ c.a = rgba::MAX_CC; - c.r = c.g = c.b = float_to_component (SvIV (*av_fetch (av, 0, 0))); + c.r = c.g = c.b = float_to_component (SvNV (*av_fetch (av, 0, 0))); if (len >= 3) { - c.g = float_to_component (SvIV (*av_fetch (av, 1, 0))); - c.b = float_to_component (SvIV (*av_fetch (av, 2, 0))); + c.g = float_to_component (SvNV (*av_fetch (av, 1, 0))); + c.b = float_to_component (SvNV (*av_fetch (av, 2, 0))); if (len >= 4) - c.a = float_to_component (SvIV (*av_fetch (av, 3, 0))); + c.a = float_to_component (SvNV (*av_fetch (av, 3, 0))); } } else if (s) @@ -372,15 +372,20 @@ static PerlInterpreter *perl; +#if 0 /* we are not a library anymore, so doing this is just not worth it */ +/*THINK/TODO: this has the side effect of, of course, not calling destructors. */ +/* but therse are not guaranteed anyway... */ rxvt_perl_interp::~rxvt_perl_interp () { if (perl) { + localise_env set_environ (perl_environ); perl_destruct (perl); perl_free (perl); PERL_SYS_TERM (); } } +#endif void rxvt_perl_interp::init () @@ -818,6 +823,8 @@ const_iv (HOOK_INIT), const_iv (HOOK_DESTROY), const_iv (HOOK_ACTION), + const_iv (HOOK_OSC_SEQ), + const_iv (HOOK_OSC_SEQ_PERL), const_iv (NUM_RESOURCES), const_iv (DEFAULT_RSTYLE), @@ -1048,8 +1055,8 @@ const_iv (PrivMode_MouseBtnEvent), const_iv (PrivMode_MouseAnyEvent), const_iv (PrivMode_BracketPaste), - const_iv (PrivMode_ExtModeMouse), - const_iv (PrivMode_ExtMouseRight), + const_iv (PrivMode_ExtMouseUTF8), + const_iv (PrivMode_ExtMouseUrxvt), const_iv (PrivMode_BlinkingCursor), const_iv (PrivMode_mouse_report), const_iv (PrivMode_Default), @@ -1559,14 +1566,13 @@ RETVAL int -rxvt_term::view_start (int newval = 1) +rxvt_term::view_start (int newval = 0) PROTOTYPE: $;$ CODE: { RETVAL = THIS->view_start; - - if (newval <= 0) - THIS->scr_changeview (max (newval, THIS->top_row)); + if (items > 1) + THIS->scr_changeview (newval); } OUTPUT: RETVAL @@ -1786,7 +1792,7 @@ if (*s == NOCHAR) ; else if (IS_COMPOSE (*s)) - dlen += rxvt_composite.expand (*s, 0); + dlen += rxvt_composite.expand (*s); else dlen++;