[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: address@hidden: [21.2.90]: Lesstif menu placement after frame resize
From: |
Harald . Maier . BW |
Subject: |
Re: address@hidden: [21.2.90]: Lesstif menu placement after frame resize] |
Date: |
Sat, 05 Oct 2002 17:34:28 +0200 |
User-agent: |
Gnus/5.090008 (Oort Gnus v0.08) Emacs/21.2.90 (i386-mingw-nt5.0.2195) |
"Jan D." <address@hidden> writes:
> Yes, this only happens with CDE to my knowledge. It is because a
> workaround for bad ConfigureNotify events that doesn't take into
> account position changes because of resize. This bug is at least as
> old as Emacs 21.1 (the oldest I got), but could be older.
UUps, it's not only the CDE environment. I got the problem too with
windowmaker then I resize the Window with 'Mod + Mouse 3' inside the
emacs window. I debugged into your fix and in the special case
windowmaker set not for both event.xconfigure.x and event.xconfigure.y
a zero value.
See line:
if (event.xconfigure.x == 0 && event.xconfigure.y == 0)
event.xconfigure.x is always 0 and event.xconfigure.y is 22. I don't
know whether this makes sense because it does not matter whether I
resize in X or Y direction. Really inconsistent or is this the
additional _header border_ ...
If I use a _OR_ condition in the above line
if (event.xconfigure.x || 0 && event.xconfigure.y == 0)
it seems to work but I don't know which impact this has to other
processing. I tried it for a while and I could not see any harmful
behavior. Anyway the other processing of your patch works _wonderful_
too with windowmaker so I think the fix is really a gift because the
current behavior is extremely annoying. Thanks!
I will test this too on Monday in a CDE conext at work. Currently I
don't have such a context. I dropped last week here a really old CDE
environment.
Harald
> I've checked in this fix in CVS. Should it go in RC also?
>
> Jan D.
>
> Index: xterm.c
> *** xterm.c.~1.753.~ 2002-10-03 19:25:46.000000000 +0200
> --- xterm.c 2002-10-03 19:44:17.000000000 +0200
> ***************
> *** 11179,11186 ****
> in the emacs widget, which messes up Motif menus. */
> if (event.xconfigure.x == 0 && event.xconfigure.y == 0)
> {
> ! event.xconfigure.x = f->output_data.x->widget->core.x;
> ! event.xconfigure.y = f->output_data.x->widget->core.y;
> }
> #endif /* USE_MOTIF */
> }
> --- 11179,11202 ----
> in the emacs widget, which messes up Motif menus. */
> if (event.xconfigure.x == 0 && event.xconfigure.y == 0)
> {
> ! Window child;
> ! int count;
> !
> ! /* We can get a ConfigureNotify because of a resize,
> ! so we can't just take x and y from the widget.
> ! Since this event may come on something else than
> ! the top level window, we can't use x_real_position
> ! either. So we get the root window x/y for 0/0 in
> ! the window in the event. */
> ! count = x_catch_errors (FRAME_X_DISPLAY (f));
> ! XTranslateCoordinates (FRAME_X_DISPLAY (f),
> ! event.xconfigure.window,
> ! FRAME_X_DISPLAY_INFO
> (f)->root_window,
> ! 0, 0,
> ! &event.xconfigure.x,
> ! &event.xconfigure.y,
> ! &child);
> ! x_uncatch_errors (FRAME_X_DISPLAY (f), count);
> }
> #endif /* USE_MOTIF */
> }
Re: address@hidden: [21.2.90]: Lesstif menu placement after frame resize],
Harald . Maier . BW <=