Mercurial > emacs
comparison src/widget.c @ 38219:f70ea2b09e46
(EmacsFrameSetCharSize): Turn off atimers and block
SIGIO around the code where Xt might wait for a
ConfigureNotifyEvent.
(toplevel): Include <signal.h> and syssignal.h.
author | Gerd Moellmann <gerd@gnu.org> |
---|---|
date | Wed, 27 Jun 2001 17:15:56 +0000 |
parents | fd45b8013008 |
children | b339083b4be1 |
comparison
equal
deleted
inserted
replaced
38218:ab6119af2d6b | 38219:f70ea2b09e46 |
---|---|
48 #include "widgetprv.h" | 48 #include "widgetprv.h" |
49 #include <X11/ObjectP.h> | 49 #include <X11/ObjectP.h> |
50 #include <X11/Shell.h> | 50 #include <X11/Shell.h> |
51 #include <X11/ShellP.h> | 51 #include <X11/ShellP.h> |
52 #include "../lwlib/lwlib.h" | 52 #include "../lwlib/lwlib.h" |
53 | |
54 #include <signal.h> | |
55 #include "syssignal.h" | |
53 | 56 |
54 #define max(a, b) ((a) > (b) ? (a) : (b)) | 57 #define max(a, b) ((a) > (b) ? (a) : (b)) |
55 | 58 |
56 /* This sucks: this is the first default that x-faces.el tries. This won't | 59 /* This sucks: this is the first default that x-faces.el tries. This won't |
57 be used unless neither the "Emacs.EmacsFrame" resource nor the | 60 be used unless neither the "Emacs.EmacsFrame" resource nor the |
954 depending on the value of the frame parameter | 957 depending on the value of the frame parameter |
955 `wait-for-wm'. */ | 958 `wait-for-wm'. */ |
956 XtVaSetValues (f->output_data.x->widget, | 959 XtVaSetValues (f->output_data.x->widget, |
957 XtNwaitForWm, (XtArgVal) f->output_data.x->wait_for_wm, | 960 XtNwaitForWm, (XtArgVal) f->output_data.x->wait_for_wm, |
958 NULL); | 961 NULL); |
962 | |
963 /* Workaround: When a SIGIO or SIGALRM occurs while Xt is | |
964 waiting for a ConfigureNotify event (see above), this leads | |
965 to Xt waiting indefinitely instead of using its default | |
966 timeout (5 seconds). */ | |
967 turn_on_atimers (0); | |
968 #ifdef SIGIO | |
969 sigblock (sigmask (SIGIO)); | |
970 #endif | |
959 | 971 |
960 /* Do parents first, otherwise LessTif's geometry management | 972 /* Do parents first, otherwise LessTif's geometry management |
961 enters an infinite loop (as of 2000-01-15). This is fixed in | 973 enters an infinite loop (as of 2000-01-15). This is fixed in |
962 later versions of LessTif (as of 2001-03-13); I'll leave it | 974 later versions of LessTif (as of 2001-03-13); I'll leave it |
963 as is because I think it can't do any harm. */ | 975 as is because I think it can't do any harm. */ |
971 NULL); | 983 NULL); |
972 XtVaSetValues ((Widget) ew, | 984 XtVaSetValues ((Widget) ew, |
973 XtNheight, (XtArgVal) pixel_height, | 985 XtNheight, (XtArgVal) pixel_height, |
974 XtNwidth, (XtArgVal) pixel_width, | 986 XtNwidth, (XtArgVal) pixel_width, |
975 NULL); | 987 NULL); |
976 | 988 #ifdef SIGIO |
989 sigunblock (sigmask (SIGIO)); | |
990 #endif | |
991 turn_on_atimers (1); | |
992 | |
977 lw_refigure_widget (f->output_data.x->column_widget, True); | 993 lw_refigure_widget (f->output_data.x->column_widget, True); |
978 | 994 |
979 update_hints_inhibit = 0; | 995 update_hints_inhibit = 0; |
980 update_wm_hints (ew); | 996 update_wm_hints (ew); |
981 | 997 |