Daniel Eklöf
f63df93e15
csi: 'X': then 'end' parameter in term_erase() is *inclusive*
2019-07-15 13:55:47 +02:00
Daniel Eklöf
470489c3a3
vt: there are NULL entries in the alternate charset
2019-07-15 13:39:53 +02:00
Daniel Eklöf
6bf75d199b
vt: \EB and \E0 have an optional "private", not param (which are CSI only)
2019-07-15 13:39:19 +02:00
Daniel Eklöf
5597856762
main: set TERM=xterm-direct
2019-07-15 12:36:00 +02:00
Daniel Eklöf
03b9cf2a22
csi: implement ':'-separated 24-bit color values
2019-07-15 12:35:43 +02:00
Daniel Eklöf
6550285cf6
vt: handle ':'-separated sub parameters correctly
2019-07-15 12:34:51 +02:00
Daniel Eklöf
6ac115bffd
vt: implement SI/SO (shift in, shift out)
...
This enables switching between the G0 and G1 charsets.
2019-07-15 12:04:40 +02:00
Daniel Eklöf
6077b57ca5
rename project to 'foot'
2019-07-11 20:10:59 +02:00
Daniel Eklöf
6e4c31960a
scrollback: limit maximum number of lines one can scrollback at once
2019-07-11 18:34:03 +02:00
Daniel Eklöf
cbac302ba1
scrollback: fix assertions in debug builds; need to wrap row number
2019-07-11 18:25:46 +02:00
Daniel Eklöf
0393521d79
input: cancel selection on any mouse *except* BTN_LEFT
2019-07-11 18:17:40 +02:00
Daniel Eklöf
6cd23654cc
selection: disable source listeners, since we don't currently use them
2019-07-11 17:38:03 +02:00
Daniel Eklöf
66e067082b
selection: implement copy *to* primary
2019-07-11 17:38:03 +02:00
Daniel Eklöf
703aeecb95
selection: add support for pasting *from* primary
2019-07-11 17:38:03 +02:00
Daniel Eklöf
e56066feef
selection: add selection_from_primary() API (stub for now)
2019-07-11 17:38:03 +02:00
Daniel Eklöf
5e1715be18
selection: cleanup
2019-07-11 17:38:03 +02:00
Daniel Eklöf
6edc3845bd
selection: calculate required length for clipboard text
2019-07-11 17:38:03 +02:00
Daniel Eklöf
c1c6646b98
selection: read until EOF when reading from clipboard
2019-07-11 17:38:03 +02:00
Daniel Eklöf
e8b6705ab8
selection: it's an error to call offset_accept() on non-drag-and-drop
2019-07-11 17:38:03 +02:00
Daniel Eklöf
3f02a7354e
selection: handle partial writes and EINTR when writing to clipboard
2019-07-11 17:38:03 +02:00
Daniel Eklöf
482c8f76a9
selection: add support for pasting from clipboard
2019-07-11 17:38:02 +02:00
Daniel Eklöf
b50ec1a850
selection: initial copy-to-clipboard functionality
2019-07-11 17:38:02 +02:00
Daniel Eklöf
1f808781f4
selection: selection_finalize() ignores invalid selections
2019-07-11 17:38:02 +02:00
Daniel Eklöf
0facfa4da7
input: call selection_finalize() when BTN_LEFT is released
2019-07-11 17:38:02 +02:00
Daniel Eklöf
e7e199d6b5
selection: spell 'finalize' correctly
2019-07-11 17:38:02 +02:00
Daniel Eklöf
d0e0b6da7c
selection: invalidate *all* affected lines when updating selection
2019-07-11 17:38:02 +02:00
Daniel Eklöf
c43b49dab6
input: ignore mouse motion outside our window
2019-07-11 17:38:02 +02:00
Daniel Eklöf
18070cf286
selection: disable debug logging
2019-07-11 17:38:02 +02:00
Daniel Eklöf
84c0bb8f59
csi: cancel selection when switching between 'normal' and 'alt' grid
2019-07-11 17:38:02 +02:00
Daniel Eklöf
7dd80b08b3
render: bug: don't render cursor when hide cursor is enabled
2019-07-11 17:38:01 +02:00
Daniel Eklöf
d944274f14
selection: disable selection when client has enabled mouse tracking
2019-07-11 17:38:01 +02:00
Daniel Eklöf
bcf763d417
selection: add a selection API
2019-07-11 17:38:01 +02:00
Daniel Eklöf
1c861e5d69
selection: only left button can be used for selection
2019-07-11 17:38:01 +02:00
Daniel Eklöf
632790d5d8
selection: selections can be made, and are rendered
...
* Start selection on mouse button down
* Update selection on motion
* Button release cancels selection if there were no motion after start
* Renderer detects cells inside the selection and inverts their colors
2019-07-11 17:38:01 +02:00
Daniel Eklöf
decb4503bf
grid: prefetch cells in grid_row()
2019-07-10 19:52:30 +02:00
Daniel Eklöf
1a21a5fb29
Merge branch 'cache-optimize'
2019-07-10 19:21:49 +02:00
Daniel Eklöf
e4a631f7f0
terminal: scrolling: prefetch cells of scrolled in lines
...
Since newly scrolled in lines will be erased, we want them in the
cache.
So, allocate and prefetch new lines, then repair non-scrolling
regions (to give the prefetch time to actually fetch the
data). Finally, erase the newly scrolled in lines.
This also fixes a bug where the fixup for the non-scrolling regions
could crash on an unallocated row (we were accessing rows that would
be, but hadn't yet been, scrolled in).
2019-07-10 19:18:53 +02:00
Daniel Eklöf
1d7bf3fbca
terminal: scrolling: better debug log messages
2019-07-10 19:18:36 +02:00
Daniel Eklöf
379f7cf646
grid: swap_row: drop requirement that row indices be positive
2019-07-10 19:17:53 +02:00
Daniel Eklöf
4ffd93ca4c
render: reduce scrollback line count
...
More than 1000 lines and we start exhibiting bad cache behavior
2019-07-10 18:49:34 +02:00
Daniel Eklöf
74ab120101
terminal: use floats instead of double for colors
...
We don't need the full resolution a double gives us. Using floats
reduces the size of cells greatly, which improves cache usage.
2019-07-10 18:48:46 +02:00
Daniel Eklöf
b1f8dd75d6
cell: we only need 4 bytes for the longest utf8 sequence
...
We don't *have* to NULL-terminate the utf8 string. So don't. This
makes the cell glyph 4 bytes exactly, which is better for alignment
and cache usage.
2019-07-10 18:47:32 +02:00
Daniel Eklöf
cf71534768
terminal: remove 'blink' attribute from cell struct
...
This makes the other attribute bits fit in a single uint8_t, which
makes each cell smaller which improves cache usage.
2019-07-10 18:45:12 +02:00
Daniel Eklöf
5a92202a49
scrollback: in debug, verify all rows in the view are initialized
2019-07-10 16:36:10 +02:00
Daniel Eklöf
132749b1ed
grid: repair grid_row_in_view(): use 'view', not 'offset'
2019-07-10 16:35:52 +02:00
Daniel Eklöf
1ff1b3a71e
grid: don't pre-allocate the entire grid (with all scrollback lines)
...
The row array may now contain NULL pointers. This means the
corresponding row hasn't yet been allocated and initialized.
On a resize, we explicitly allocate the visible rows.
Uninitialized rows are then allocated the first time they are
referenced.
2019-07-10 16:27:55 +02:00
Daniel Eklöf
8f0d574dcb
grid: don't implement grid_swap_row() in the header file
2019-07-10 16:08:53 +02:00
Daniel Eklöf
ea1b618b6d
vt: implement \ED and \EE
...
'\ED' is just like '\n'; move the cursor down to the next row, or if
it's at the bottom, scroll up one row.
'\EE' is just like '\n\r'
2019-07-10 16:05:19 +02:00
Daniel Eklöf
885089d146
vt: \EM now calls term_reverse_index() instead of always scrolling one line
2019-07-10 16:05:01 +02:00
Daniel Eklöf
3bb726eb78
vt: '\n' now calls term_linefeed()
2019-07-10 16:04:46 +02:00