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.128 by root, Sat Dec 26 09:42:16 2009 UTC vs.
Revision 1.131 by root, Sun May 23 00:08:53 2010 UTC

654 } *civ, const_iv[] = { 654 } *civ, const_iv[] = {
655# define const_iv(name) { # name, (IV)name } 655# define const_iv(name) { # name, (IV)name }
656 const_iv (NUM_RESOURCES), 656 const_iv (NUM_RESOURCES),
657 const_iv (DEFAULT_RSTYLE), 657 const_iv (DEFAULT_RSTYLE),
658 const_iv (OVERLAY_RSTYLE), 658 const_iv (OVERLAY_RSTYLE),
659 const_iv (Color_Bits),
660 const_iv (RS_bgShift), const_iv (RS_bgMask),
661 const_iv (RS_fgShift), const_iv (RS_fgMask),
662 const_iv (RS_Careful),
663 const_iv (RS_fontCount),
664 const_iv (RS_fontShift),
665 const_iv (RS_fontMask),
666 const_iv (RS_baseattrMask),
667 const_iv (RS_attrMask),
668 const_iv (RS_redraw),
669 const_iv (RS_Sel),
659 const_iv (RS_Bold), 670 const_iv (RS_Bold),
660 const_iv (RS_Italic), 671 const_iv (RS_Italic),
661 const_iv (RS_Blink), 672 const_iv (RS_Blink),
662 const_iv (RS_RVid), 673 const_iv (RS_RVid),
663 const_iv (RS_Uline), 674 const_iv (RS_Uline),
1594 THIS->selection.screen = screen; 1605 THIS->selection.screen = screen;
1595 OUTPUT: 1606 OUTPUT:
1596 RETVAL 1607 RETVAL
1597 1608
1598void 1609void
1599rxvt_term::selection_clear () 1610rxvt_term::selection_clear (bool clipboard = false)
1600 1611
1601void 1612void
1602rxvt_term::selection_make (Time eventtime, bool rect = false) 1613rxvt_term::selection_make (Time eventtime, bool rect = false)
1603 CODE: 1614 CODE:
1604 THIS->selection.op = SELECTION_CONT; 1615 THIS->selection.op = SELECTION_CONT;
1605 THIS->selection.rect = rect; 1616 THIS->selection.rect = rect;
1606 THIS->selection_make (eventtime); 1617 THIS->selection_make (eventtime);
1607 1618
1608int 1619int
1609rxvt_term::selection_grab (Time eventtime) 1620rxvt_term::selection_grab (Time eventtime, bool clipboard = false)
1610 1621
1611void 1622void
1612rxvt_term::selection (SV *newtext = 0) 1623rxvt_term::selection (SV *newtext = 0, bool clipboard = false)
1613 PPCODE: 1624 PPCODE:
1614{ 1625{
1626 wchar_t * &text = clipboard ? THIS->selection.clip_text : THIS->selection.text;
1627 unsigned int &len = clipboard ? THIS->selection.clip_len : THIS->selection.len;
1628
1615 if (GIMME_V != G_VOID) 1629 if (GIMME_V != G_VOID)
1616 XPUSHs (THIS->selection.text 1630 XPUSHs (text
1617 ? sv_2mortal (wcs2sv (THIS->selection.text, THIS->selection.len)) 1631 ? sv_2mortal (wcs2sv (text, len))
1618 : &PL_sv_undef); 1632 : &PL_sv_undef);
1619 1633
1620 if (newtext) 1634 if (newtext)
1621 { 1635 {
1622 free (THIS->selection.text); 1636 free (text);
1623 1637
1624 THIS->selection.text = sv2wcs (newtext); 1638 text = sv2wcs (newtext);
1625 THIS->selection.len = wcslen (THIS->selection.text); 1639 len = wcslen (text);
1626 } 1640 }
1627} 1641}
1628 1642
1629char 1643char
1630rxvt_term::cur_charset () 1644rxvt_term::cur_charset ()

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines