VPP-23 Re-work pager line collation 54/1154/6
authorChris Luke <chrisy@flirble.org>
Sat, 14 May 2016 14:13:34 +0000 (10:13 -0400)
committerFlorin Coras <florin.coras@gmail.com>
Mon, 16 May 2016 21:37:00 +0000 (21:37 +0000)
commit862623da6eb3dfb211f5ed03ce063137d3f2242e
tree29b157792690407c37cb51ed7c726e0a7dcc1719
parente7a40e86b1f7f2325ebcff1d2506ef6a81536955
VPP-23 Re-work pager line collation

To better handle lines longer than the terminal width, re-work how
the pager collates lines. We still store each output line in a vector
or lines; additionally we index the start and end of displayable lines.

The index then becomes the data to work out what to display.

If the terminal is resized this index is rebuilt and the current page
redisplayed and an attempt made to keep the current top-of-screen line
in place.

Change-Id: Icc6f4f72dabad89682cd82be88adb03eadb7811d
Signed-off-by: Chris Luke <chrisy@flirble.org>
vlib/vlib/unix/cli.c