HMCL icon indicating copy to clipboard operation
HMCL copied to clipboard

[Bug] Linux上无法使用输入法在HMCL

Open xuan-rs opened this issue 1 month ago • 4 comments

问题描述 | Bug Description

  • 我的HMCL 版本 - 3.16.4
  • 输入法 Fcitx5

1.其他地方都能用快捷键调输入法,但在HMCL里失效了 视频 2.问题从我刚开始用Linux玩HMCL的时候就有了,Windows上没任何问题

启动器崩溃报告 / 启动器日志文件 | Launcher Crash Report / Launcher Log File

我打开hmcl然后再在下载版本里面尝试调输入法后的log

[20:14:40] [@.util.SelfDependencyPatcher.patch/INFO] Missing JavaFX dependencies, attempting to patch in missing classes
[20:14:41] [@.util.SelfDependencyPatcher.fetchDependencies/INFO] Downloading https://mirrors.cloud.tencent.com/nexus/repository/maven-public/org/openjfx/javafx-base/21.0.8/javafx-base-21.0.8-linux.jar
[20:14:43] [@.util.SelfDependencyPatcher.fetchDependencies/INFO] Downloading https://mirrors.cloud.tencent.com/nexus/repository/maven-public/org/openjfx/javafx-graphics/21.0.8/javafx-graphics-21.0.8-linux.jar
[20:14:44] [@.util.SelfDependencyPatcher.fetchDependencies/INFO] Downloading https://mirrors.cloud.tencent.com/nexus/repository/maven-public/org/openjfx/javafx-controls/21.0.8/javafx-controls-21.0.8-linux.jar
[20:14:49] [@.util.SelfDependencyPatcher.loadFromCache/INFO]  - Loading dependencies...
[20:14:50] [@.util.SelfDependencyPatcher.patch/INFO]  - Done!
[20:14:50] [@.Launcher.main/INFO] *** HMCL 3.16.4 ***
[20:14:50] [@.Launcher.main/INFO] Operating System: Arch Linux (Linux 7.2.11-zen1-1-zen)
[20:14:50] [@.Launcher.main/INFO] System Architecture: x86-64
[20:14:50] [@.Launcher.main/INFO] Native Encoding: UTF-8
[20:14:50] [@.Launcher.main/INFO] JNU Encoding: UTF-8
[20:14:50] [@.Launcher.main/INFO] Java Architecture: x86-64
[20:14:50] [@.Launcher.main/INFO] Java Version: 17.0.20.1, Arch Linux
[20:14:50] [@.Launcher.main/INFO] Java VM Version: OpenJDK 64-Bit Server VM (mixed mode, sharing), Arch Linux
[20:14:50] [@.Launcher.main/INFO] Java Home: /usr/lib/jvm/java-17-openjdk
[20:14:50] [@.Launcher.main/INFO] Current Directory: /home/xuan-rs/Videos/Recordings
[20:14:50] [@.Launcher.main/INFO] HMCL User Home: /home/xuan-rs/.local/share/hmcl
[20:14:50] [@.Launcher.main/INFO] HMCL Local Home: /home/xuan-rs/Videos/Recordings/.hmcl
[20:14:50] [@.Launcher.main/INFO] HMCL Jar Path: /usr/share/java/hmcl-bin/hmcl-bin.jar
[20:14:50] [@.Launcher.main/INFO] HMCL Log File: /home/xuan-rs/Videos/Recordings/.hmcl/logs/2026-10-22T20-14-39.log
[20:14:50] [@.Launcher.main/INFO] JVM Max Memory: 2962 MiB
[20:14:50] [@.Launcher.main/INFO] Metaspace: 18.51 MiB
[20:14:50] [@.Launcher.main/INFO] Native Backend: None
[20:14:50] [@.Launcher.main/INFO] XDG Session Type: wayland
[20:14:50] [@.Launcher.main/INFO] XDG Current Desktop: Hyprland
[20:14:50] [@.Launcher.main/INFO] Zlib Compatible: true
[20:14:51] [@.util.platform.SystemInfo.initialize/INFO] System Info:
 - CPU: Intel Core i3-4170 (2 Cores / 4 Threads)
 - GPU: Intel 4th Generation Core Processor Family Integrated Graphics Controller [Discrete]
 - Memory: 4.88 GiB / 11.56 GiB (42%)
[20:14:51] [@.Launcher.start/INFO] JavaFX Version: 21.0.8+2
[20:14:52] [@.Launcher.start/INFO] Prism Pipeline: com.sun.prism.es2.ES2Pipeline
[20:14:52] [@.Launcher.start/INFO] Dark Mode: false
[20:14:52] [@.Launcher.start/INFO] Reduced Motion: false
[20:14:52] [@.Launcher.start/INFO] Screens:
 - Screen 1: 1920x1080 101dpi in 22" (0, 0, 1920, 1080)
