diff options
| author | Gerd Moellmann | 2001-06-25 15:36:53 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2001-06-25 15:36:53 +0000 |
| commit | cbec8c518d92c2d9296f177f695407508b038eae (patch) | |
| tree | 262475888483d8c653a295b41b1cc1bd496ee684 /src | |
| parent | 2b9c25e0c25b7d587b4518c3686d7262707e965a (diff) | |
| download | emacs-cbec8c518d92c2d9296f177f695407508b038eae.tar.gz emacs-cbec8c518d92c2d9296f177f695407508b038eae.zip | |
(EmacsFrameSetCharSize): Set XtNwaitForWm depending
on the value of the wait-for-wm frame parameter.
Diffstat (limited to 'src')
| -rw-r--r-- | src/widget.c | 44 |
1 files changed, 31 insertions, 13 deletions
diff --git a/src/widget.c b/src/widget.c index 46be70eca52..a7ba3e3536e 100644 --- a/src/widget.c +++ b/src/widget.c | |||
| @@ -525,12 +525,12 @@ update_wm_hints (ew) | |||
| 525 | /* ((WMShellWidget) wmshell)->wm.size_hints.flags |= USSize;*/ | 525 | /* ((WMShellWidget) wmshell)->wm.size_hints.flags |= USSize;*/ |
| 526 | 526 | ||
| 527 | XtVaSetValues (wmshell, | 527 | XtVaSetValues (wmshell, |
| 528 | XtNbaseWidth, base_width, | 528 | XtNbaseWidth, (XtArgVal) base_width, |
| 529 | XtNbaseHeight, base_height, | 529 | XtNbaseHeight, (XtArgVal) base_height, |
| 530 | XtNwidthInc, cw, | 530 | XtNwidthInc, (XtArgVal) cw, |
| 531 | XtNheightInc, ch, | 531 | XtNheightInc, (XtArgVal) ch, |
| 532 | XtNminWidth, base_width + min_cols * cw, | 532 | XtNminWidth, (XtArgVal) (base_width + min_cols * cw), |
| 533 | XtNminHeight, base_height + min_rows * ch, | 533 | XtNminHeight, (XtArgVal) (base_height + min_rows * ch), |
| 534 | NULL); | 534 | NULL); |
| 535 | } | 535 | } |
| 536 | 536 | ||
| @@ -853,7 +853,8 @@ EmacsFrameSetValues (cur_widget, req_widget, new_widget, dum1, dum2) | |||
| 853 | if (cur->emacs_frame.iconic != new->emacs_frame.iconic) | 853 | if (cur->emacs_frame.iconic != new->emacs_frame.iconic) |
| 854 | { | 854 | { |
| 855 | Widget wmshell = get_wm_shell ((Widget) cur); | 855 | Widget wmshell = get_wm_shell ((Widget) cur); |
| 856 | XtVaSetValues (wmshell, XtNiconic, new->emacs_frame.iconic, NULL); | 856 | XtVaSetValues (wmshell, XtNiconic, |
| 857 | (XtArgVal) new->emacs_frame.iconic, NULL); | ||
| 857 | } | 858 | } |
| 858 | 859 | ||
| 859 | return needs_a_refresh; | 860 | return needs_a_refresh; |
| @@ -939,22 +940,39 @@ EmacsFrameSetCharSize (widget, columns, rows) | |||
| 939 | int old_left = f->output_data.x->widget->core.x; | 940 | int old_left = f->output_data.x->widget->core.x; |
| 940 | int old_top = f->output_data.x->widget->core.y; | 941 | int old_top = f->output_data.x->widget->core.y; |
| 941 | 942 | ||
| 943 | /* Input is blocked here, and Xt waits for some event to | ||
| 944 | occur. */ | ||
| 945 | |||
| 942 | lw_refigure_widget (f->output_data.x->column_widget, False); | 946 | lw_refigure_widget (f->output_data.x->column_widget, False); |
| 943 | update_hints_inhibit = 1; | 947 | update_hints_inhibit = 1; |
| 944 | 948 | ||
| 949 | /* Xt waits for a ConfigureNotify event from the window manager | ||
| 950 | in EmacsFrameSetCharSize when the shell widget is resized. | ||
| 951 | For some window managers like fvwm2 2.2.5 and KDE 2.1 this | ||
| 952 | event doesn't arrive for an unknown reason and Emacs hangs in | ||
| 953 | Xt when the default font is changed. Tell Xt not to wait, | ||
| 954 | depending on the value of the frame parameter | ||
| 955 | `wait-for-wm'. */ | ||
| 956 | XtVaSetValues (f->output_data.x->widget, | ||
| 957 | XtNwaitForWm, (XtArgVal) f->output_data.x->wait_for_wm, | ||
| 958 | NULL); | ||
| 959 | |||
| 945 | /* Do parents first, otherwise LessTif's geometry management | 960 | /* Do parents first, otherwise LessTif's geometry management |
| 946 | enters an infinite loop (as of 2000-01-15). This is fixed in | 961 | enters an infinite loop (as of 2000-01-15). This is fixed in |
| 947 | later versions of LessTif (as of 2001-03-13); I'll leave it | 962 | later versions of LessTif (as of 2001-03-13); I'll leave it |
| 948 | as is because I think it can't do any harm. */ | 963 | as is because I think it can't do any harm. */ |
| 949 | XtVaSetValues (f->output_data.x->widget, | 964 | XtVaSetValues (f->output_data.x->widget, |
| 950 | XtNheight, outer_widget_height + hdelta, | 965 | XtNheight, (XtArgVal) (outer_widget_height + hdelta), |
| 951 | XtNwidth, outer_widget_width + wdelta, NULL); | 966 | XtNwidth, (XtArgVal) (outer_widget_width + wdelta), |
| 967 | NULL); | ||
| 952 | XtVaSetValues (f->output_data.x->column_widget, | 968 | XtVaSetValues (f->output_data.x->column_widget, |
| 953 | XtNheight, column_widget_height + hdelta, | 969 | XtNheight, (XtArgVal) (column_widget_height + hdelta), |
| 954 | XtNwidth, column_widget_width + wdelta, NULL); | 970 | XtNwidth, (XtArgVal) column_widget_width + wdelta, |
| 971 | NULL); | ||
| 955 | XtVaSetValues ((Widget) ew, | 972 | XtVaSetValues ((Widget) ew, |
| 956 | XtNheight, pixel_height, | 973 | XtNheight, (XtArgVal) pixel_height, |
| 957 | XtNwidth, pixel_width, NULL); | 974 | XtNwidth, (XtArgVal) pixel_width, |
| 975 | NULL); | ||
| 958 | 976 | ||
| 959 | lw_refigure_widget (f->output_data.x->column_widget, True); | 977 | lw_refigure_widget (f->output_data.x->column_widget, True); |
| 960 | 978 | ||