From: Richard M. Stallman Date: Mon, 9 May 1994 05:08:06 +0000 (+0000) Subject: (x_set_window_size) [USE_X_TOOLKIT]: X-Git-Tag: emacs-19.34~8438 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=3a20653d462b04ef912c62e102d0dab8e297fac7;p=emacs.git (x_set_window_size) [USE_X_TOOLKIT]: Preserve the main widget's x and y position. --- diff --git a/src/xterm.c b/src/xterm.c index bc6b614f4dc..e994465c4bc 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -5244,7 +5244,17 @@ x_set_window_size (f, change_gravity, cols, rows) #ifdef USE_X_TOOLKIT BLOCK_INPUT; - EmacsFrameSetCharSize (f->display.x->edit_widget, cols, rows); + { + /* The x and y position of the widget is clobbered by the + call to XtSetValues within EmacsFrameSetCharSize. + This is a real kludge, but I don't understand Xt so I can't + figure out a correct fix. Can anyone else tell me? -- rms. */ + int xpos = f->display.x->widget->core.x; + int ypos = f->display.x->widget->core.y; + EmacsFrameSetCharSize (f->display.x->edit_widget, cols, rows); + f->display.x->widget->core.x = xpos; + f->display.x->widget->core.y = ypos; + } UNBLOCK_INPUT; #else /* not USE_X_TOOLKIT */