Skip to content

Instantly share code, notes, and snippets.

@liz3
Created October 25, 2024 00:29
Show Gist options
  • Save liz3/f57fe8c067e477b274476daf39f0da0e to your computer and use it in GitHub Desktop.
Save liz3/f57fe8c067e477b274476daf39f0da0e to your computer and use it in GitHub Desktop.
Electron fcitx5 long press bug

Before reproducing

start fcitx 5(fcitx5 -d) and the config tool(fcitx5-configtool), from there click the Preferences button for the active language: image

then set the Choose key modifier to None and enable Type special characters with long press: image

You might need to add this flag to ~/.config/electron-flags.conf:

--ozone-platform-hint=auto

Reproduce the bug

<!DOCTYPE html>
<html>
<body>
<input type="text" />
</body>
</html>
import {BrowserWindow, app } from "electron"
const createWindow = () => {
const win = new BrowserWindow({
width: 800,
height: 600
})
win.loadFile('index.html')
}
app.whenReady().then(() => {
app.commandLine.appendSwitch("--enable-wayland-ime", "");
createWindow();
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment