Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to input anything until switching windows #29

Open
NoSuck opened this issue Jul 26, 2019 · 5 comments
Open

Unable to input anything until switching windows #29

NoSuck opened this issue Jul 26, 2019 · 5 comments

Comments

@NoSuck
Copy link

NoSuck commented Jul 26, 2019

I am opening this issue because scim appeals to me very much. While other input method platforms grow larger and slower, scim remains simple and lean.

Is it being maintained? I see some commits. I know somebody is working.

Anyway, there is one major issue that prevents me from being able to use scim. It has been described elsewhere as a loss of focus, but in my experience window focus is never lost. Rather, scim suddenly stops sending input to the focused window. This has a tendency to happen when using Ctrl keyboard shortcuts, e.g. Ctrl + u in a terminal window running a shell.

Switching focus to another window, pressing a key or two, and switching back to the original window usually solves the issue. When it does not, switching again and pressing even more keys almost always does. Wash, rinse, repeat.

Other than this, scim is pretty much perfect (to me, at least). You can configure it with text files for crying out loud--a convenience that scim's alternatives seem to have completely forgotten.

Thank you and take care.

■ uname -srvmo
Linux 4.19.57-v7+ #1244 SMP Thu Jul 4 18:45:25 BST 2019 armv7l GNU/Linux
■ scim -h
Smart Common Input Method 1.4.18

P.S. I have also experienced this issue on a Debian system back in 2014. And I can almost always reproduce the issue after running the following command:

xdotool key --delay 150 --clearmodifiers "Shift_L+u"
@heroxbd
Copy link
Contributor

heroxbd commented Jul 27, 2019

Yes, I can confirm I have been bugged by this for a long time. Thank you raising this.

@tzhuan
Copy link
Member

tzhuan commented Jul 27, 2019

Thank you very much for reporting the issue.

I have tried the command xdotool key --delay 150 --clearmodifiers "Shift_L+u" in the gnome-terminal but after executed the command I still can toggle the scim with my shortcut (ctrl + space) and input the Chinese characters without problems (screencast). My system is debian buster with kernel 4.19.37-5 and scim 1.4.18 compiled by myself.

I am curious that which input mode do you use? xim or gtk? Which im-module do you use? scim or scim-orig? I am also curious about your keyboard shortcut settings.

@NoSuck
Copy link
Author

NoSuck commented Jul 27, 2019

I did not expect this kind of response. Thank you for taking interest. The screencast was... disheartening. ;)

This is what I have in ~/.xinitrc

export GDK_USE_XFT=1
export XMODIFIERS=@im=SCIM
export GTK_IM_MODULE=scim
export QT_IM_MODULE=scim
scim -d

I do not see a scim-orig file offered by my distribution (Raspbian 10 Buster). The IM module is Anthy. I keep it on all the time and switch between its raw and Japanese. Here is my config file:

/DefaultIMEngineFactory/si_LK = IMEngine-M17N-si-wijesekera
/DefaultIMEngineFactory/ta_IN = IMEngine-M17N-ta-tamil99
/DefaultIMEngineFactory/zh_CN = 29ab338a-5a27-46b8-96cd-abbe86f17132
/DefaultIMEngineFactory/zh_HK = 5da9d4ff-ccdd-45af-b1a5-7bd4ac0aeb5f
/DefaultIMEngineFactory/zh_SG = 05235cfc-43ce-490c-b1b1-c5a2185276ae
/DefaultIMEngineFactory/zh_TW = fcff66b6-4d3e-4cf2-833c-01ef66ac6025
/FrontEnd/ChangeFactoryGlobally = false
/FrontEnd/IMOpenedByDefault = false
/FrontEnd/OnTheSpot = true
/FrontEnd/SharedInputMethod = true
/FrontEnd/Socket/ConfigReadOnly = false
/FrontEnd/Socket/MaxClients = 512
/FrontEnd/X11/BrokenWchar = true
/FrontEnd/X11/Dynamic = false
/FrontEnd/X11/OnTheSpot = true
/FrontEnd/X11/ServerName = SCIM
/Hotkeys/FrontEnd/NextFactory =
/Hotkeys/FrontEnd/NextFactory/zh_CN = Control+Alt+Down,Shift+Control+KeyRelease+Shift_L,Shift+Control+KeyRelease+Shift_R
/Hotkeys/FrontEnd/NextFactory/zh_HK = Control+Alt+Down,Shift+Control+KeyRelease+Shift_L,Shift+Control+KeyRelease+Shift_R
/Hotkeys/FrontEnd/NextFactory/zh_SG = Control+Alt+Down,Shift+Control+KeyRelease+Shift_L,Shift+Control+KeyRelease+Shift_R
/Hotkeys/FrontEnd/NextFactory/zh_TW = Control+Alt+Down,Shift+Control+KeyRelease+Shift_L,Shift+Control+KeyRelease+Shift_R
/Hotkeys/FrontEnd/PreviousFactory =
/Hotkeys/FrontEnd/PreviousFactory/zh_CN = Control+Alt+Up,Shift+Control+KeyRelease+Control_L,Shift+Control+KeyRelease+Control_R
/Hotkeys/FrontEnd/PreviousFactory/zh_HK = Control+Alt+Up,Shift+Control+KeyRelease+Control_L,Shift+Control+KeyRelease+Control_R
/Hotkeys/FrontEnd/PreviousFactory/zh_SG = Control+Alt+Up,Shift+Control+KeyRelease+Control_L,Shift+Control+KeyRelease+Control_R
/Hotkeys/FrontEnd/PreviousFactory/zh_TW = Control+Alt+Up,Shift+Control+KeyRelease+Control_L,Shift+Control+KeyRelease+Control_R
/Hotkeys/FrontEnd/ShowFactoryMenu =
/Hotkeys/FrontEnd/Trigger = Control+space,Zenkaku_Hankaku,Hangul
/Hotkeys/FrontEnd/Trigger/ja_JP = Zenkaku_Hankaku,Alt+grave,Control+space
/Hotkeys/FrontEnd/Trigger/ko_KR = Alt+Alt_L+KeyRelease,Shift+space,Control+space,Hangul
/Hotkeys/FrontEnd/ValidKeyMask = Shift+Control+Alt+Meta+Super+Hyper+CapsLock
/IMEngine/Anthy/CandWinPageSize = 10
/IMEngine/Anthy/KanaLayoutFile = /home/grady/.scim/Anthy/config.sty
/IMEngine/Anthy/KeyTheme = User defined
/IMEngine/Anthy/KeyThemeFile =
/IMEngine/Anthy/NICOLALayoutFile =
/IMEngine/Anthy/OnOffKey = Zenkaku_Hankaku,Control+space
/IMEngine/Anthy/PredictOnInput = false
/IMEngine/Anthy/RomajiThemeFile =
/IMEngine/Anthy/ShowCandidatesLabel = false
/IMEngine/Anthy/TypingMethod = Kana
/IMEngine/RawCode/Locales = default
/Panel/Gtk/Color/ActiveBackground = light sky blue
/Panel/Gtk/Color/ActiveText = black
/Panel/Gtk/Color/NormalBackground = #F7F3F7
/Panel/Gtk/Color/NormalText = black
/Panel/Gtk/DefaultSticked = false
/Panel/Gtk/Font = default
/Panel/Gtk/LookupTableEmbedded = true
/Panel/Gtk/LookupTableVertical = true
/Panel/Gtk/ShowStatusBox = false
/Panel/Gtk/ShowTrayIcon = true
/Panel/Gtk/ToolBar/AlwaysHidden = true
/Panel/Gtk/ToolBar/AlwaysShow = false
/Panel/Gtk/ToolBar/AutoSnap = true
/Panel/Gtk/ToolBar/HideTimeout = 2
/Panel/Gtk/ToolBar/POS_X = -1
/Panel/Gtk/ToolBar/POS_Y = -1
/Panel/Gtk/ToolBar/ShowFactoryIcon = true
/Panel/Gtk/ToolBar/ShowFactoryName = true
/Panel/Gtk/ToolBar/ShowHelpIcon = true
/Panel/Gtk/ToolBar/ShowMenuIcon = true
/Panel/Gtk/ToolBar/ShowPropertyLabel = true
/Panel/Gtk/ToolBar/ShowSetupIcon = true
/Panel/Gtk/ToolBar/ShowStickIcon = false
/UpdateTimeStamp = 1564144828:725380

This is a fresh install, and I have only been using scim for about a day. I have already noticed a correlation between the non-responsive state and ctrl+key combinations... Then again, this could be my imagination. I use a lot of ctrl+key stuff on the terminal.

@NoSuck
Copy link
Author

NoSuck commented Jul 28, 2019

Switching focus to another window, pressing a key or two, and switching back to the original window usually solves the issue.

I have since discovered that maximizing and unmaximizing the problem window is an even more effective method.

@tzhuan
Copy link
Member

tzhuan commented Jul 29, 2019

scim provides two gtk immodules, scim-orig (written in c++) and scim (written in pure c). For some reason the debian official scim package provides scim only.

By the way I have tried both scim and scim-orig but I still cannot reproduce the issue. I'll find some time to setup a new profile with Anthy and your config later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants