<feed xmlns='http://www.w3.org/2005/Atom'>
<title>r-alacritty.git/alacritty_terminal/tests/ref, branch experimental</title>
<subtitle>My custom-patched version of alacritty.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/'/>
<entry>
<title>Unify the grid line indexing types</title>
<updated>2021-03-30T23:25:38+00:00</updated>
<author>
<name>Christian Duerr</name>
<email>contact@christianduerr.com</email>
</author>
<published>2021-03-30T23:25:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=3bd5ac221ab3b122962063edd1f4c10f9f2d117f'/>
<id>3bd5ac221ab3b122962063edd1f4c10f9f2d117f</id>
<content type='text'>
Previously Alacritty was using two different ways to reference lines in
the terminal. Either a `usize`, or a `Line(usize)`. These indexing
systems both served different purposes, but made it difficult to reason
about logic involving these systems because of its inconsistency.

To resolve this issue, a single new `Line(i32)` type has been
introduced.  All existing references to lines and points now rely on
this definition of a line.

The indexing starts at the top of the terminal region with the line 0,
which matches the line 1 used by escape sequences. Each line in the
history becomes increasingly negative and the bottommost line is equal
to the number of visible lines minus one.

Having a system which goes into the negatives allows following the
escape sequence's indexing system closely, while at the same time making
it trivial to implement `Ord` for points.

The Alacritty UI crate is the only place which has a different indexing
system, since rendering and input puts the zero line at the top of the
viewport, rather than the top of the terminal region.

All instances which refer to a number of lines/columns instead of just a
single Line/Column have also been changed to use a `usize` instead. This
way a Line/Column will always refer to a specific place in the grid and
no confusion is created by having a count of lines as a possible index
into the grid storage.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously Alacritty was using two different ways to reference lines in
the terminal. Either a `usize`, or a `Line(usize)`. These indexing
systems both served different purposes, but made it difficult to reason
about logic involving these systems because of its inconsistency.

To resolve this issue, a single new `Line(i32)` type has been
introduced.  All existing references to lines and points now rely on
this definition of a line.

The indexing starts at the top of the terminal region with the line 0,
which matches the line 1 used by escape sequences. Each line in the
history becomes increasingly negative and the bottommost line is equal
to the number of visible lines minus one.

Having a system which goes into the negatives allows following the
escape sequence's indexing system closely, while at the same time making
it trivial to implement `Ord` for points.

The Alacritty UI crate is the only place which has a different indexing
system, since rendering and input puts the zero line at the top of the
viewport, rather than the top of the terminal region.

All instances which refer to a number of lines/columns instead of just a
single Line/Column have also been changed to use a `usize` instead. This
way a Line/Column will always refer to a specific place in the grid and
no confusion is created by having a count of lines as a possible index
into the grid storage.
</pre>
</div>
</content>
</entry>
<entry>
<title>Use dynamic storage for zerowidth characters</title>
<updated>2020-11-05T04:45:14+00:00</updated>
<author>
<name>Christian Duerr</name>
<email>contact@christianduerr.com</email>
</author>
<published>2020-11-05T04:45:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=ec42b42ce601808070462111c0c28edb0e89babb'/>
<id>ec42b42ce601808070462111c0c28edb0e89babb</id>
<content type='text'>
The zerowidth characters were conventionally stored in a [char; 5].
This creates problems both by limiting the maximum number of zerowidth
characters and by increasing the cell size beyond what is necessary even
when no zerowidth characters are used.

Instead of storing zerowidth characters as a slice, a new CellExtra
struct is introduced which can store arbitrary optional cell data that
is rarely required. Since this is stored behind an optional pointer
(Option&lt;Box&lt;CellExtra&gt;&gt;), the initialization and dropping in the case
of no extra data are extremely cheap and the size penalty to cells
without this extra data is limited to 8 instead of 20 bytes.

The most noticible difference with this PR should be a reduction in
memory size of up to at least 30% (1.06G -&gt; 733M, 100k scrollback, 72
lines, 280 columns). Since the zerowidth characters are now stored
dynamically, the limit of 5 per cell is also no longer present.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The zerowidth characters were conventionally stored in a [char; 5].
This creates problems both by limiting the maximum number of zerowidth
characters and by increasing the cell size beyond what is necessary even
when no zerowidth characters are used.

Instead of storing zerowidth characters as a slice, a new CellExtra
struct is introduced which can store arbitrary optional cell data that
is rarely required. Since this is stored behind an optional pointer
(Option&lt;Box&lt;CellExtra&gt;&gt;), the initialization and dropping in the case
of no extra data are extremely cheap and the size penalty to cells
without this extra data is limited to 8 instead of 20 bytes.

The most noticible difference with this PR should be a reduction in
memory size of up to at least 30% (1.06G -&gt; 733M, 100k scrollback, 72
lines, 280 columns). Since the zerowidth characters are now stored
dynamically, the limit of 5 per cell is also no longer present.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add support for single line terminals</title>
<updated>2020-09-27T22:36:08+00:00</updated>
<author>
<name>ii41</name>
<email>23465321+ii41@users.noreply.github.com</email>
</author>
<published>2020-09-27T22:36:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=a754d06b44139b85e8b34a71ece4477cb1caa85e'/>
<id>a754d06b44139b85e8b34a71ece4477cb1caa85e</id>
<content type='text'>
This changes the minimum terminal dimensions from 2 lines and 2 columns,
to 1 line and 2 columns.

This also reworks the `SizeInfo` to store the number of columns and
lines and consistently has only the terminal lines/columns stored,
instead of including the message bar and search in some places of the
Alacritty renderer/input.

These new changes also make it easy to properly start the selection
scrolling as soon as the mouse is over the message bar, instead of
waiting until it is beyond it.

Fixes #4207.

Co-authored-by: Christian Duerr &lt;contact@christianduerr.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This changes the minimum terminal dimensions from 2 lines and 2 columns,
to 1 line and 2 columns.

This also reworks the `SizeInfo` to store the number of columns and
lines and consistently has only the terminal lines/columns stored,
instead of including the message bar and search in some places of the
Alacritty renderer/input.

These new changes also make it easy to properly start the selection
scrolling as soon as the mouse is over the message bar, instead of
waiting until it is beyond it.

Fixes #4207.

Co-authored-by: Christian Duerr &lt;contact@christianduerr.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Add support for double underlines</title>
<updated>2020-08-12T16:05:22+00:00</updated>
<author>
<name>Christian Duerr</name>
<email>contact@christianduerr.com</email>
</author>
<published>2020-08-12T16:05:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=b904207b1979bb86f86c2a7db1720ce04571508a'/>
<id>b904207b1979bb86f86c2a7db1720ce04571508a</id>
<content type='text'>
This adds support for double underlines using the colon separated escape
sequence `CSI 4 : 2 m`.

Alacritty will now also always fallback to the normal underline in case
any of the other underlines like the undercurl are specified. The escape
sequence `CSI 4 : 0 m` can now be used to clear all underlines.

Some terminals support `CSI 21 m` for double underline, but since
Alacritty already uses that as cancel bold which is a little more
consistent, that behavior has not changed. So the colon separated
variant must be used.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This adds support for double underlines using the colon separated escape
sequence `CSI 4 : 2 m`.

Alacritty will now also always fallback to the normal underline in case
any of the other underlines like the undercurl are specified. The escape
sequence `CSI 4 : 0 m` can now be used to clear all underlines.

Some terminals support `CSI 21 m` for double underline, but since
Alacritty already uses that as cancel bold which is a little more
consistent, that behavior has not changed. So the colon separated
variant must be used.</pre>
</div>
</content>
</entry>
<entry>
<title>Add support for colon separated SGR parameters</title>
<updated>2020-08-07T22:37:23+00:00</updated>
<author>
<name>Christian Duerr</name>
<email>contact@christianduerr.com</email>
</author>
<published>2020-08-07T22:37:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=576252294d09c1f52ec73bde03652349bdf5a529'/>
<id>576252294d09c1f52ec73bde03652349bdf5a529</id>
<content type='text'>
This implements the colon separated form of SGR 38 and 48.

Fixes #1485.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This implements the colon separated form of SGR 38 and 48.

