Costin Chirvasuta
unread,May 13, 2013, 1:33:42 PM5/13/13You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
Hello,
I made this quick little hack to do what the subject says.
Sharing for anyone who might find it useful.
diff /n/sources/plan9/sys/src/cmd/rio/rio.c /sys/src/cmd/rio/rio.c
779a780,802
> if(mouse->buttons == 0 && eqpt(mouse->xy, p)){
> p = onscreen(mouse->xy);
> if(p.x < screen->clipr.min.x + 10){
> p0.x = screen->clipr.min.x;
> p0.y = screen->clipr.min.y;
> p.x = (screen->clipr.max.x + screen->clipr.min.x) / 2;
> p.y = screen->clipr.max.y;
> }else if(p.x > screen->clipr.max.x - 10){
> p0.x = (screen->clipr.max.x + screen->clipr.min.x) / 2;
> p0.y = screen->clipr.min.y;
> p.x = screen->clipr.max.x;
> p.y = screen->clipr.max.y;
> }else
> break;
> r = Rect(p0.x, p0.y, p.x, p.y);
> i = allocwindow(wscreen, r, Refnone, 0xEEEEEEFF);
> freeimage(oi);
> if(i == nil)
> goto Rescue;
> border(i, r, Selborder, red, ZP);
> flushimage(display, 1);
> break;
> }