Qi Xiao
7a87a07f5b
newedit: Simplify dependency interfaces.
2019-03-17 10:35:53 +00:00
Qi Xiao
a2cf05a463
On Windows, enable VT100 escape sequence on startup.
...
This fixes #798 .
2019-03-14 21:42:21 +00:00
Qi Xiao
3f73331ba0
Adjust the order of TTY restoration on Windows.
...
Normal commands no longer produce unsupported escape sequences. This
addresses #798 .
2019-03-14 21:14:43 +00:00
Qi Xiao
150ee696a6
newedit/listing: Support AutoAccept.
2019-03-13 08:46:43 +00:00
Qi Xiao
9027d35465
newedit/listing: Refilter every time filter changes.
2019-03-12 22:10:40 +00:00
Qi Xiao
e3de2eb8b1
Support filtering in listing mode.
2019-03-12 22:01:08 +00:00
Qi Xiao
06fae6494a
newedit: Support accepting in listing mode. Add tests.
2019-03-11 12:25:36 +00:00
Qi Xiao
acb95dac00
newedit: Implement $edit:{listing,lastcmd}:binding.
2019-03-10 21:17:28 +00:00
Qi Xiao
6af426499c
newedit: Reorganize lastcmd so that it behaves more like a mode.
2019-03-10 19:15:01 +00:00
Qi Xiao
c6d7be11ed
newedit/listing: Add basic selection movement support.
2019-03-10 17:09:57 +00:00
Qi Xiao
4c654b6822
edit/ui: Add ui.K as a constructor for ui.Key.
2019-03-10 16:59:27 +00:00
Qi Xiao
5b179a9daa
newedit/listing: Go to initial mode after pressing Esc.
2019-03-10 16:59:21 +00:00
Qi Xiao
2ee2352c95
Add _testwin, a small program to manually test console input on Windows.
2019-03-10 15:56:40 +00:00
Qi Xiao
7e10760892
eval: Update boilerplate.py
2019-03-10 15:24:04 +00:00
Qi Xiao
38dde84a0f
eval: opBody -> effectOpBody, for consistency.
2019-03-10 15:23:43 +00:00
Qi Xiao
6b900563e4
newedit: Basic listing and lastcmd mode.
2019-03-02 23:12:06 +00:00
Qi Xiao
686e944cb1
edit/ui: Add renderer for content with vertical scrollbar.
2019-03-02 23:12:06 +00:00
Qi Xiao
0cb066d326
edit/ui: Add test cases against renderers.
2019-03-02 23:12:06 +00:00
Qi Xiao
ea0b17b20b
edit/ui: Cosmetics.
2019-03-02 23:12:06 +00:00
Qi Xiao
35126799fb
styled: Add a Text.TrimWcwidth method.
2019-03-02 23:12:06 +00:00
Qi Xiao
60169dfb35
styled: Add methods for counting runes and splitting by runes.
2019-03-02 23:12:06 +00:00
Qi Xiao
2664bc9b05
edit/ui: Document that ui.Styled is deprecated.
2019-03-02 23:12:06 +00:00
Qi Xiao
21f1a0163b
edit/ui/render: Add a trivial StringRenderer.
2019-03-02 23:12:06 +00:00
Steve Blundy
d8a93c60c3
Fix a few typos and misspellings ( #796 )
2019-02-25 10:04:57 +00:00
Tw
06abd5dbc5
support option argument completion ( #794 )
...
Signed-off-by: Tw <wei.tan@intel.com>
2019-02-03 20:54:52 -08:00
Tobias Klauser
a78f675a47
sys: use unix.IoctlGetWinsize and unix.Winsize ( #792 )
...
Use the IoctlGetWinsize function and Winsize type from
golang.org/x/sys/unix in sys.GetWinsize instead of duplicating it.
2019-01-29 18:01:58 -08:00
Qi Xiao
6fe68e3744
edit/completion: Deduplicate candidates.
...
This fixes #791 .
2019-01-26 08:22:40 -08:00
pltrz
1875b1a7ad
fix inconsistent example filename in learn/fundamentals page ( #790 )
2019-01-22 01:09:59 +00:00
Qi Xiao
d939a10903
Remove accidentally commited test program.
2018-12-17 23:59:28 +00:00
Qi Xiao
d262a8c61c
Fix test on Windows (for real).
2018-12-17 23:13:32 +00:00
Qi Xiao
dd8a5769f5
newedit: Fix test on Windows.
...
Windows doesn't allow colons in filenames.
2018-12-16 20:10:04 +00:00
Qi Xiao
5c99af44ff
newedit: Set up dependencies for the highlighter.
2018-12-16 13:27:53 +00:00
Qi Xiao
eaca2e36d9
tt: Call t.Helper.
2018-12-16 12:51:22 +00:00
Qi Xiao
efb8be3f4e
Add builtins only-{bytes,values}.
...
This fixes #784 .
2018-12-16 10:40:10 +00:00
Qi Xiao
1ce9b3933c
newedit: Complete the test on SIGHUP; fix name for test on SIGINT.
2018-12-09 12:31:29 +00:00
Qi Xiao
c47df5ea18
newedit/highlight: Test that out-of-order updates are dropped correctly.
...
This package now has 100% test coverage!
2018-12-09 12:19:40 +00:00
Qi Xiao
10ef6ccc5f
newedit/highlight: Test Highlighter instead of highlight.
...
Also fixed a bug where the state of the highlighter is never correctly
maintained.
2018-12-09 12:03:10 +00:00
Qi Xiao
eb7d704110
newedit/core: Highlighter.LateUpdates also deliver styled.Text.
...
Although the result is not used, it makes Highlighter.LateUpdates and
Prompt.LateUpdates identical.
2018-12-08 14:10:11 +00:00
Qi Xiao
28cbb3112e
newedit/highlighter: Highlighter now relays late updates.
2018-12-08 13:47:33 +00:00
Qi Xiao
25bdb6ecd7
newedit/highlight: Make Highlighter opaque.
2018-12-07 20:19:58 +00:00
Qi Xiao
4aecff3af1
newedit/highlight: hlDep -> Dep.
2018-12-07 20:18:13 +00:00
Qi Xiao
2029ee781d
newedit: Change Highlighter to allow late updates.
...
It is now an interface instead of a callback, in a similar fashion to
Prompt.
The call site of the highlighter has also been moved out of the render
function to prepare for relaying late updates..
2018-12-06 23:15:53 +00:00
Qi Xiao
3dae357e5e
newedit/highlight: Support dependencies as callbacks.
2018-11-25 23:01:10 +00:00
Qi Xiao
6daca30365
Implement Ranger for *diag.SourceRange and *eval.CompilationError.
2018-11-20 23:22:51 +00:00
Qi Xiao
ee5b34ef00
newedit/highlight: Elide parse errors at the end.
2018-11-20 21:53:46 +00:00
Qi Xiao
65508e728f
parse: Name chain shift: ErrorEntry -> Error -> MultiError.
...
The Error type now implements the error interface.
2018-11-19 23:05:05 +00:00
Qi Xiao
11e8629cb2
_tools/elvdoc: Support -R, like grep.
2018-11-19 22:18:41 +00:00
Qi Xiao
53feefe839
util: Remove unused function InTempDir.
2018-11-19 20:50:52 +00:00
Qi Xiao
c42b121428
newedit: Add common buffer builtins to the default binding.
2018-11-19 20:03:09 +01:00
Qi Xiao
22f9583850
newedit: Rename buffer builtins.
2018-11-19 20:02:49 +01:00