… | |
… | |
821 | } *civ, const_iv[] = { |
821 | } *civ, const_iv[] = { |
822 | # define const_iv(name) { # name, (IV)name } |
822 | # define const_iv(name) { # name, (IV)name } |
823 | const_iv (HOOK_INIT), |
823 | const_iv (HOOK_INIT), |
824 | const_iv (HOOK_DESTROY), |
824 | const_iv (HOOK_DESTROY), |
825 | const_iv (HOOK_ACTION), |
825 | const_iv (HOOK_ACTION), |
|
|
826 | const_iv (HOOK_OSC_SEQ), |
|
|
827 | const_iv (HOOK_OSC_SEQ_PERL), |
826 | |
828 | |
827 | const_iv (NUM_RESOURCES), |
829 | const_iv (NUM_RESOURCES), |
828 | const_iv (DEFAULT_RSTYLE), |
830 | const_iv (DEFAULT_RSTYLE), |
829 | const_iv (OVERLAY_RSTYLE), |
831 | const_iv (OVERLAY_RSTYLE), |
830 | const_iv (Color_Bits), |
832 | const_iv (Color_Bits), |
… | |
… | |
1372 | |
1374 | |
1373 | SV * |
1375 | SV * |
1374 | rxvt_term::locale_encode (SV *str) |
1376 | rxvt_term::locale_encode (SV *str) |
1375 | CODE: |
1377 | CODE: |
1376 | { |
1378 | { |
|
|
1379 | if (!SvOK (str)) |
|
|
1380 | XSRETURN_UNDEF; |
|
|
1381 | |
1377 | wchar_t *wstr = sv2wcs (str); |
1382 | wchar_t *wstr = sv2wcs (str); |
1378 | |
1383 | |
1379 | rxvt_push_locale (THIS->locale); |
1384 | rxvt_push_locale (THIS->locale); |
1380 | char *mbstr = rxvt_wcstombs (wstr); |
1385 | char *mbstr = rxvt_wcstombs (wstr); |
1381 | rxvt_pop_locale (); |
1386 | rxvt_pop_locale (); |
… | |
… | |
1390 | |
1395 | |
1391 | SV * |
1396 | SV * |
1392 | rxvt_term::locale_decode (SV *octets) |
1397 | rxvt_term::locale_decode (SV *octets) |
1393 | CODE: |
1398 | CODE: |
1394 | { |
1399 | { |
|
|
1400 | if (!SvOK (octets)) |
|
|
1401 | XSRETURN_UNDEF; |
|
|
1402 | |
1395 | STRLEN len; |
1403 | STRLEN len; |
1396 | char *data = SvPVbyte (octets, len); |
1404 | char *data = SvPVbyte (octets, len); |
1397 | |
1405 | |
1398 | rxvt_push_locale (THIS->locale); |
1406 | rxvt_push_locale (THIS->locale); |
1399 | wchar_t *wstr = rxvt_mbstowcs (data, len); |
1407 | wchar_t *wstr = rxvt_mbstowcs (data, len); |
… | |
… | |
1562 | THIS->rstyle = new_rstyle; |
1570 | THIS->rstyle = new_rstyle; |
1563 | OUTPUT: |
1571 | OUTPUT: |
1564 | RETVAL |
1572 | RETVAL |
1565 | |
1573 | |
1566 | int |
1574 | int |
1567 | rxvt_term::view_start (int newval = 1) |
1575 | rxvt_term::view_start (int newval = 0) |
1568 | PROTOTYPE: $;$ |
1576 | PROTOTYPE: $;$ |
1569 | CODE: |
1577 | CODE: |
1570 | { |
1578 | { |
1571 | RETVAL = THIS->view_start; |
1579 | RETVAL = THIS->view_start; |
1572 | if (items > 1) |
1580 | if (items > 1) |