<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mirrors/foot.git/ime.c, branch spawn-terminal-cmdline-arguments</title>
<subtitle>A fast, lightweight and minimalistic Wayland terminal emulator</subtitle>
<id>https://git.0x0f.dev/mirrors/foot.git/atom?h=spawn-terminal-cmdline-arguments</id>
<link rel='self' href='https://git.0x0f.dev/mirrors/foot.git/atom?h=spawn-terminal-cmdline-arguments'/>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/'/>
<updated>2026-11-12T08:54:23Z</updated>
<entry>
<title>ime: reset view &amp; cancel selection on text commit</title>
<updated>2026-11-12T08:54:23Z</updated>
<author>
<name>CismonX</name>
<email>admin@cismon.net</email>
</author>
<published>2026-10-27T04:56:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=8768826c887c27721fddbf4670e27215b201bce2'/>
<id>urn:sha1:8768826c887c27721fddbf4670e27215b201bce2</id>
<content type='text'>
IMEs may commit text directly without updating preedit text
(seen on Squeekboard), thus 5c8d520807 is not enough.
</content>
</entry>
<entry>
<title>ime: reset view and cancel selection on input</title>
<updated>2026-10-25T10:48:42Z</updated>
<author>
<name>CismonX</name>
<email>admin@cismon.net</email>
</author>
<published>2026-10-05T07:52:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=5c8d52080750b81752595ac8f00fbacece17978b'/>
<id>urn:sha1:5c8d52080750b81752595ac8f00fbacece17978b</id>
<content type='text'>
The text input area should be visible when using input methods.

This also keeps the behavior consistent with the wl_keyboard.key
event handler.
</content>
</entry>
<entry>
<title>ime: ignore enter events with a NULL surface</title>
<updated>2026-09-18T05:51:33Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2026-09-18T05:50:39Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=f3226bc5eba53ce4b0306546e99f5928198526c3'/>
<id>urn:sha1:f3226bc5eba53ce4b0306546e99f5928198526c3</id>
<content type='text'>
Closes #2467
</content>
</entry>
<entry>
<title>ime: refresh search matches after IME commit</title>
<updated>2026-07-21T09:11:28Z</updated>
<author>
<name>0WD0</name>
<email>wd.1105848296@gmail.com</email>
</author>
<published>2026-06-18T13:50:59Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=027ef55842c36b1b6182ebe334a92e402e39e54e'/>
<id>urn:sha1:027ef55842c36b1b6182ebe334a92e402e39e54e</id>
<content type='text'>
The IME commit handler appended text to the search buffer and refreshed
the search box, but never called search_find_next(). CJK input into
scrollback search therefore showed no match until another key press
re-triggered the regular search input path. Call search_find_next() in
the commit branch, and apply the same fix to unicode-mode.c. To allow
this, search_find_next() is no longer static.
</content>
</entry>
<entry>
<title>ime: fix initial cursor rectangle being reported as 0,0,0,0</title>
<updated>2025-03-17T07:43:12Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2025-03-17T07:43:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=cd4ee8ae49f7c3ba1441917decd2e4ebb804e4ab'/>
<id>urn:sha1:cd4ee8ae49f7c3ba1441917decd2e4ebb804e4ab</id>
<content type='text'>
Closes #1994
</content>
</entry>
<entry>
<title>ime: codespell: surroundin -&gt; surrounding</title>
<updated>2024-06-08T06:49:33Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2024-06-08T06:49:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=ba424e84947540f8bcc20e622a8a5e7947178b44'/>
<id>urn:sha1:ba424e84947540f8bcc20e622a8a5e7947178b44</id>
<content type='text'>
</content>
</entry>
<entry>
<title>ime: track IME focus independently from keyboard focus</title>
<updated>2022-06-15T17:25:33Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2022-06-15T16:41:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=96f23b4c6436d314ae4272f5f99c51b8e33556eb'/>
<id>urn:sha1:96f23b4c6436d314ae4272f5f99c51b8e33556eb</id>
<content type='text'>
Replace the seat-&gt;ime.focused boolean with a terminal instace pointer,
seat-&gt;ime_focus.

Set and reset this on ime::enter() and ime::leave() events, and use
this instead of seat-&gt;kbd_focus on all other IME events.

This fixes two issues:

a) buggy compositors that sometimes sends an IME enter event without
  first having sent a keyboard enter event.

b) seats may be IME capable while still lacking the keyboard
  capability. Such seats will *always* see IME enter events without a
  corresponding keyboard enter event.
</content>
</entry>
<entry>
<title>ime: ime_reset_pending_{preedit,commit} is not used outside ime.c</title>
<updated>2022-06-15T17:25:32Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2022-06-15T16:39:46Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=d852178540bbe98c0b88ecc627b0fcfa208d4b24'/>
<id>urn:sha1:d852178540bbe98c0b88ecc627b0fcfa208d4b24</id>
<content type='text'>
</content>
</entry>
<entry>
<title>fcft: adapt to API changes in fcft-3.x</title>
<updated>2022-02-05T16:00:54Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-08-21T12:50:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=e0227266cabc015c282774ac898e3f52dce943df'/>
<id>urn:sha1:e0227266cabc015c282774ac898e3f52dce943df</id>
<content type='text'>
Fcft no longer uses wchar_t, but plain uint32_t to represent
codepoints.

Since we do a fair amount of string operations in foot, it still makes
sense to use something that actually _is_ a string (or character),
rather than an array of uint32_t.

For this reason, we switch out all wchar_t usage in foot to
char32_t. We also verify, at compile-time, that char32_t used
UTF-32 (which is what fcft expects).

Unfortunately, there are no string functions for char32_t. To avoid
having to re-implement all wcs*() functions, we add a small wrapper
layer of c32*() functions.

These wrapper functions take char32_t arguments, but then simply call
the corresponding wcs*() function.

For this to work, wcs*() must _also_ be UTF-32 compatible. We can
check for the presence of the  __STDC_ISO_10646__ macro. If set,
wchar_t is at least 4 bytes and its internal representation is UTF-32.

FreeBSD does *not* define this macro, because its internal wchar_t
representation depends on the current locale. It _does_ use UTF-32
_if_ the current locale is UTF-8.

Since foot enforces UTF-8, we simply need to check if __FreeBSD__ is
defined.

Other fcft API changes:

* fcft_glyph_rasterize() -&gt; fcft_codepoint_rasterize()
* font.space_advance has been removed
* ‘tags’ have been removed from fcft_grapheme_rasterize()
* ‘fcft_log_init()’ removed
* ‘fcft_init()’ and ‘fcft_fini()’ must be explicitly called
</content>
</entry>
<entry>
<title>term: rename CELL_MULT_COL_SPACER -&gt; CELL_SPACER, and change its definition</title>
<updated>2021-05-14T12:41:02Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-05-14T12:41:02Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=d9e1aefb9173857f0632227de5ac368a505c69bf'/>
<id>urn:sha1:d9e1aefb9173857f0632227de5ac368a505c69bf</id>
<content type='text'>
Instead of using CELL_SPACER for *all* cells that previously used
CELL_MULT_COL_SPACER, include the remaining number of spacers
following, and including, itself. This is encoded by adding to the
CELL_SPACER value.

So, a double width character will now store the character itself in
the first cell (just like before), and CELL_SPACER+1 in the second
cell.

A three-cell character would store the character itself, then
CELL_SPACER+2, and finally CELL_SPACER+1.

In other words, the last spacer is always CELL_SPACER+1.

CELL_SPACER+0 is used when padding at the right margin. I.e. when
writing e.g. a double width character in the last column, we insert a
CELL_SPACER+0 pad character, and then write the double width character
in the first column on the next row.
</content>
</entry>
<entry>
<title>config: add ‘beam-thickness’ option</title>
<updated>2021-04-30T18:36:16Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-04-30T18:31:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=7ce767ab87ca915b2ac4023cc95dbda81fe87abd'/>
<id>urn:sha1:7ce767ab87ca915b2ac4023cc95dbda81fe87abd</id>
<content type='text'>
* Rename cursor.style value ‘bar’ to ‘beam’. ‘bar’ remains recognized,
  but should eventually be deprecated and then removed.
* Add ‘cursor.beam-thickness’ option, a pt-or-px value specifying the
  thickness of the beam cursor. Defaults to 1.5pt.
* Rename (and export) pt_or_px_as_pixels() to
  term_pt_or_px_as_pixels()
* Change term_pt_or_px_as_pixels() to round point values instead of
  truncating them.
