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.103 by root, Mon Aug 7 21:38:24 2006 UTC vs.
Revision 1.108 by root, Sun Dec 10 15:14:05 2006 UTC

941 RETVAL 941 RETVAL
942 942
943int 943int
944GET_CUSTOM (int rend) 944GET_CUSTOM (int rend)
945 CODE: 945 CODE:
946 RETVAL = (rend && RS_customMask) >> RS_customShift; 946 RETVAL = (rend & RS_customMask) >> RS_customShift;
947 OUTPUT: 947 OUTPUT:
948 RETVAL 948 RETVAL
949 949
950int 950int
951SET_CUSTOM (int rend, int new_value) 951SET_CUSTOM (int rend, int new_value)
1122 CODE: 1122 CODE:
1123{ 1123{
1124 wchar_t *wstr = sv2wcs (str); 1124 wchar_t *wstr = sv2wcs (str);
1125 1125
1126 rxvt_push_locale (THIS->locale); 1126 rxvt_push_locale (THIS->locale);
1127 RETVAL = wcswidth (wstr, wcslen (wstr)); 1127 RETVAL = 0;
1128 for (wchar_t *wc = wstr; *wc; wc++)
1129 {
1130 int w = WCWIDTH (*wc);
1131
1132 if (w)
1133 RETVAL += max (w, 1);
1134 }
1128 rxvt_pop_locale (); 1135 rxvt_pop_locale ();
1129 1136
1130 free (wstr); 1137 free (wstr);
1131} 1138}
1132 OUTPUT: 1139 OUTPUT:
1162 rxvt_pop_locale (); 1169 rxvt_pop_locale ();
1163 1170
1164 RETVAL = wcs2sv (wstr); 1171 RETVAL = wcs2sv (wstr);
1165 free (wstr); 1172 free (wstr);
1166} 1173}
1174 OUTPUT:
1175 RETVAL
1176
1177char *
1178rxvt_term::locale ()
1179 CODE:
1180 RETVAL = THIS->locale;
1167 OUTPUT: 1181 OUTPUT:
1168 RETVAL 1182 RETVAL
1169 1183
1170#define TERM_OFFSET(sym) offsetof (TermWin_t, sym) 1184#define TERM_OFFSET(sym) offsetof (TermWin_t, sym)
1171 1185

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines