1
0
зеркало из https://github.com/glebtv/tui-textarea.git synced 2026-09-02 13:56:18 +03:00
Граф коммитов

188 Коммитов

Автор SHA1 Сообщение Дата
rhysd
49c90f0983 fix tests for termion support when using old version of termion 2024-08-08 23:55:25 +09:00
rhysd
3fb0a78a4c use the same version of termion as tui's dependency for tuirs-termion feature 2024-08-08 23:04:13 +09:00
rhysd
de736a584f make the first element of range is smaller than the second one (#81) 2024-08-08 20:55:35 +09:00
Linda_pp
b7a7e3dc34 Merge pull request #81 from achristmascarl/expose-selection-start
Expose `selection_start`
2024-08-08 09:25:35 +09:00
achristmascarl
75f51111e1 switch to selection range 2024-08-07 16:34:13 -04:00
rhysd
9650a1171a fix warnings and compile errors due to ratatui v0.28 update 2024-08-08 00:12:17 +09:00
achristmascarl
31012c6a01 fix tests 2024-08-06 12:45:18 -04:00
achristmascarl
23dfde75bd expose selection_start 2024-08-06 12:33:10 -04:00
rhysd
150ee9d360 add more tests for search feature 2024-08-05 00:02:11 +09:00
rhysd
3a9d1430d4 caveat on conversion from termion's key event into Input (#68) 2024-08-03 23:48:30 +09:00
rhysd
6f5ca389ff support 'Ctrl + Home' and 'Ctrl + End' for termion backend 2024-08-03 08:47:03 +09:00
rhysd
3937eca234 refactor converting termion key event into Input 2024-08-03 08:44:04 +09:00
rhysd
0e32eed5dd support shift/ctrl/alt + arrow keys combinations added at termion v4
fix #68

termion added the support at this commit:

3b52dc9bfb
2024-08-03 08:02:03 +09:00
rhysd
e5500dfa61 fix typos 2024-08-02 23:07:17 +09:00
rhysd
59ab95cc76 remove redundant clone() call with ratatui 2024-08-02 22:45:38 +09:00
rhysd
4e1adc66a9 smoothly slide the line number part into screen on scrolling left 2024-08-02 22:25:36 +09:00
rhysd
871577a20b shift cursor position by line number width on horizontal scroll 2024-08-02 21:23:04 +09:00
rhysd
c99108bf45 directly implement Widget for &TextArea (fix #78) 2024-08-02 16:31:21 +09:00
rhysd
506a065980 fix violating MSRV 2024-08-01 01:43:47 +09:00
rhysd
a3b6dd152d fix WordEnd does not consider going across multiple empty lines 2024-08-01 01:39:44 +09:00
Linda_pp
d9571ca50e Merge pull request #75 from achristmascarl/cursor-word-end
add `CursorMove` for next end of word
2024-07-31 22:51:12 +09:00
rhysd
00f0010393 show the cursor even if placeholder text is rendered by default
related to #73
2024-07-31 22:18:34 +09:00
achristmascarl
eae80347d9 adjust if else structure 2024-07-30 16:11:36 -04:00
achristmascarl
18f2af88c9 fix behavior at end of line 2024-07-30 15:40:22 -04:00
achristmascarl
311b185ff2 new WordEnd enum member for CursorMove 2024-07-30 15:08:29 -04:00
achristmascarl
08d13206cd add method for finding next word end 2024-07-30 15:07:51 -04:00
kyu08
a1ed9c68b3 add an option to show cursor and placeholder together 2024-07-26 21:38:44 +09:00
Linda_pp
fcd44bb7d9 Merge pull request #62 from cestef/main
Add serde feature to Scrolling, CursorMove and Input enums
2024-07-12 23:11:34 +09:00
rhysd
8c6bcb9a7c implement Display for YankText instead of ToString directly 2024-07-07 23:26:26 +09:00
kyu08
68ca07b77c fix typo 2024-03-15 20:46:06 +09:00
cstef
f354c48c11 Add Eq derive for Input 2024-02-27 18:33:13 +01:00
cstef
38df8592fb Make Input serializable 2024-02-27 18:33:13 +01:00
cstef
4cc1ecaed9 Make Scrolling serializable 2024-02-27 18:33:13 +01:00
cstef
1625d0b603 Add serde feature 2024-02-27 18:33:13 +01:00
rhysd
a9d981f2d8 run doc test for impl FromIterator for TextArea 2023-11-19 22:18:21 +09:00
rhysd
9e3df38b54 fix inser_str doesn't handle \r\n and ignores newline at end of input 2023-11-19 22:08:25 +09:00
rhysd
1194331a02 fix TextArea::set_yank_text doesn't support CRLF (\r\n) for newline 2023-11-18 18:28:32 +09:00
rhysd
13ce6aa6d5 fix selected text is not deleted on paste 2023-11-15 01:57:48 +09:00
rhysd
8e3a432ecc add Key::Copy, Key::Cut, Key::Paste support 2023-11-15 01:29:44 +09:00
rhysd
523a888f26 implement TextArea::select_all
but it is not assigned to default key shortcuts because C-a is already
in use.
2023-11-15 00:11:18 +09:00
rhysd
bae9d4cee3 refactor undo/redo implementation 2023-11-13 19:29:43 +09:00
rhysd
cb868a19b6 add sanity test for all combination of key inputs 2023-11-13 00:19:17 +09:00
rhysd
f28f417e06 fix insert_char and set_yank_text does not consider newline 2023-11-12 23:06:02 +09:00
rhysd
a54ce36d22 refactor text selection and add more tests (fix #6) 2023-11-12 18:22:17 +09:00
pm100
5a2649abe9 implement select (#45)
* select, second go using new multiline code

* implemented internal delete_str, added tests

* delete_str_internal must not put non deleted strings into history. Ie ctrlc should not change history

* delete_str was taking lines out in the non delete case

* corrected comment

* fixes after feedback. Plus multichar bugs. change modal sample
2023-11-10 21:10:04 +09:00
rhysd
efdfc13445 simplify unit tests for DisplayTextBuilder 2023-11-04 19:48:28 +09:00
rhysd
2e6697e54a perfer for to while 2023-11-04 19:36:33 +09:00
rhysd
25bfdbc42b refactor building display text and add tests where start offset is not zero 2023-11-04 19:29:54 +09:00
rhysd
37d42cd545 fix start offset of line text is always zero when calculating tab width 2023-11-04 19:29:49 +09:00
rhysd
217c5079f0 fix pasting yanked text when it contains multiple lines 2023-11-03 02:39:58 +09:00