1
1
mirror of https://github.com/walles/moar.git synced 2024-10-03 23:17:51 +03:00
Commit Graph

1167 Commits

Author SHA1 Message Date
Johan Walles
c42ac5f66c Improve test performance 2024-09-21 08:50:49 +02:00
Johan Walles
f48a1b4084 Add a missing note 2024-09-21 08:14:36 +02:00
Johan Walles
cd9845c083 Merge branch 'johan/wide-chars'
This fixes display issues when there were wide characters in the input.

Fixes #243.
2024-09-20 22:31:33 +02:00
Johan Walles
801a74e582 Fix a broken test case 2024-09-20 22:24:29 +02:00
Johan Walles
189e622658 Simplify last-cell-on-a-row-is-wide handling
By doing the clipping in SetCell(). This is less intrusive than doing it
in renderLine().
2024-09-20 08:04:56 +02:00
Johan Walles
5bddefafe1 Add wide chars sample file
From here:
https://github.com/walles/moar/issues/243#issuecomment-2348150407
2024-09-20 06:58:25 +02:00
Johan Walles
331646da90 Don't render hidden runes
The same test is still failing, and no scroll-right markers are visible
even though they should, at least for the sample ps.txt file.
2024-09-20 06:56:48 +02:00
Johan Walles
e3b50a0845 Support setting wide characters on screen 2024-09-19 19:48:46 +02:00
Johan Walles
b9b2fcf77a Fix a broken test case 2024-09-18 21:24:31 +02:00
Johan Walles
82401f32ca Cosmetics
Tests are still failing.
2024-09-18 08:11:19 +02:00
Johan Walles
e23cad2a36 Fix a faulty expectation 2024-09-18 07:08:50 +02:00
Johan Walles
3c64f1c4c2 Fix cut-left detection bug
More tests are failing, more fixing needed.
2024-09-18 07:07:10 +02:00
Johan Walles
1552d8adfb Fix a bug, make some tests stop crashing
Some are still failing though, more fixing needed.
2024-09-18 06:59:47 +02:00
Johan Walles
769f6549db WIP: Make scroll indicators wide char aware
And fail some tests, needs fixing.
2024-09-17 19:45:50 +02:00
Johan Walles
0b123b24c7 Overflow should be true for too long lines 2024-09-16 17:07:53 +02:00
Johan Walles
39212f39c6 Test cropping multi-width chars to the right 2024-09-16 17:03:45 +02:00
Johan Walles
7966c83ebc Fix the last multi character line wrapping problem 2024-09-15 19:14:23 +02:00
Johan Walles
c45209def5 Start fixing line wrapping of wide characters
A test is crashing. There may be other issues that need fixing.
2024-09-15 15:24:32 +02:00
Johan Walles
5295602e42 Implement rune width measuring 2024-09-15 14:17:41 +02:00
Johan Walles
9c858a7ecb Add a rune width test 2024-09-15 14:13:16 +02:00
Johan Walles
e0e9ee6610 Start telling screen cells from styled runes
One rune can cover multiple screen cells.
2024-09-15 13:56:50 +02:00
Johan Walles
bac6d0d80e Add line wrapping tests 2024-09-15 09:22:24 +02:00
Johan Walles
5b180e20ca Tune docs + linting 2024-09-15 09:12:39 +02:00
Johan Walles
60088072db More tests on the same theme 2024-09-15 09:08:48 +02:00
Johan Walles
8cff9fa78c Use the new function in one more place 2024-09-15 07:32:53 +02:00
Johan Walles
c5a2102377 Add test for wide character support
Failing.
2024-09-15 07:29:19 +02:00
Johan Walles
4930d0aed3 Accept \ characters in URLs
Generated by some software on Windows, also accepted by less. We should
accept them for compatibility reasons.

Fixes #244.
2024-09-14 10:39:36 +02:00
Johan Walles
6d3bf3dfd4 Auto detect JSON for highlighting
Resolves #240.
2024-09-10 16:54:53 +02:00
Johan Walles
f885c873af
Merge pull request #239 from lapo-luchini/version
Use module version when not built with script.
2024-09-03 20:11:55 +02:00
Johan Walles
f1a65a7a8d Maintain build.sh link for local builds 2024-09-03 20:08:42 +02:00
Lapo Luchini
e225cc77f7
Fix indent-error-flow.
Signed-off-by: Lapo Luchini <lapo@lapo.it>
2024-09-01 18:43:51 +02:00
Lapo Luchini
214662484f
Use module version when not built with script.
Signed-off-by: Lapo Luchini <lapo@lapo.it>
2024-08-31 12:49:21 +02:00
Johan Walles
e68547a413 Make line numbers easier to read 2024-08-13 07:00:32 +02:00
Johan Walles
c379459982 Add a regression test
For: https://github.com/walles/moar/issues/236#issuecomment-2282677792
2024-08-13 06:56:16 +02:00
Johan Walles
a67c887554 Include stack trace in panic logs 2024-08-12 21:47:46 +02:00
Johan Walles
27e9c0d68b Merge branch 'johan/color-underline'
Fixes #237.
2024-08-12 20:57:59 +02:00
Johan Walles
f69e58d9b3 Handle reading underline color 2024-08-12 20:57:44 +02:00
Johan Walles
065b95a653 Add a colored underline test case 2024-08-12 20:50:57 +02:00
Johan Walles
d9b3e16e00 Render underline color changes 2024-08-12 20:44:40 +02:00
Johan Walles
ae0ae42241 Support parsing underline color escape sequences 2024-08-12 20:43:10 +02:00
Johan Walles
2c9f16fa2a Add underline color support to Style 2024-08-12 20:39:48 +02:00
Johan Walles
43f17ebe7b Remove no-longer-needed code 2024-08-12 20:31:11 +02:00
Johan Walles
f26ae4ff9a Introduce colorType to ansiString 2024-08-12 20:25:53 +02:00
Johan Walles
44136f6524 More renaming, forgot some things 2024-08-12 18:53:44 +02:00
Johan Walles
42b0bc7e25 Improve naming 2024-08-12 18:36:49 +02:00
Johan Walles
37cf840879 Fix a highlighting issue
Reported here:
https://github.com/walles/moar/issues/236#issuecomment-2282677792
2024-08-11 16:34:29 +02:00
Johan Walles
6cf1223634 Catch errors in goroutines and log them 2024-08-10 08:40:48 +02:00
Johan Walles
3b5b2ff31f Handle scrolling down while stream is loading
I don't know how this could work even without the stream loading, but
now it does.

Fixes #235.
2024-08-09 09:50:38 +02:00
Johan Walles
db41b5c946 Give tests more time on Windows
CI is slow on Windows.
2024-08-06 10:59:08 +02:00
Johan Walles
479d8970b2 Build tests in a separate step
To help the tests not time out.
2024-08-06 10:56:30 +02:00