X11: Use bottom-right corner of IME cursor area as caret position
XIM servers currently do not support preedit area reporting from clients and there may be no standard way to report it. Fcitx and iBus both place the candidate window descending descending from the caret, with the reported X font; but since winit does not report a font, the height of the line is assumed 0, so when we report the top left corner of the cursor area they will tend to obscure it. Taking this into account, the best default option is to report the bottom right corner of the cursor area, because it will tend not to obscure the preedit area when using `Window::set_ime_cursor_area` in the way suggested by documentation.
This commit is contained in:
parent
9f8ac8feb5
commit
f781e13166
3 changed files with 14 additions and 5 deletions
|
|
@ -1005,7 +1005,8 @@ pub trait Window: AsAny + Send + Sync {
|
|||
///
|
||||
/// ## Platform-specific
|
||||
///
|
||||
/// - **X11:** - area is not supported, only position.
|
||||
/// - **X11:** Area is not supported, only position. The bottom-right corner of the provided
|
||||
/// area is reported as the position.
|
||||
/// - **iOS / Android / Web / Orbital:** Unsupported.
|
||||
///
|
||||
/// [chinese]: https://support.apple.com/guide/chinese-input-method/use-the-candidate-window-cim12992/104/mac/12.0
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue