return FALSE;
return TRUE;
im_hangul3_automata(GtkIMContextHangul *hcontext,		    GdkEventKey *key){  gunichar ch;  guint keyval, state;  if (pref_use_dvorak) {    keyval = im_hangul_dvorak_to_qwerty(key->keyval);    state = key->state;  } else {    keyval = key->keyval;    state = key->state;  }  ch = im_hangul3_mapping(keyval, state);  if (manual_mode) {    if (hcontext->jongseong[0]) {      if (im_hangul_is_choseong(ch)) {        im_hangul_commit(hcontext);        hcontext->choseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jungseong(ch)) {        im_hangul_commit(hcontext);        hcontext->jungseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jongseong(ch)) {        if (!im_hangul_add_jongseong(hcontext, ch)) {          im_hangul_commit(hcontext);          hcontext->jongseong[0] = ch;        }        im_hangul_push(hcontext, ch);        goto done;      }    } else if (hcontext->jungseong[0]) {      if (im_hangul_is_choseong(ch)) {        im_hangul_commit(hcontext);        hcontext->choseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jungseong(ch)) {        if (!im_hangul_add_jungseong(hcontext, ch)) {          im_hangul_commit(hcontext);          hcontext->jungseong[0] = ch;        }        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jongseong(ch)) {        hcontext->jongseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }    } else if (hcontext->choseong[0]) {      if (im_hangul_is_choseong(ch)) {        if (!im_hangul_add_choseong(hcontext, ch)) {          im_hangul_commit(hcontext);          hcontext->choseong[0] = ch;        }        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jungseong(ch)) {        hcontext->jungseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jongseong(ch)) {        im_hangul_commit(hcontext);        hcontext->jongseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }    } else {      if (im_hangul_is_choseong(ch)) {        hcontext->choseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jungseong(ch)) {        hcontext->jungseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jongseong(ch)) {        hcontext->jongseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }    }    /* treat backspace */    if (im_hangul_is_backspace(key)) {      ch = im_hangul_pop(hcontext);      if (ch == 0)        return FALSE;       if (im_hangul_is_choseong(ch)) {        im_hangul_sub_choseong(hcontext);        goto done;      }      if (im_hangul_is_jungseong(ch)) {        im_hangul_sub_jungseong(hcontext);        goto done;      }      if (im_hangul_is_jongseong(ch)) {        im_hangul_sub_jongseong(hcontext);        goto done;      }      return FALSE;    }  } else {    /* choseong */    if (im_hangul_is_choseong(ch)) {      if (hcontext->choseong[0] == 0) {        hcontext->choseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_choseong(im_hangul_peek(hcontext))) {        gunichar choseong = im_hangul_compose(hcontext->choseong[0], ch);        if (choseong) {          hcontext->choseong[0] = choseong;          im_hangul_push(hcontext, choseong);          goto done;        }      }      im_hangul_commit(hcontext);      hcontext->choseong[0] = ch;      im_hangul_push(hcontext, ch);      goto done;    }    /* junseong */    if (im_hangul_is_jungseong(ch)) {      if (hcontext->jungseong[0] == 0) {        hcontext->jungseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jungseong(im_hangul_peek(hcontext))) {        gunichar jungseong = im_hangul_compose(hcontext->jungseong[0], ch);        if (jungseong) {          hcontext->jungseong[0] = jungseong;          im_hangul_push(hcontext, jungseong);          goto done;        }      }      im_hangul_commit(hcontext);      hcontext->jungseong[0] = ch;      im_hangul_push(hcontext, ch);      goto done;    }    /* jongseong */    if (im_hangul_is_jongseong(ch)) {      if (hcontext->jongseong[0] == 0) {        hcontext->jongseong[0] = ch;        im_hangul_push(hcontext, ch);        goto done;      }      if (im_hangul_is_jongseong(im_hangul_peek(hcontext))) {        gunichar jongseong = im_hangul_compose(hcontext->jongseong[0], ch);        if (jongseong) {          hcontext->jongseong[0] = jongseong;          im_hangul_push(hcontext, jongseong);          goto done;        }      }      im_hangul_commit(hcontext);      hcontext->jongseong[0] = ch;      im_hangul_push(hcontext, ch);      goto done;    }    /* treat backspace */    if (im_hangul_is_backspace(key)) {      ch = im_hangul_pop(hcontext);      if (ch == 0)        return FALSE;      if (im_hangul_is_choseong(ch)) {        ch = im_hangul_peek(hcontext);        hcontext->choseong[0] = im_hangul_is_choseong(ch) ? ch : 0;        goto done;      }      if (im_hangul_is_jungseong(ch)) {        ch = im_hangul_peek(hcontext);        hcontext->jungseong[0] = im_hangul_is_jungseong(ch) ? ch : 0;        goto done;      }      if (im_hangul_is_jongseong(ch)) {        ch = im_hangul_peek(hcontext);        hcontext->jongseong[0] = im_hangul_is_jongseong(ch) ? ch : 0;        goto done;      }      return FALSE;    }  }  /* number and puctuation */  if (ch > 0) {    im_hangul_commit(hcontext);    im_hangul_commit_unicode(hcontext, ch);    hcontext->state = STATE_HANGUL;    goto done;  }  if (im_hangul_is_trigger(key)) {    im_hangul_commit(hcontext);    g_signal_emit_by_name(hcontext, "preedit_changed");    im_hangul_mode_direct(hcontext);    return FALSE;  }  if (hcontext->index >= 0) {    im_hangul_commit(hcontext);    g_signal_emit_by_name(hcontext, "preedit_changed");  }  return im_hangul_process_nonhangul(hcontext, key);done:  g_signal_emit_by_name(hcontext, "preedit_changed");  return TRUE;}