summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Faure <billiob@gmail.com>2020-07-19 16:43:36 +0200
committerBoris Faure <billiob@gmail.com>2021-02-12 15:52:30 +0100
commitd096b4bc34faefdbc6f6213d553d0c48bf705a7d (patch)
tree3dea473bf2ee67db4f6fdc31f59f30e0595a7b07
parentb3a1c400ac00233126e89d0ecdde7bf4e4e5994c (diff)
ecore_imf_xim: remove calls to XCreateFontSet()devs/billiob/imf_xim_issue
Summary: I use ECORE_IMF_MODULE=xim for ages and I had random crashes here, mostly on terminology's start-up. I've done that patch months ago (if not late last year) and I have not had a single crash since then. Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D12059
-rw-r--r--src/modules/ecore_imf/xim/ecore_imf_xim.c29
1 files changed, 3 insertions, 26 deletions
diff --git a/src/modules/ecore_imf/xim/ecore_imf_xim.c b/src/modules/ecore_imf/xim/ecore_imf_xim.c
index 5bb8c4ae2e..09e98c5c9b 100644
--- a/src/modules/ecore_imf/xim/ecore_imf_xim.c
+++ b/src/modules/ecore_imf/xim/ecore_imf_xim.c
@@ -1128,32 +1128,9 @@ _ecore_imf_xim_ic_get(Ecore_IMF_Context *ctx)
1128 1128
1129 if (imf_context_data->use_preedit == EINA_TRUE) 1129 if (imf_context_data->use_preedit == EINA_TRUE)
1130 { 1130 {
1131 if (im_info->supports_cursor) 1131 im_style |= XIMPreeditCallbacks;
1132 { 1132 im_style |= XIMStatusNothing;
1133 // kinput2 DOES do this... 1133 preedit_attr = _ecore_imf_xim_preedit_callback_set(ctx);
1134 XFontSet fs;
1135 char **missing_charset_list;
1136 int missing_charset_count;
1137 char *def_string;
1138
1139 im_style |= XIMPreeditPosition;
1140 im_style |= XIMStatusNothing;
1141 fs = XCreateFontSet(ecore_x_display_get(),
1142 "fixed",
1143 &missing_charset_list,
1144 &missing_charset_count,
1145 &def_string);
1146 preedit_attr = XVaCreateNestedList(0,
1147 XNSpotLocation, &spot,
1148 XNFontSet, fs,
1149 NULL);
1150 }
1151 else
1152 {
1153 im_style |= XIMPreeditCallbacks;
1154 im_style |= XIMStatusNothing;
1155 preedit_attr = _ecore_imf_xim_preedit_callback_set(ctx);
1156 }
1157 name = XNPreeditAttributes; 1134 name = XNPreeditAttributes;
1158 } 1135 }
1159 else 1136 else