Hi Havoc, Thanks for your kind reply ! Problem solved ! Now NEdit functions flawlessly while being embedded inside a Gtk App ! My problem was not sending the synthetic event to the NEDit window, because I already saw an example of this being done at gtksocket.c/gtk_socket_send_configure_event(), where a call to XSentEvent() was used (However I did have to correct the parameters in that call, the wrong Event mask was used -- NoEventMask instead of StructureNotifyMask, so probably the NEdit window did proces the event, but discarded it right away because the mask was empty). Rather the problem was to know/get an indication, when the window manager moves my window around. You supplied the important piece of information, that I did not know about, that the window manager send a (synthetic) configure event to the top level window when the window manager moves the app around. Initially I did not think that this would happen, since when the app is moved around by the window manager, the top level window of the app does not move/resize at all relative to its parent, which is the frame/decoration that the WM puts. I solved the problem by adding an event filter function for my Gtk top level window, and when I detected an ConfigureNotify event on the top level window, I sent a ConfigureNotify event to the NEDit window. So now I have a nice NEdit window embedded within a Gtk VBOX ... I can now extent NEdit with much needed (IMHO) Tree View and Tabs and what have you, without (almost) any change to NEdit code ... What do you think the prospects of my (small) changes in gtksocket.c making it to the main branch ? About two of these changes I believe to be bug fixes, but I'm too much of a newbie to get a good perspective on what I've done (learn Xlib/ICCCM2/Gtk-C/Gtk-Perl/NEdit in one week .. too much .. have to wait some time to get perspective). thanks again for your kind help ! Gal Aviel. On Sat, 2003-06-07 at 07:46, Havoc Pennington wrote: > > On Sat, Jun 07, 2003 at 01:28:10AM +0300, Gal Aviel wrote: > > If I can somehow monitor (via a signal, or similar) when my app is being > > moved by the window manager, then I can send a dummy event to the > > (formerly top level) embedded window, and the pop down menu(s) will be > > updated. However I don't know how. > > You want configure_event on the GtkWindow. > > (This is the event that your embedded NEdit is not receiving, for > exactly the reason you explained.) > > What you can do is simply sythesize a ConfigureNotify event for the > NEdit window, just as a window manager would. See for example > the function send_configure_notify() in metacity/src/window.c, > or the equivalent function in any window manager. > > Havoc > _______________________________________________ > > gtk-list@gnome.org > http://mail.gnome.org/mailman/listinfo/gtk-list