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.97 by root, Sat Feb 4 16:12:48 2006 UTC vs.
Revision 1.100 by root, Mon Feb 20 20:44:22 2006 UTC

923 RETVAL 923 RETVAL
924 924
925int 925int
926SET_FGCOLOR (int rend, int new_color) 926SET_FGCOLOR (int rend, int new_color)
927 CODE: 927 CODE:
928 RETVAL = SET_FGCOLOR (rend, new_color); 928 RETVAL = SET_FGCOLOR (rend, clamp (new_color, 0, TOTAL_COLORS - 1));
929 OUTPUT: 929 OUTPUT:
930 RETVAL 930 RETVAL
931 931
932int 932int
933SET_BGCOLOR (int rend, int new_color) 933SET_BGCOLOR (int rend, int new_color)
934 CODE: 934 CODE:
935 RETVAL = SET_BGCOLOR (rend, new_color); 935 RETVAL = SET_BGCOLOR (rend, clamp (new_color, 0, TOTAL_COLORS - 1));
936 OUTPUT: 936 OUTPUT:
937 RETVAL 937 RETVAL
938 938
939int 939int
940GET_CUSTOM (int rend) 940GET_CUSTOM (int rend)
1209 } 1209 }
1210 OUTPUT: 1210 OUTPUT:
1211 RETVAL 1211 RETVAL
1212 1212
1213SV * 1213SV *
1214rxvt_term::_env () 1214rxvt_term::envv ()
1215 ALIAS:
1216 argv = 1
1215 CODE: 1217 PPCODE:
1216{ 1218{
1217 if (THIS->envv) 1219 stringvec *vec = ix ? THIS->argv : THIS->envv;
1218 {
1219 AV *av = newAV ();
1220 1220
1221 EXTEND (SP, vec->size ());
1222
1221 for (char **i = THIS->envv->begin (); i != THIS->envv->end (); ++i) 1223 for (char **i = vec->begin (); i != vec->end (); ++i)
1222 if (*i) 1224 if (*i)
1223 av_push (av, newSVpv (*i, 0)); 1225 PUSHs (sv_2mortal (newSVpv (*i, 0)));
1224
1225 RETVAL = newRV_noinc ((SV *)av);
1226 }
1227 else
1228 RETVAL = &PL_sv_undef;
1229} 1226}
1230 OUTPUT:
1231 RETVAL
1232 1227
1233int 1228int
1234rxvt_term::pty_ev_events (int events = EVENT_UNDEF) 1229rxvt_term::pty_ev_events (int events = EVENT_UNDEF)
1235 CODE: 1230 CODE:
1236 RETVAL = THIS->pty_ev.events; 1231 RETVAL = THIS->pty_ev.events;
1290void 1285void
1291rxvt_term::focus_in () 1286rxvt_term::focus_in ()
1292 1287
1293void 1288void
1294rxvt_term::focus_out () 1289rxvt_term::focus_out ()
1290
1291void
1292rxvt_term::key_press (unsigned int state, unsigned int keycode, Time time = CurrentTime)
1293 ALIAS:
1294 key_release = 1
1295 CODE:
1296{
1297 XKeyEvent xkey;
1298
1299 memset (&xkey, 0, sizeof (xkey));
1300
1301 xkey.time = time;
1302 xkey.state = state;
1303 xkey.keycode = keycode;
1304
1305 xkey.type = ix ? KeyRelease : KeyPress;
1306 xkey.display = THIS->dpy;
1307 xkey.window = THIS->vt;
1308 xkey.root = THIS->display->root;
1309 xkey.subwindow = THIS->vt;
1310
1311 if (ix)
1312 THIS->key_release (xkey);
1313 else
1314 THIS->key_press (xkey);
1315}
1295 1316
1296void 1317void
1297rxvt_term::want_refresh () 1318rxvt_term::want_refresh ()
1298 CODE: 1319 CODE:
1299 THIS->want_refresh = 1; 1320 THIS->want_refresh = 1;
1786 : 1; 1807 : 1;
1787 1808
1788 XChangeProperty (THIS->dpy, window, property, 1809 XChangeProperty (THIS->dpy, window, property,
1789 type, format, PropModeReplace, 1810 type, format, PropModeReplace,
1790 (unsigned char *)data_, len / elemsize); 1811 (unsigned char *)data_, len / elemsize);
1791 XSync (THIS->dpy, 0);
1792} 1812}
1793 1813
1794Atom 1814Atom
1795XInternAtom (rxvt_term *term, char *atom_name, int only_if_exists = FALSE) 1815XInternAtom (rxvt_term *term, char *atom_name, int only_if_exists = FALSE)
1796 C_ARGS: term->dpy, atom_name, only_if_exists 1816 C_ARGS: term->dpy, atom_name, only_if_exists

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines