Re: XForms: BLOODY tabfolders!

From: Angus Leeming (a.leeming@ic.ac.uk)
Date: Thu Oct 03 2002 - 07:34:47 EDT

  • Next message: Angus Leeming: "XForms: Howto update active folder x,y coords?"

    # To subscribers of the xforms list from Angus Leeming <a.leeming@ic.ac.uk> :

    One more thing.

    Displaying the tooltip and then closing the dialog from the
    keyboard results in fl_check_forms() spitting out some unhandled
    X11 events:

            while (form1->visible || form2->visible) {
                    if (fl_check_forms() == FL_EVENT) {
                            XEvent ev;
                            fl_XNextEvent(&ev);
                            printf("Received unhandled X11 event\n");
                            printf("Type: 0x%x Target: 0x%x\n",
                                   ev.xany.type, ev.xany.window);;
                    }
            }

    Received unhandled X11 event
    Type: 10 Target: 0x5800040
    Received unhandled X11 event
    Type: 9 Target: 0x5800040
    Received unhandled X11 event
    Type: 8 Target: 0x5800040

    From X.h:
    #define LeaveNotify 8
    #define FocusIn 9
    #define FocusOut 10

    Presumably 0x5800040 is the tooltip window (no way to confirm
    without adding a print statement in the xforms src and
    recompiling). It most certainly is not the window of either
    form1 or form2.

    Is this just a necessary fallout of the Bug that I'll have to
    live with, or can I perform some magic trick?

    Regards,
    Angus

    On Thursday 03 October 2002 11:32 am, Angus Leeming wrote:
    > # To subscribers of the xforms list from Angus Leeming
    > <a.leeming@ic.ac.uk> :
    >
    > Apologies for the intemperate title.
    >
    > I have a fix for the tooltip never disappearing:
    >
    > // This should be in forms.h but isn't
    > extern void fl_hide_tooltip();
    >
    > void exit_cb(FL_OBJECT * ob, long data)
    > {
    > fl_hide_tooltip();
    > fl_hide_form(ob->form);
    > }
    >
    > So, should fl_hide_tooltip() be declared in forms.h or should
    > fl_hide_form() just call it anyway?
    >
    > Regards,
    > Angus
    >
    > On Wednesday 02 October 2002 7:00 pm, Angus Leeming wrote:
    > > Dear Steve et al.,
    > >
    > > attached is a sample piece of code that demonstrates two
    > > bugs with the current implementation of tooltips when used
    > > with tabfolders.
    > >
    > > Run the code and two little windows will pop up, one lying
    > > on top of the other.
    > >
    > > Move the mouse over the "Press me!" button on the topmost
    > > form and a tooltip is displayed. Super.
    > >
    > > Moving this form aside to display the other, move your mouse
    > > over the two "Press me!" buttons in turn.
    > >
    > > BUG 1. The position of the tooltip for the form just moved
    > > has not been updated.
    > >
    > > With the mouse over the "Press me!" button close the form
    > > using the Alt-E shortcut.
    > >
    > > BUG 2. The form disappears but the tooltip remains.
    > >
    > > BUG 1 is a direct result of the x,y coords of the FL_FORM
    > > holding the tabbed folder are not updated when the window is
    > > moved.
    > >
    > > Now we've moved to Open Source real fixes should be
    > > possible, but temporary work arounds would be nice too ;-)
    > > Any ideas?
    > >
    > > Angus
    > >
    > > ps, this code was compiled with RC5 and
    > > gcc -I/usr/local/include -o tooltip tooltip.c
    > > -L/usr/local/lib -lforms -lm
    _________________________________________________
    To unsubscribe, send the message "unsubscribe" to
    xforms-request@bob.usuhs.mil or see
    http://bob.usuhs.mil/mailserv/xforms.html
    XForms Home Page: http://world.std.com/~xforms
    List Archive: http://bob.usuhs.mil/mailserv/list-archives/



    This archive was generated by hypermail 2b29 : Thu Oct 03 2002 - 07:33:32 EDT