Mercurial > hg > xemacs-beta
comparison src/input-method-motif.c @ 771:943eaba38521
[xemacs-hg @ 2002-03-13 08:51:24 by ben]
The big ben-mule-21-5 check-in!
Various files were added and deleted. See CHANGES-ben-mule.
There are still some test suite failures. No crashes, though.
Many of the failures have to do with problems in the test suite itself
rather than in the actual code. I'll be addressing these in the next
day or so -- none of the test suite failures are at all critical.
Meanwhile I'll be trying to address the biggest issues -- i.e. build
or run failures, which will almost certainly happen on various platforms.
All comments should be sent to ben@xemacs.org -- use a Cc: if necessary
when sending to mailing lists. There will be pre- and post- tags,
something like
pre-ben-mule-21-5-merge-in, and
post-ben-mule-21-5-merge-in.
author | ben |
---|---|
date | Wed, 13 Mar 2002 08:54:06 +0000 |
parents | 98b3721724bd |
children | 7da79fbe37bb |
comparison
equal
deleted
inserted
replaced
770:336a418893b5 | 771:943eaba38521 |
---|---|
34 | 34 |
35 #ifndef XIM_MOTIF | 35 #ifndef XIM_MOTIF |
36 #error XIM_MOTIF is not defined?? | 36 #error XIM_MOTIF is not defined?? |
37 #endif | 37 #endif |
38 | 38 |
39 void | |
40 Initialize_Locale (void) | |
41 { | |
42 char *locale; | |
43 | |
44 /* dverna - Nov. 98: #### DON'T DO THIS !!! The default XtLanguageProc | |
45 routine calls setlocale(LC_ALL, lang) which fucks up our lower-level | |
46 locale management, and especially the value of LC_NUMERIC. Anyway, since | |
47 at this point, we don't know yet whether we're gonna need an X11 frame, | |
48 we should really do it manually and not use Xlib's dumb default routine */ | |
49 /*XtSetLanguageProc (NULL, (XtLanguageProc) NULL, NULL);*/ | |
50 if ((locale = setlocale (LC_ALL, "")) == NULL) | |
51 { | |
52 stderr_out ("Can't set locale.\n"); | |
53 stderr_out ("Using C locale instead.\n"); | |
54 putenv ("LANG=C"); | |
55 putenv ("LC_ALL=C"); | |
56 if ((locale = setlocale (LC_ALL, "C")) == NULL) | |
57 { | |
58 stderr_out ("Can't even set locale to `C'!\n"); | |
59 return; | |
60 } | |
61 } | |
62 | |
63 if (!XSupportsLocale ()) | |
64 { | |
65 stderr_out ("X Windows does not support locale `%s'\n", locale); | |
66 stderr_out ("Using C Locale instead\n"); | |
67 putenv ("LANG=C"); | |
68 putenv ("LC_ALL=C"); | |
69 if ((locale = setlocale (LC_ALL, "C")) == NULL) | |
70 { | |
71 stderr_out ("Can't even set locale to `C'!\n"); | |
72 return; | |
73 } | |
74 if (!XSupportsLocale ()) | |
75 { | |
76 stderr_out ("X Windows does not even support locale `C'!\n"); | |
77 return; | |
78 } | |
79 } | |
80 | |
81 setlocale(LC_NUMERIC, "C"); | |
82 | |
83 if (XSetLocaleModifiers ("") == NULL) | |
84 { | |
85 stderr_out ("XSetLocaleModifiers(\"\") failed\n"); | |
86 stderr_out ("Check the value of the XMODIFIERS environment variable.\n"); | |
87 } | |
88 } | |
89 | 39 |
90 /* Create X input method for device */ | 40 /* Create X input method for device */ |
91 void | 41 void |
92 XIM_init_device (struct device *d) | 42 XIM_init_device (struct device *d) |
93 { | 43 { |