Daniel Eklöf
3e25faeae7
Merge branch 'remove-deprecated-things'
2020-12-09 20:53:05 +01:00
Daniel Eklöf
e42fd0f87f
changelog: don’t repeat ‘IME’
2020-12-08 20:31:48 +01:00
Daniel Eklöf
3d14d79c01
changelog: add missing space in escape sequence
2020-12-08 20:31:22 +01:00
Daniel Eklöf
251026800f
changelog: consistently use ‘CSI ? X h/l’ instead of \E[?Xh/l
2020-12-08 20:29:44 +01:00
Daniel Eklöf
0263a152d4
Merge branch 'input-method-editor'
...
Closes #134
2020-12-08 20:06:22 +01:00
Daniel Eklöf
5020366bf5
config: remove support for scrollback-up and scrollback-down
2020-12-08 19:58:02 +01:00
Daniel Eklöf
386796cec6
config: remove support for default.geometry
2020-12-08 19:53:55 +01:00
Daniel Eklöf
6ec63eae00
config: remove support for default.scrollback
2020-12-08 19:52:28 +01:00
Daniel Eklöf
7b16802972
config: remove support for loading configuration from footrc
2020-12-08 19:52:22 +01:00
Daniel Eklöf
e7c56b0b29
completions: zsh: foot: fix default path of foot.ini
2020-12-08 19:49:14 +01:00
Daniel Eklöf
6494ba24c9
install: simplify sentence
2020-12-08 19:19:09 +01:00
Daniel Eklöf
ae01caee8c
render: ime: ensure cursor is visible
2020-12-08 19:17:46 +01:00
Daniel Eklöf
2ac520b958
changelog: DECSET 737769 - enable/disable IME
2020-12-07 20:44:15 +01:00
Daniel Eklöf
b270f221d0
render: search: render IME pre-edit text correctly, hopefully
2020-12-07 20:44:15 +01:00
Daniel Eklöf
a6ed9a9773
ime: don’t underline characters inside the cursor-box
2020-12-07 20:44:15 +01:00
Daniel Eklöf
fc2bcf9bc0
search: reset IME state when entering/exiting search mode
2020-12-07 20:44:15 +01:00
Daniel Eklöf
bcfc468fd0
render: ime: adjust cursor cell index when adjusting glyph offset
2020-12-07 20:44:15 +01:00
Daniel Eklöf
d46dcd8ef5
render: ime: wip: pre-edit
2020-12-07 20:44:14 +01:00
Daniel Eklöf
fd42a0bc23
ime: call render_refresh_search() instead of render_refresh()
...
When scrollback search is active
2020-12-07 20:44:14 +01:00
Daniel Eklöf
194fbff883
ime: store wchar version of pre-edit string in terminal struct
2020-12-07 20:44:14 +01:00
Daniel Eklöf
7c420004fb
render: search: don’t access term->search.buf[] directly
2020-12-07 20:44:14 +01:00
Daniel Eklöf
1ea3674029
render: codespell: cound -> count
2020-12-07 20:44:13 +01:00
Daniel Eklöf
b4a0f5b13b
render: search: glyph_offset is in *cells*, cursor position in *characters*
...
When calculating the offset into the search string, from where to
start rendering, take into account that the cursor position is
in *characters*, and the glyph-offset is in *cells*.
2020-12-07 20:44:13 +01:00
Daniel Eklöf
5ffa65a2e3
render: search: wcsnlen() -> wcswidth()
2020-12-07 20:44:13 +01:00
Daniel Eklöf
a552610fdb
render: search: handle multi-column characters
2020-12-07 20:44:13 +01:00
Daniel Eklöf
dca35215d0
render: search: render colorized glyphs (emojis) correctly
2020-12-07 20:44:13 +01:00
Daniel Eklöf
d87160e5f6
ime: commit text using search_add_chars() while in scrollback search mode
2020-12-07 20:44:12 +01:00
Daniel Eklöf
f51ce34753
search: new function: search_add_chars()
...
This function inserts a string into the search buffer, at the current
insertion point (i.e. where the cursor is).
2020-12-07 20:44:12 +01:00
Daniel Eklöf
7eea6f94ed
ime: don’t commit to the slave while scrollback searching
2020-12-07 20:44:12 +01:00
Daniel Eklöf
9ce0edc8bb
render: ime: don’t render pre-edit string in grid while searching
...
While doing a scrollback search, the pre-edit string should be
rendered in the search box, not in the grid.
Note that we don’t yet support IME in scrollback search mode. This
patch simply prevents the pre-edit text being rendered in the grid,
in the “background”, while searching.
2020-12-07 20:44:12 +01:00
Daniel Eklöf
fe6cf547f1
install: highlight option default value in options list
2020-12-07 20:44:12 +01:00
Daniel Eklöf
ab699338b3
install: highlight option name in options list
2020-12-07 20:44:12 +01:00
Daniel Eklöf
725d17d21d
changelog: ime: add link to INSTALL.md
2020-12-07 20:44:12 +01:00
Daniel Eklöf
559c87b84a
install: add ‘options’ section, describing compile-time options
2020-12-07 20:44:12 +01:00
Daniel Eklöf
3df4ec1c8e
changelog: IME support
2020-12-07 20:44:12 +01:00
Daniel Eklöf
0536bc41f4
csi: add DECSET 737769 - enables/disables IME input
...
73 77 69 = I M E
2020-12-07 20:44:12 +01:00
Daniel Eklöf
e3b5a98ade
codespell: currenly -> currently, second instance
2020-12-07 20:44:11 +01:00
Daniel Eklöf
0fc2a1188c
codespell: currenly -> currently
2020-12-07 20:44:11 +01:00
Daniel Eklöf
77bc7c8b2c
features: include compile-time enable/disable state of features when printing version
2020-12-07 20:44:11 +01:00
Daniel Eklöf
2078e1675d
render: ime: draw a ‘bar’ cursor when the pre-edit cursor’s begin == end
2020-12-07 20:44:11 +01:00
Daniel Eklöf
85cdc66ff2
shm: fix badly indented function return type
2020-12-07 20:44:11 +01:00
Daniel Eklöf
b59d695b2b
ime: add functions to enable/disable IME, simplify code that enables IME
...
We may want to be able to enable/disable IME run-time, even though we
have received an ‘enter’ IME event.
This enables us to do that.
Also add functions to enable/disable IME on a per-terminal instance
basis.
A terminal may have multiple seats focusing it, and enabling/disabling
IME in a terminal instance enables/disables IME on all those seats.
Finally, the code to enable IME is simplified; the *only* surface that
can ever receive ‘enter’ IME events is the main grid. All other
surfaces are sub-surfaces, without their own keyboard focus.
2020-12-07 20:44:11 +01:00
Daniel Eklöf
5c17b7f8e7
ime: expand cursor cell-end across multi-cell characters
...
This fixes an issue where the cursor ended in the middle of e.g double
width characters.
2020-12-07 20:44:11 +01:00
Daniel Eklöf
001c82fa54
ime: don’t adjust cursor’s cell-end if it’s equal to the cell-begin
2020-12-07 20:44:11 +01:00
Daniel Eklöf
552b9884b9
ime: set cursor end correctly when it ends *after* the pre-edit string
2020-12-07 20:44:11 +01:00
Daniel Eklöf
cc76f91c43
ime: use correct index when calculating number of *cells* to advance
2020-12-07 20:44:11 +01:00
Daniel Eklöf
83d3ae10ae
render: ime: don’t render cursor if cursor begin == end
2020-12-07 20:44:10 +01:00
Daniel Eklöf
e9f99df2ab
render: ime: calculate on-screen cursor position ourselves
...
The position calculated by render_grid() may be -1,-1 if the cursor is
currently hidden.
This fixes a crash when trying to input IME while the cursor is
hidden.
2020-12-07 20:44:10 +01:00
Daniel Eklöf
98bd798dae
ime: calculate wchar widths once
2020-12-07 20:44:10 +01:00
Daniel Eklöf
4d90b200f1
render: ignore IME preedit state when deciding which cursor style to render
2020-12-07 20:44:10 +01:00