popup menu positioned partially off-screen

Howdy y'all. I have a GTK app that displays a GtkCList and when a user
clicks on a row, display a popup context menu via gtk_menu_popup(). I
don't provide a function to position it.

The problem is that if the mouse pointer is near the bottom or right
edge of the screen, the menu ends up being placed partially outside the

I looked at the the gtk/gtkmenu.c gtk_menu_position() internal function
that is supposed to position the menu based on the width and height of
the screen and the menu so that it is positioned within the screen. At
first glance this looks correct but it doesn't seem to work right for

Anyone else seen this behaviour with a pure GTK app? GNOME apps (not
GTK) that I've tried work as expected with the popup menu never going
beyond the screen bounds.

I already searched the bug reports but didn't find anything pertinent.


Luciano Chavez

lnx1138 us ibm com          

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]