[20:14:52] [@.util.FileSaver.saveSync/INFO] Saving file /home/xuan-rs/Videos/Recordings/.hmcl/config/game-settings.json
[20:14:52] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$19/TRACE] Executing task: org.jackhuang.hmcl.game.GameRepository.refreshVersionsAsync(GameRepository.java:91)
[20:14:53] [@.event.EventBus.fireEvent/INFO] RefreshingVersionsEvent [source=HMCLGameRepository [versions=null, baseDirectory=.minecraft]] gets fired
[20:14:53] [@.util.FileSaver.saveSync/INFO] Saving file /home/xuan-rs/Videos/Recordings/.hmcl/config/launcher-settings.json
[20:14:53] [@.event.EventBus.fireEvent/INFO] RefreshedVersionsEvent [source=HMCLGameRepository [versions=[], baseDirectory=.minecraft]] gets fired
[20:14:53] [@.util.FileSaver.saveSync/INFO] Saving file /home/xuan-rs/Videos/Recordings/.hmcl/config/game-directories.json
[20:14:53] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$29/TRACE] Task finished: org.jackhuang.hmcl.game.GameRepository.refreshVersionsAsync(GameRepository.java:91)
[20:14:53] [@.auth.authlibinjector.AuthlibInjectorServer.refreshMetadata/INFO] authlib-injector server metadata refreshed: https://littleskin.cn/api/yggdrasil/
[20:14:53] [@.ui.Controllers.initialize/INFO] Start initializing application
[20:14:53] [@.ui.Controllers.initialize/INFO] April Fools: false
[20:14:53] [@.util.FileSaver.saveSync/INFO] Saving file /home/xuan-rs/Videos/Recordings/.hmcl/cache/authlib-injector-server-metadata.json
[20:14:54] [@.theme.Themes.getDefaultBrightness/INFO] Detecting system theme brightness
[20:14:54] [@.theme.Themes.getDefaultBrightness/INFO] Detected system theme brightness: DARK
[20:14:55] [@.setting.FontManager.findByFcMatch/INFO] Load font file: /home/xuan-rs/.local/share/fonts/MapleNarrow/MapleMono-NF-CN-Regular.ttf
[20:14:55] [@.setting.FontManager.<clinit>/INFO] Font: Maple Mono NF CN Narrow
[20:14:55] [@.java.JavaManager.searchPotentialJavaExecutables/TRACE] Finished Java lookup, found 1
 - JRE 17.0.20.1 (x86-64, Arch Linux): /usr/lib/jvm/java-17-openjdk/bin/java
[20:14:56] [@.auth.microsoft.MicrosoftService.lambda$new$0/INFO] Fetching properties of b25d6e97-5a85-42aa-b72c-3023bfc67ea1
[20:14:59] [@.upgrade.IntegrityChecker.isSelfVerified/INFO] Successfully verified current JAR
[20:15:09] [@.upgrade.UpdateChecker.lambda$requestCheckUpdate$2/WARNING] Failed to check for update
java.net.SocketTimeoutException: Connect timed out
	at java.base/sun.nio.ch.NioSocketImpl.timedFinishConnect(Unknown Source)
	at java.base/sun.nio.ch.NioSocketImpl.connect(Unknown Source)
	at java.base/java.net.SocksSocketImpl.connect(Unknown Source)
	at java.base/java.net.Socket.connect(Unknown Source)
	at java.base/sun.security.ssl.SSLSocketImpl.connect(Unknown Source)
	at java.base/sun.net.NetworkClient.doConnect(Unknown Source)
	at java.base/sun.net.www.http.HttpClient.openServer(Unknown Source)
	at java.base/sun.net.www.http.HttpClient.openServer(Unknown Source)
	at java.base/sun.net.www.protocol.https.HttpsClient.<init>(Unknown Source)
	at java.base/sun.net.www.protocol.https.HttpsClient.New(Unknown Source)
	at java.base/sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(Unknown Source)
	at java.base/sun.net.www.protocol.http.HttpURLConnection.plainConnect0(Unknown Source)
	at java.base/sun.net.www.protocol.http.HttpURLConnection.plainConnect(Unknown Source)
	at java.base/sun.net.www.protocol.http.HttpURLConnection.connect(Unknown Source)
	at java.base/sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(Unknown Source)
	at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source)
	at java.base/sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)
	at java.base/java.net.HttpURLConnection.getResponseCode(Unknown Source)
	at java.base/sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(Unknown Source)
	at org.jackhuang.hmcl.util.io.NetworkUtils.resolveConnection(NetworkUtils.java:328)
	at org.jackhuang.hmcl.util.io.NetworkUtils.doGet(NetworkUtils.java:358)
	at org.jackhuang.hmcl.util.io.NetworkUtils.doGet(NetworkUtils.java:352)
	at org.jackhuang.hmcl.upgrade.RemoteVersion.fetch(RemoteVersion.java:36)
	at org.jackhuang.hmcl.upgrade.UpdateChecker.checkUpdate(UpdateChecker.java:96)
	at org.jackhuang.hmcl.upgrade.UpdateChecker.lambda$requestCheckUpdate$2(UpdateChecker.java:113)
	at java.base/java.lang.Thread.run(Unknown Source)
[20:15:41] [@.ui.Controllers.prepareDownloadPage/INFO] Prepare the download page
[20:15:41] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$19/TRACE] Executing task: org.jackhuang.hmcl.ui.download.VersionsPage.refresh(VersionsPage.java:116)
[20:15:41] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$19/TRACE] Executing task: org.jackhuang.hmcl.task.Task$UniCompose$$Lambda$1115/0x00007fd4d4558a40@2fefbe15
[20:15:41] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$19/TRACE] Executing task: org.jackhuang.hmcl.task.Task$UniCompose$$Lambda$1115/0x00007fd4d4558a40@3fafca76
[20:15:41] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$19/TRACE] Executing task: MultipleSourceVersionList.refreshAsync(task=org.jackhuang.hmcl.download.game.GameVersionList.refreshAsync(GameVersionList.java:57), index=0, all=2)
[20:15:41] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$19/TRACE] Executing task: org.jackhuang.hmcl.download.game.GameVersionList.refreshAsync(GameVersionList.java:57)
[20:15:41] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$19/TRACE] Executing task: org.jackhuang.hmcl.download.game.GameVersionList.refreshAsync(GameVersionList.java:56)
[20:15:41] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$19/TRACE] Executing task: https://piston-meta.mojang.com/mc/game/version_manifest.json
[20:15:42] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$29/TRACE] Task finished: https://piston-meta.mojang.com/mc/game/version_manifest.json
[20:15:42] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$29/TRACE] Task finished: org.jackhuang.hmcl.download.game.GameVersionList.refreshAsync(GameVersionList.java:56)
[20:15:43] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$29/TRACE] Task finished: org.jackhuang.hmcl.download.game.GameVersionList.refreshAsync(GameVersionList.java:57)
[20:15:43] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$29/TRACE] Task finished: MultipleSourceVersionList.refreshAsync(task=org.jackhuang.hmcl.download.game.GameVersionList.refreshAsync(GameVersionList.java:57), index=0, all=2)
[20:15:43] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$29/TRACE] Task finished: org.jackhuang.hmcl.task.Task$UniCompose$$Lambda$1115/0x00007fd4d4558a40@3fafca76
[20:15:43] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$19/TRACE] Executing task: org.jackhuang.hmcl.util.Lang.lambda$wrap$2(Lang.java:303)
[20:15:43] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$29/TRACE] Task finished: org.jackhuang.hmcl.util.Lang.lambda$wrap$2(Lang.java:303)
[20:15:43] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$29/TRACE] Task finished: org.jackhuang.hmcl.task.Task$UniCompose$$Lambda$1115/0x00007fd4d4558a40@2fefbe15
[20:15:43] [@.task.AsyncTaskExecutor.lambda$executeNormalTask$29/TRACE] Task finished: org.jackhuang.hmcl.ui.download.VersionsPage.refresh(VersionsPage.java:116)
[20:15:45] [@.ui.construct.Navigator.navigate/INFO] Navigate to DownloadPage@7e6b8144[styleClass=root gray-background]
[20:15:55] [@.Launcher.stopApplication/INFO] Stopping application.
	at java.base/java.lang.Thread.getStackTrace(Unknown Source)
	at org.jackhuang.hmcl.Launcher.stopApplication(Launcher.java:386)
	at org.jackhuang.hmcl.ui.decorator.Decorator.close(Decorator.java:290)
	at org.jackhuang.hmcl.ui.decorator.DecoratorSkin.lambda$new$11(DecoratorSkin.java:275)
	at [email protected]/com.sun.javafx.event.CompositeEventHandler.dispatchBubblingEvent(CompositeEventHandler.java:86)
	at [email protected]/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:232)
	at [email protected]/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:189)
	at [email protected]/com.sun.javafx.event.CompositeEventDispatcher.dispatchBubblingEvent(CompositeEventDispatcher.java:59)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:58)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.EventUtil.fireEventImpl(EventUtil.java:74)
	at [email protected]/com.sun.javafx.event.EventUtil.fireEvent(EventUtil.java:49)
	at [email protected]/javafx.event.Event.fireEvent(Event.java:198)
	at [email protected]/javafx.scene.Node.fireEvent(Node.java:8875)
	at [email protected]/javafx.scene.control.Button.fire(Button.java:203)
	at [email protected]/com.sun.javafx.scene.control.behavior.ButtonBehavior.mouseReleased(ButtonBehavior.java:207)
	at [email protected]/com.sun.javafx.scene.control.inputmap.InputMap.handle(InputMap.java:274)
	at [email protected]/com.sun.javafx.event.CompositeEventHandler$NormalEventHandlerRecord.handleBubblingEvent(CompositeEventHandler.java:247)
	at [email protected]/com.sun.javafx.event.CompositeEventHandler.dispatchBubblingEvent(CompositeEventHandler.java:80)
	at [email protected]/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:232)
	at [email protected]/com.sun.javafx.event.EventHandlerManager.dispatchBubblingEvent(EventHandlerManager.java:189)
	at [email protected]/com.sun.javafx.event.CompositeEventDispatcher.dispatchBubblingEvent(CompositeEventDispatcher.java:59)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:58)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.BasicEventDispatcher.dispatchEvent(BasicEventDispatcher.java:56)
	at [email protected]/com.sun.javafx.event.EventDispatchChainImpl.dispatchEvent(EventDispatchChainImpl.java:114)
	at [email protected]/com.sun.javafx.event.EventUtil.fireEventImpl(EventUtil.java:74)
	at [email protected]/com.sun.javafx.event.EventUtil.fireEvent(EventUtil.java:54)
	at [email protected]/javafx.event.Event.fireEvent(Event.java:198)
	at [email protected]/javafx.scene.Scene$MouseHandler.process(Scene.java:3984)
	at [email protected]/javafx.scene.Scene.processMouseEvent(Scene.java:1890)
	at [email protected]/javafx.scene.Scene$ScenePeerListener.mouseEvent(Scene.java:2708)
	at [email protected]/com.sun.javafx.tk.quantum.GlassViewEventHandler$MouseEventNotification.run(GlassViewEventHandler.java:411)
	at [email protected]/com.sun.javafx.tk.quantum.GlassViewEventHandler$MouseEventNotification.run(GlassViewEventHandler.java:301)
	at java.base/java.security.AccessController.doPrivileged(Unknown Source)
	at [email protected]/com.sun.javafx.tk.quantum.GlassViewEventHandler.lambda$handleMouseEvent$2(GlassViewEventHandler.java:450)
	at [email protected]/com.sun.javafx.tk.quantum.QuantumToolkit.runWithoutRenderLock(QuantumToolkit.java:424)
	at [email protected]/com.sun.javafx.tk.quantum.GlassViewEventHandler.handleMouseEvent(GlassViewEventHandler.java:449)
	at [email protected]/com.sun.glass.ui.View.handleMouseEvent(View.java:551)
	at [email protected]/com.sun.glass.ui.View.notifyMouse(View.java:937)
	at [email protected]/com.sun.glass.ui.gtk.GtkApplication._runLoop(Native Method)
	at [email protected]/com.sun.glass.ui.gtk.GtkApplication.lambda$runLoop$10(GtkApplication.java:263)
	at java.base/java.lang.Thread.run(Unknown Source)

[20:15:55] [@.task.Schedulers.shutdown/INFO] Shutting down executor services.
[20:15:55] [@.util.FileSaver.saveSync/INFO] Saving file /home/xuan-rs/Videos/Recordings/.hmcl/state/launcher-state.json

xuan-rs avatar Oct 22 '26 12:10 xuan-rs

尝试使用 java 25 打开启动器?

zkitefly avatar Oct 22 '26 13:10 zkitefly

这是低版本 JavaFX 的问题,请使用 Java 22+ 启动 HMCL。

Glavo avatar Oct 22 '26 13:10 Glavo

3. 这 这 迫是低才 本问题 的问题题请使核 Java 22+ 吉 森举

我觉得有必要在hmcl里面加个提示说明java22-版本在Linux调不了输入法

xuan-rs avatar Oct 22 '26 14:10 xuan-rs

我测试了一下,发现在 java版本大于22时,需要环境变量

XMODIFIERS=@im=fcitx

在wayland下,不应该直接设置全局环境变量。因此建议在终端这样启动

env XMODIFIERS=@im=fcitx {启动命令}

例如

env XMODIFIERS=@im=fcitx hmcl

建议使用java25

ZhX589 avatar Oct 23 '26 15:10 ZhX589