Re: XForms: overwrite mode for fl_input?

Steve Lamont (spl@szechuan.ucsd.edu)
Fri, 6 Mar 98 18:33:33 PST

# To subscribers of the xforms list from spl@szechuan.ucsd.edu (Steve Lamont) :

> I'm looking for something like:
>
> fl_set_input_mode(obj, FL_OVER_WRITE);

That would be cool. TC?

In the meantime, you could probably do it by using the input filter.

Since the filter is passed the old string, the new string, and the new
character, you could probably simply get the cursor position,
substitute the new character for the old character at the current
cursor position, set the input string to the modified string, and then
return FL_INVALID.

I haven't tried it, so I won't swear it'll work.

> Also, it would be nice to not loose the keyboard when the mouse pointer
> is outside of the form boundries.

That's a window manager function. There has been considerable
discussion of that on this list over the past year or so. I believe
0.88 is more cooperative in this regard but I can't stand "click to
focus" (too much like a Maggotbox for my taste), so I don't know
how true this is.

If you want to do this only for a short time, you can grab keyboard
focus with the appropriate Xlib call, though this is considered
somewhat antisocial.

spl
_________________________________________________
To unsubscribe, send the message "unsubscribe" to
xforms-request@bob.usuf2.usuhs.mil or see
http://bob.usuf2.usuhs.mil/mailserv/xforms.html
XForms Home Page: http://bragg.phys.uwm.edu/xforms
List Archive: http://bob.usuf2.usuhs.mil/mailserv/list-archives/