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:
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:
f7db6d139bba0fb56f0560533b77af219958ecc0
- From:
- Omar Polo <op@omarpolo.com>
- Date:
some headers cleanup
try to not include headers from headers, and remove some redundant
include.
This helps in modularizing the codebase and also helps during
incremental compilations.
- Commit:
cbe2da3279946cae9bb365a672e6600268de9cce
- From:
- Omar Polo <op@omarpolo.com>
- Date:
move struct cmd and cmds declaration in cmd.h
- Commit:
32ac17a4ea1ad4c2f9e8c8d78dd5738958883291
- From:
- Omar Polo <op@omarpolo.com>
- Date:
replace TAILQ_EMPTY/INSERT_HEAD/TAIL dance with a single TAILQ_INSERT_TAIL
Now that all the queues are correctly initialised, there's no need for
that dance.
- Commit:
408b51819656814ce96d28d88005b0dcb27e2be2
- From:
- Omar Polo <op@omarpolo.com>
- Date:
add prototypes and use proper type (fn ptr vs void *)
- Commit:
d7352f56a0347b3aea16c30ce69f42162e13745b
- From:
- Omar Polo <op@omarpolo.com>
- Date:
give a name to to the help buffer
- Commit:
c6be26e477ec817b6c8e56297729595524b7b9c3
- From:
- Omar Polo <op@omarpolo.com>
- Date:
pretty print help lines
- Commit:
7102f5d94d510ebd2af6b36c075d3c338a7dc338
- From:
- Omar Polo <op@omarpolo.com>
- Date:
recompute help only when needed
- Commit:
de27856787c352519320f213681df6c680a3d446
- From:
- Omar Polo <op@omarpolo.com>
- Date:
move help to its own file
in order to do so, we also have to export some internal variables from
ui (the width and height of the window). Not the best possible
outcome, but are used only in recompute_help, and can be dropped
later.
Also, move wrap_page to wrap.c.