> Running Edzard's demo program (with 1.1.9 on XP - but I'm fairly sure > other platforms are similar) I observe the problem as follows: > > Now, this causes a cascade effect: The first submenu opens, and is > "pushed" back to the left by hitting the edge of the screen. > This forces its first item to be "under the mouse", so the next submenu > layer opens instantly, which is pushed back under the mouse... Until you > are left at the bottom sub-menu. It is not possible to select any of the > intermediate menu levels at all.
Yes, maybe the real problem is not layout of items, but automatic choose of submenu. I met the problem first using a menubutton with some direct items and a submenu in the middle. When opening the menubutton (placed on bottom of window) and going up, it was not possible to reach items above the submenu, because it opens and hides the rest of upper level. I found the workaround to open the menu, move the mouse cursor out of the menu (it stays open) and reenter the menu above the submenu. If always working, this would be okay to me, but you see, there are cases that prevent to choose parts of menu at all. But sometimes (didn't find a way to reproduce it) the submenu opens, but the cursor stays in the upper menu, so submenu was changing, when moving the mouse down. >> 1. Every submenu should check, whether it covers the next >> higher submenu and move to a point, where it doesn't. > > I think this is what (some?) other toolkits do. Testing on this XP box, > I see that menus that would pass the right edge of the screen are > instead drawn to the left of their parent rather than to the right, so > that the parent is not covered. Do you see this using FLTK or another toolkit? I think, that I have seen this behaviour before using FLTK, but this time it doesn't work. >> 2. When touching the right border of screen, the menu should >> move the x0 >> of the whole menu to the left. This seems most easy to me. > > I'm not sure I follow this - is this the effect I described in my > comment for (1)? No, I mean the left side of menu - normally it sticks to the point, where menu was called, i.e. Fl_Menu_Button, and spreads to the right side. When touching the right border, it might be a solution to move the left side of the whole menu. Even if it leaves screen on left side this would be no problem, because only the upper levels of menu, that had been choosen before, were not in the view any more. >> A workaround may be, to make every submenu a little smaller, then the > Oh, I don't like the sound of that much. And I'm not sure, whether this really works - I made some attempts, but finally decided, that I should try to solve the basic problem. _______________________________________________ fltk mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk

