I have made the patch to migrate the scim to gtk3. The patch is made from svn revision 329. Here is the summary:
* If only the gtk3 is available, scim will be built with gtk3, and gtk2_immodule is disabled.
* If only the gtk2 is available, scim will be built with gtk2, and gtk3_immodule is disabled.
* If both gtk2 and gtk3 are available, scim will be built with gtk3 by default, and both gtk2_immodule and gtk3_immodule will be built by default.
* User can use --with-gtk-version when configuring to specify the gtk version if both 2 and 3 are available.
* scim can be built with gtk3 cleanly.
I have tested the scim built with gtk3, it seems to work fine except the SetupUI part. When FrontEnd module is loaded, the gtk3 failed with the error "register a existing type `GtkWidget'". I don't know how to solve this problem at this moment. Basically I don't know why it is not a problem with gtk2.