Commits
- Commit:
f853ec6f0c0569cf5bae15ce3e9d8bfc533b358b
- From:
- Omar Polo <op@omarpolo.com>
- Date:
handle tab characters
tab characters have their width depending on the column they're in,
since they extend to the next multiple of 8. (citation needed?)
So, keep track of the column when considering the length (in columns)
of the text, so that we can render them properly.
In the future we might want to turn them into spaces (either at read
or render time) just to stay on the safe side in case not all
terminals/ncurses implementations use 8 columns.
- Commit:
7c9e12dfe9e21d4d4d9797a77ec89359808c7d22
- From:
- Omar Polo <op@omarpolo.com>
- Date:
wrapping shouldn't reach the last column
since we can't move the cursor past the last column, we can't draw a
character there.
- Commit:
6d24bfb3ca185665e8a7fa4e5f88434690f4272d
- From:
- Omar Polo <op@omarpolo.com>
- Date:
use a byte offset to track the point in the line
Instead of using a code-point offset, use a raw byte offset and
navigate backward and forward by means of graphemes. This gives a
correct "visual" backward/forward navigation through characters.
- Commit:
3d89457cdeba5041aa6f0c1f8640b91bcbb6ec51
- From:
- Thomas Adam <thomas.adam22@gmail.com>
- Date:
code: add wrappers for common failure cases
Certain calls to well-known functions sometimes result in similar
error handling across the code base. Sometimes there's a need to
centralise the failure case.
Achieve this for common wrappers to often-used functions.
The transformation is achieved via coccinelle, commited with this patch.
Note that coccinelle can be told to ignore code blocks with comment
delimiters.
This transformation applies just to telescope's code, and not any of the
bundled depdencies in telescope (libgrapheme).
- Commit:
c1d27b0e114e6a65f7979971940df212f00bb2ae
- From:
- Omar Polo <op@omarpolo.com>
- Date:
untangle a bit buffers and parsers
Now buffers have a nicer interface, taking explicitly the buffer
where they push stuff, and the code that deals with buffers doesn't
need to peek into the parsers. The parsers now are 'pure' structs
without state attached to them, the state was moved to the buffer.
- Commit:
1ac119fb5a25757d6e8eaa3b53320b7c3be61cee
- From:
- Omar Polo <op@omarpolo.com>
- Date:
move all the sources back in the root directory
subdir is just messier for no good reason