repo: rxvt-unicode-sixel action: commit revision: path_from: revision_from: e71107cfde261907c441f6594fda2b21d5eff589: path_to: revision_to:
commit e71107cfde261907c441f6594fda2b21d5eff589 Author: Marc LehmannDate: Wed Jan 18 10:31:37 2006 +0000 *** empty log message *** diff --git a/src/command.C b/src/command.C
--- a/src/command.C
+++ b/src/command.C
@@ -1504,6 +1504,8 @@ rxvt_term::x_cb (XEvent &ev)
resize_all_windows (ev.xconfigure.width, ev.xconfigure.height, 1);
}
+ HOOK_INVOKE ((this, HOOK_CONFIGURE_NOTIFY, DT_XEVENT, &ev, DT_END));
+
#ifdef TRANSPARENT /* XXX: maybe not needed - leave in for now */
if (OPTION (Opt_transparent))
check_our_parents ();
diff --git a/src/hookinc.h b/src/hookinc.h
--- a/src/hookinc.h +++ b/src/hookinc.h @@ -34,4 +34,5 @@ def (MOTION_NOTIFY) def (MAP_NOTIFY) def (UNMAP_NOTIFY) + def (CONFIGURE_NOTIFY) def (CUSTOM_REND) // hovering over custom rendition, generate enter/leave maybe? diff --git a/src/perl/selection-pastebin b/src/perl/selection-pastebin
--- a/src/perl/selection-pastebin
+++ b/src/perl/selection-pastebin
@@ -16,7 +16,8 @@ sub upload_paste {
my $msg = "uploaded $filename";
- if (open my $o, ">" . $tmpfile) {
+ if (open my $o, ">$tmpfile") {
+ chmod 0644, $tmpfile;
print $o $txt;
close $o;
} else {
diff --git a/src/rxvtperl.xs b/src/rxvtperl.xs
--- a/src/rxvtperl.xs
+++ b/src/rxvtperl.xs
@@ -537,6 +537,7 @@ rxvt_perl_interp::invoke (rxvt_term *term, hook_type htype, ...)
# define set(name, sv) hv_store (hv, # name, sizeof (# name) - 1, sv, 0)
# define setiv(name, val) hv_store (hv, # name, sizeof (# name) - 1, newSViv (val), 0)
+# define setuv(name, val) hv_store (hv, # name, sizeof (# name) - 1, newSVuv (val), 0)
# undef set
setiv (type, xe->type);
@@ -550,31 +551,54 @@ rxvt_perl_interp::invoke (rxvt_term *term, hook_type htype, ...)
case ButtonPress:
case ButtonRelease:
case MotionNotify:
- setiv (time, xe->xmotion.time);
- setiv (x, xe->xmotion.x);
- setiv (y, xe->xmotion.y);
- setiv (row, xe->xmotion.y / term->fheight);
- setiv (col, xe->xmotion.x / term->fwidth);
- setiv (x_root, xe->xmotion.x_root);
- setiv (y_root, xe->xmotion.y_root);
- setiv (state, xe->xmotion.state);
- break;
- }
+ setuv (window, xe->xmotion.window);
+ setuv (root, xe->xmotion.root);
+ setuv (subwindow, xe->xmotion.subwindow);
+ setuv (time, xe->xmotion.time);
+ setiv (x, xe->xmotion.x);
+ setiv (y, xe->xmotion.y);
+ setiv (row, xe->xmotion.y / term->fheight);
+ setiv (col, xe->xmotion.x / term->fwidth);
+ setiv (x_root, xe->xmotion.x_root);
+ setiv (y_root, xe->xmotion.y_root);
+ setuv (state, xe->xmotion.state);
+
+ switch (xe->type)
+ {
+ case KeyPress:
+ case KeyRelease:
+ setuv (keycode, xe->xkey.keycode);
+ break;
+
+ case ButtonPress:
+ case ButtonRelease:
+ setuv (button, xe->xbutton.button);
+ break;
+
+ case MotionNotify:
+ setiv (is_hint, xe->xmotion.is_hint);
+ break;
+ }
- switch (xe->type)
- {
- case KeyPress:
- case KeyRelease:
- setiv (keycode, xe->xkey.keycode);
break;
- case ButtonPress:
- case ButtonRelease:
- setiv (button, xe->xbutton.button);
- break;
+ case MapNotify:
+ case UnmapNotify:
+ case ConfigureNotify:
+ setuv (event, xe->xconfigure.event);
+ setuv (window, xe->xconfigure.window);
+
+ switch (xe->type)
+ {
+ case ConfigureNotify:
+ setiv (x, xe->xconfigure.x);
+ setiv (y, xe->xconfigure.y);
+ setiv (width, xe->xconfigure.width);
+ setiv (height, xe->xconfigure.height);
+ setuv (above, xe->xconfigure.above);
+ break;
+ }
- case MotionNotify:
- setiv (is_hint, xe->xmotion.is_hint);
break;
}
diff --git a/src/urxvt.pm b/src/urxvt.pm
--- a/src/urxvt.pm +++ b/src/urxvt.pm @@ -436,6 +436,8 @@ does focus in processing. Called wheneever the window loses keyboard focus, before rxvt-unicode does focus out processing. +=item on_configure_notify $term, $event + =item on_key_press $term, $event, $keysym, $octets =item on_key_release $term, $event, $keysym
-----END OF PAGE-----