</content>
</entry>
<entry>
<title>ime: set ‘have_warned = true’ to avoid warning over and over again</title>
<updated>2021-03-25T08:36:28Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-03-23T16:30:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=ebb92a4db6e7c3484b918c07092aa381103bada7'/>
<id>urn:sha1:ebb92a4db6e7c3484b918c07092aa381103bada7</id>
<content type='text'>
</content>
</entry>
<entry>
<title>ime: log warning on text-input::done() received without keyboard focus</title>
<updated>2021-03-25T08:36:07Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-03-23T13:02:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=adb5a344fe6b4a8789813f5a39cce7067a40034f'/>
<id>urn:sha1:adb5a344fe6b4a8789813f5a39cce7067a40034f</id>
<content type='text'>
</content>
</entry>
<entry>
<title>ime: don’t enable IME if we don’t have keyboard focus</title>
<updated>2021-03-25T08:36:07Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-03-23T13:01:46Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=ed3e70a9c78413e85b2cb1c379d26d592c13f827'/>
<id>urn:sha1:ed3e70a9c78413e85b2cb1c379d26d592c13f827</id>
<content type='text'>
Closes #411
</content>
</entry>
<entry>
<title>ime: don’t pass ‘term’ to ime_update_cursor_rect()</title>
<updated>2021-03-25T08:36:07Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-03-23T12:56:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=13b45db13e134c81ea72d1d70bf782ecd2445900'/>
<id>urn:sha1:13b45db13e134c81ea72d1d70bf782ecd2445900</id>
<content type='text'>
In all instances where we call ime_update_cursor_rect(), the ‘term’
argument is the same as seat-&gt;kbd_focus.

So, let ime_update_cursor_rect() use that directly instead.

Also make ime_send_cursor_rect() static (i.e. local to ime.c).
</content>
</entry>
<entry>
<title>ime: codespell: actaually -&gt; actually</title>
<updated>2021-03-25T08:36:07Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-03-23T12:37:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=1c355f7b7f61a85578144b967aa50aa9e8f2cf36'/>
<id>urn:sha1:1c355f7b7f61a85578144b967aa50aa9e8f2cf36</id>
<content type='text'>
</content>
</entry>
<entry>
<title>ime: move preedit state from terminal struct to the seat struct</title>
<updated>2021-03-25T08:36:07Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-03-23T12:03:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=e8ffb05bc7fb3b996752f345b77af4b757f69776'/>
<id>urn:sha1:e8ffb05bc7fb3b996752f345b77af4b757f69776</id>
<content type='text'>
This ensures different seat’s don’t step on each others IME pre-edit
state.

It also removes most dependencies on having a valid term pointer for
many IME operations.

We’re still not all the way, since we support disabling IME with a
private mode, which is per terminal, not seat.

Thus, we still require the seat to have keyboard focus on one of our
windows.

Closes #324. But note that *rendering* of multiple seat’s IME pre-edit
strings is still broken.
</content>
</entry>
<entry>
<title>ime: don’t commit IME changes when we don’t have IME focus</title>
<updated>2021-03-02T08:01:40Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-03-02T08:01:40Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=3f19ee4d921e69e90073d00846fa2a5a37d691af'/>
<id>urn:sha1:3f19ee4d921e69e90073d00846fa2a5a37d691af</id>
<content type='text'>
Fixes log spamming in Sway:

  00:54:07.780 [DEBUG] [wlr] [types/wlr_text_input_v3.c:181] Text input commit received without focus
  00:54:07.780 [INFO] [sway/input/text_input.c:127] Inactive text input tried to commit an update

Closes #384
</content>
</entry>
<entry>
<title>ime: enter(): remove assertion on surface kind being TERM_SURF_GRID</title>
<updated>2021-02-07T10:11:58Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2021-02-07T10:11:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=7cb49681e76ec84bc89a2e67943bec258f11e553'/>
<id>urn:sha1:7cb49681e76ec84bc89a2e67943bec258f11e553</id>
<content type='text'>
The main surface is the *only* IME capable surface we have. If the
compositor is sending an ime::enter event for another surface, it is a
compositor bug, not a foot bug.
</content>
</entry>
<entry>
<title>ime: Reset terminal's IME state on text_input.leave</title>
<updated>2021-01-30T19:24:12Z</updated>
<author>
<name>Tadeo Kondrak</name>
<email>me@tadeo.ca</email>
</author>
<published>2021-01-29T19:57:03Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=1515b7e44bde7c045eae12105d8fe6a168fb3152'/>
<id>urn:sha1:1515b7e44bde7c045eae12105d8fe6a168fb3152</id>
<content type='text'>
To reproduce issue:
- Launch an IME from inside foot
- Type in some preedit text
- Use Ctrl-C to close the IME
- IME text stays in terminal until focus is changed
</content>
</entry>
</feed>
