Skip to content

Improve IME (Input Method Editor) Support for bevy_egui #413

@elgar328

Description

@elgar328

Problem

bevy_egui currently lacks full IME support, which is a critical feature for non-English language input. While egui itself handles IME correctly, bevy_egui does not, preventing users from entering characters from languages like Korean, Japanese, Chinese, etc.

Why Existing Solutions Aren't Sufficient

There is a community-made plugin, bevy_egui_ime, which attempts to solve this issue. However, this plugin only works with specific egui text widgets (egui::text_edit_singleline and egui::text_edit_multiline). This approach is insufficient because:

It requires custom implementation for every text input field, which is not scalable.

It does not provide IME support for third-party egui widgets like egui_file (a file dialog), which are essential for many applications. This means that even with the plugin, users are still unable to type correctly in file dialogs or other complex widgets that aren't using the basic text editing functions.

Proposed Solution

The ideal solution would be to implement native IME support directly within the bevy_egui crate. This would involve:

Listening for IME-related events from the underlying winit window.

Correctly forwarding these events to egui's input handler.

Ensuring that egui receives the committed text correctly, rather than the raw, unconverted input.

By integrating this functionality at a foundational level, all widgets (including third-party ones) that rely on egui's text input would automatically gain proper IME support, making the crate more accessible and robust for a global user base.

Thank you for your consideration.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions