# To subscribers of the xforms list from Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr> :
>>>>> "Jean-Marc" == Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr> writes:
Jean-Marc> I have done a small example of a bug that have been
Jean-Marc> plaguing LyX for a long time (file attached).
Jean-Marc> In the following example (butchered from the demo popup.c),
Jean-Marc> if you click on the button so that the menu appears, then
Jean-Marc> clicking just to the right of the button fails to close the
Jean-Marc> menu. This is a pain in LyX where the menu bar is a bunch
Jean-Marc> of this buttons and opening 'Edit' when 'File' is open is a
Jean-Marc> real problem.
Since it seems TC has had no time to look at this bug, I did a bit of
searching of my own (using an old sources snapshot from TC) and found
that the culprit is in handle_motion (xpopup.c) where the item number
cval is computed.
The comment below says it all:
/* if released on title bar, cval is zero. However, if there is no title,
change cval to -1 (invalid) if "too right" */
It happens that "too right" means "more than 1/3 of the menu width".
What's the reason for that? It is a real pain with LyX, when if the
File menu is open, clicking on Edit does nothing (not in the "too
right" area).
Another things that confuses me is that the example I gave does use a
title, so it should not have this problem. However, it certainly
explains the problem seen with LyX.
Hope this helps.
Another question: having an existing popup, is it possible to add a
separator to it? In our case, we do not know what the last entry is,
since we use %x to convey information about the function linked to the
entry. This means our current code is a bit more complicated than it
should.
JMarc
_________________________________________________
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 : Fri Nov 17 2000 - 10:10:11 EST