Hi all, Sorry to butt in on you mailing list but we have a problem on the sawmill Window Manager project that I thought you folks might be able to help with: In Sawmill we have a problem that when invoking a popup menu too close to the right-hand-edge of the screen, some of it disappears off the screen. I noticed this problem in abiword as well but not in Dia. John Harper the developer for sawmill doesn't have any solutions to the problem; his menus are created dynamically in a sub-program and he doesn't know there size before they are invoked. Any clues would be very much be appreciated, thanks. Here's a message on the subject from the sawmill mailing list. BTW I don't subscribe to the Dia list so please CC [EMAIL PROTECTED] any discussion, thanks.
John Harper writes: > Kai Gro�johann writes: > |I observe the following: when pressing a mouse button over a titlebar > |button, the left edge of the menu is always aligned with the left edge > |of the button, even when that means that the menu is partly > |off-screen. When pressing a mouse button in the title bar, the left > |edge of the menu is normally aligned with the mouse pointer, except > |when that would put the menu partly off-screen. > | > |John, is this a bug? > > I guess. But there's nothing sawmill can do about it. It tries to align > menus with the button they were invoked from. But GTK only allows the > left edge of the menu to be specified. Also there's no way to tell a > priori how large the realised menu will be This doesn't make sense to me. You are in control of the menu even if you don't know the dimensions of the menu before you draw, you know them after. Can't you just then move the menu to a more appropriate position? Or are you locked out by GTK? Even so you must build the menu somehow so just before you invoke it you must know its size? Other Gnome apps don't have this problem; its peculiar to sawmill. Sorry about the ramblings but I've never written a GTK app so Im just speculating. I think this is a serious bug that requires at least a temporary hack around if an elegant solution can't be found; Menus disappearing off the screen just ain't cool :( OK I see that Abiword has this problem but Dia does not. Does any GTK expert read this list and can shed some like on this? I'll forward this to the Dia developer. Maybe some GTK expert -- Geoff Jacobsen. May the source be with you, Always.