Fixes #1485.</pre>
</div>
</content>
</entry>
<entry>
<title>Fix saved cursor handling</title>
<updated>2020-07-06T19:10:06+00:00</updated>
<author>
<name>Christian Duerr</name>
<email>contact@christianduerr.com</email>
</author>
<published>2020-07-06T19:10:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=65bff1878ff68698da021b4d5aa00d1cfad41d0a'/>
<id>65bff1878ff68698da021b4d5aa00d1cfad41d0a</id>
<content type='text'>
This resolves several problems with handling of the saved cursor when
switching between primary and alternate screen. Additionally ref-tests
are also added for all common interactions to make sure the behavior
does not regress.

The behavior is based on XTerm's behavior except for interaction with
`reset`. XTerm does not reset the alternate screen's saved cursor on
`reset`, but VTE does. Since a `reset` should reset as much as possible,
Alacritty copies VTE here instead of XTerm.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This resolves several problems with handling of the saved cursor when
switching between primary and alternate screen. Additionally ref-tests
are also added for all common interactions to make sure the behavior
does not regress.

The behavior is based on XTerm's behavior except for interaction with
`reset`. XTerm does not reset the alternate screen's saved cursor on
`reset`, but VTE does. Since a `reset` should reset as much as possible,
Alacritty copies VTE here instead of XTerm.</pre>
</div>
</content>
</entry>
<entry>
<title>Preserve linewrap flag across alt screen switches</title>
<updated>2020-07-06T05:08:36+00:00</updated>
<author>
<name>Christian Duerr</name>
<email>contact@christianduerr.com</email>
</author>
<published>2020-07-06T05:08:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=72c916ff434e23d44e2a31e6a8d5f7b8ae649008'/>
<id>72c916ff434e23d44e2a31e6a8d5f7b8ae649008</id>
<content type='text'>
While neither VTE, URxvt nor Kitty handle this, preserving the linewrap
flag across alternate screen switches seems like the correct thing to
do. XTerm also does handle this correctly, which indicates that it is a
bug and not a feature.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
While neither VTE, URxvt nor Kitty handle this, preserving the linewrap
flag across alternate screen switches seems like the correct thing to
do. XTerm also does handle this correctly, which indicates that it is a
bug and not a feature.</pre>
</div>
</content>
</entry>
<entry>
<title>Fix scroll down escape pulling lines from history</title>
<updated>2020-06-25T09:50:17+00:00</updated>
<author>
<name>Christian Duerr</name>
<email>contact@christianduerr.com</email>
</author>
<published>2020-06-25T09:50:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=6c8966f426552065f2846c0c1f555d02aba98141'/>
<id>6c8966f426552065f2846c0c1f555d02aba98141</id>
<content type='text'>
This works around a bug where the optimized version of the
`Grid::scroll_down` function would just rotate the entire grid down if
the scrolling region starts at the top of the screen, even if there is
history available.

Since rotations of scrolling regions should not affect the scrollback
history, this optimized version is now only called when the max
scrollback size is 0, making it impossible for the grid to have any
history while it is used.

Since the main usecase of this is the alternate screen buffer, which
never has any history, the performance should not be affected negatively
by this change.

Fixes #3582.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This works around a bug where the optimized version of the
`Grid::scroll_down` function would just rotate the entire grid down if
the scrolling region starts at the top of the screen, even if there is
history available.

Since rotations of scrolling regions should not affect the scrollback
history, this optimized version is now only called when the max
scrollback size is 0, making it impossible for the grid to have any
history while it is used.

Since the main usecase of this is the alternate screen buffer, which
never has any history, the performance should not be affected negatively
by this change.

Fixes #3582.</pre>
</div>
</content>
</entry>
<entry>
<title>Fix incorrect grid.len() and grid.history_size()</title>
<updated>2020-01-26T13:49:58+00:00</updated>
<author>
<name>Kirill Chibisov</name>
<email>contact@kchibisov.com</email>
</author>
<published>2020-01-26T13:49:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=4cc6421daa4ff5976ab43c67110a7a80a36541e5'/>
<id>4cc6421daa4ff5976ab43c67110a7a80a36541e5</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Update outdated reftests</title>
<updated>2020-01-04T23:55:10+00:00</updated>
<author>
<name>Kirill Chibisov</name>
<email>contact@kchibisov.com</email>
</author>
<published>2020-01-04T23:55:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.josher.dev/cgit/r-alacritty.git/commit/?id=5aaa350e1a79402244c3350b2cad9880c4e770e4'/>
<id>5aaa350e1a79402244c3350b2cad9880c4e770e4</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
