I have quite a few custom compose key sequences. I know I can get them working with an ~/.XCompose
and switching the input method to xim
. However, Sublime Text 2 doesn't accept any compose key sequences when I'm using xim
. It does accept them when I'm using the default input method. I think I reported this bug for Sublime Text 2 a while ago.
Using the default input method, I added the contents of my ~/.XCompose
to /usr/share/X11/locale/en_US.UTF-8/Compose
but this did not change anything. Is there any way I can get the compose key sequences in my ~/.XCompose
to work without relying on xim
?
I know you asked this a year ago, but in case it ever helps someone, here’s what worked for me to enable custom
.XCompose
additions:uim is an input method which respects the compose file additions, but also enables the functionality not available in xim, eg
Ctrl+Shift+U
to enter a hex Unicode character ID.This may work for the OP’s situation, if he still needs a solution, I don’t know.
What @coteyr says is, in fact, not correct. Sublime Text uses standard GTK input method API, however, it does so incorrectly.
I made a package that fixes Sublime Text. You can find all the details on the bug and my workaround on my blog post but here's a quick overview of the installation:
Add the
sublime-imethod-fix
-PPA to your APT sources by executing the following command:Install the bugfix package that corresponds with your Sublime Text version:
for XCompose support in ST2:
for XCompose support in ST3:
This is a hugely random guess, but I think it's because Sublime Text is using a different widget library and that one isn't setup for xim input.
You can try (if you haven't already) setting up persistent configuration at this link
If that doesn't work you can always hack IM support back in.
This post should assist with that.
Both are pretty technical and both mean going out of your way a bit to make it work.
Here's a workaround for Sublime Text 2 specifically. Install this package, either via Package Control or manually:
After restarting Sublime you can access an input window for composed key sequences with Ctrl + Shift + Z. Hit Enter to insert the sequence at the cursor position.