<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mirrors/foot.git/selection.c, branch master</title>
<subtitle>A fast, lightweight and minimalistic Wayland terminal emulator</subtitle>
<id>https://git.0x0f.dev/mirrors/foot.git/atom?h=master</id>
<link rel='self' href='https://git.0x0f.dev/mirrors/foot.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/'/>
<updated>2026-10-28T08:39:41Z</updated>
<entry>
<title>selection: fix multi-cell chars selection update</title>
<updated>2026-10-28T08:39:41Z</updated>
<author>
<name>CismonX</name>
<email>admin@cismon.net</email>
</author>
<published>2026-10-28T08:39:41Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=61e88e44fc0f8ad8aa2ab2f69968d7a8ceaa8a77'/>
<id>urn:sha1:61e88e44fc0f8ad8aa2ab2f69968d7a8ceaa8a77</id>
<content type='text'>
As in 0e7e943062, absolute row numbers cannot be used for comparison.
Here it may break selection update with multi-cell characters.

Note that there's no need to compare the coordinates again.
A better fix is to check the selection direction instead.
</content>
</entry>
<entry>
<title>selection: fix row comparison in selection update</title>
<updated>2026-10-25T10:47:06Z</updated>
<author>
<name>CismonX</name>
<email>admin@cismon.net</email>
</author>
<published>2026-10-10T23:29:39Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=0e7e943062cc002b07d107f408eea7208f2d836c'/>
<id>urn:sha1:0e7e943062cc002b07d107f408eea7208f2d836c</id>
<content type='text'>
Absolute row numbers may wrap around, thus not suitable for comparison.
This may incorrectly update the selection direction and break word-wise
selection.

Compare scrollback-relative row numbers instead.

Fixes #2483.
</content>
</entry>
<entry>
<title>selection: treat spacer pad cells as empty cells when marking cells for highlighting</title>
<updated>2026-09-10T06:37:01Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2026-09-02T12:25:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=2705e36f0ecf3ef50c13b41165de852f134859d6'/>
<id>urn:sha1:2705e36f0ecf3ef50c13b41165de852f134859d6</id>
<content type='text'>
</content>
</entry>
<entry>
<title>selection: don't allow the start/end-points to be inside spacer pad cells</title>
<updated>2026-09-10T06:37:01Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2026-09-02T12:23:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=92c61ec9b1cef3bf6d1da01db3310daff6bba522'/>
<id>urn:sha1:92c61ec9b1cef3bf6d1da01db3310daff6bba522</id>
<content type='text'>
Having the start/end-points in the pad area made the spacer cells
tracking points when reflowing the grid. This caused the spacer cells
to be kept, instead of removed.
</content>
</entry>
<entry>
<title>selection: don't include spacer pad cells when extending the selection to cover all of a multi-cell character</title>
<updated>2026-09-10T06:37:01Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2026-09-02T12:22:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=e6b286403f08163e914eb8ff5af06999dec52214'/>
<id>urn:sha1:e6b286403f08163e914eb8ff5af06999dec52214</id>
<content type='text'>
When the selection starts or ends in the middle of a multi-cell
character, we stretch the selection so that all of the cells belonging
to the character is selected.

When we do this, we do *not* want trailing pad cells to be included in
the selection.
</content>
</entry>
<entry>
<title>selection: check column when updating selection</title>
<updated>2026-08-06T10:44:04Z</updated>
<author>
<name>CismonX</name>
<email>admin@cismon.net</email>
</author>
<published>2026-07-31T04:49:51Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=919e06c8438bbbc9b214f2caacfe14ea031844e3'/>
<id>urn:sha1:919e06c8438bbbc9b214f2caacfe14ea031844e3</id>
<content type='text'>
Selection coordinates may appear outside of the terminal grid
(e.g., during the "fast resize" stage of delayed resize),
resulting in bad width passed to pixman_region32_union_rect().
</content>
</entry>
<entry>
<title>selection: find-quote-right: assert next-row &gt; 0</title>
<updated>2026-07-30T05:29:50Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2026-07-30T05:29:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=38b3424a1148779a659ea26077965518118c8e9f'/>
<id>urn:sha1:38b3424a1148779a659ea26077965518118c8e9f</id>
<content type='text'>
</content>
</entry>
<entry>
<title>selection: fixed segfault when quote is on newline</title>
<updated>2026-07-30T05:17:14Z</updated>
<author>
<name>Emily Vlasics</name>
<email>e.vlasics@mail.utoronto.ca</email>
</author>
<published>2026-07-29T03:11:15Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=5913184de4bfd945bec70333a752e02dac0b8500'/>
<id>urn:sha1:5913184de4bfd945bec70333a752e02dac0b8500</id>
<content type='text'>
Closes #2405
</content>
</entry>
<entry>
<title>selection: fix word boundary check</title>
<updated>2026-07-21T08:56:02Z</updated>
<author>
<name>CismonX</name>
<email>admin@cismon.net</email>
</author>
<published>2026-07-10T15:16:43Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=11e3fa0d59da71267e5c7f5cb16c502d15901eb7'/>
<id>urn:sha1:11e3fa0d59da71267e5c7f5cb16c502d15901eb7</id>
<content type='text'>
This patch fixes rightmost boundary check for a word wrapped to
another line, where a multi-column character appears as the last
character in the original line.

Closes #2411
</content>
</entry>
<entry>
<title>selection: escape quotes in file names being DnD:ed on the command line</title>
<updated>2026-06-12T16:49:48Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2026-06-12T16:49:48Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=ca73ec71d5747d2c0c68b8b562cee3bb80b773ac'/>
<id>urn:sha1:ca73ec71d5747d2c0c68b8b562cee3bb80b773ac</id>
<content type='text'>
Closes #2363
</content>
</entry>
<entry>
<title>selection: fix block selection direction update</title>
<updated>2026-06-12T15:36:42Z</updated>
<author>
<name>CismonX</name>
<email>admin@cismon.net</email>
</author>
<published>2026-05-23T22:47:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=382e9a31c5c631258da8f6ebb17f1b9aecb92e6b'/>
<id>urn:sha1:382e9a31c5c631258da8f6ebb17f1b9aecb92e6b</id>
<content type='text'>
This patch fixes a condition check in selection_update(), so that
during block selection, the selection area no longer gets incorrectly
updated when selecting back across the starting column.
</content>
</entry>
<entry>
<title>selection: do not copy empty text</title>
<updated>2026-05-22T09:49:46Z</updated>
<author>
<name>CismonX</name>
<email>admin@cismon.net</email>
</author>
<published>2026-05-20T18:38:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=4bf60d0fbcad533c5131288617caae67342c1065'/>
<id>urn:sha1:4bf60d0fbcad533c5131288617caae67342c1065</id>
<content type='text'>
Copy-on-select (configured with 'selection-target') may accidentally
clear the clipboard, if the user drags the mouse a little bit when
clicking inside a terminal window.

Now we only copy if there is actual text being selected.

Closes #2327
</content>
</entry>
<entry>
<title>osc-52: don't strip any control characters, and don't do newline conversion</title>
<updated>2026-03-22T17:57:49Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2026-03-02T07:11:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=46a9cb8aab3145c8d4083aea485eaf7e2d44bf51'/>
<id>urn:sha1:46a9cb8aab3145c8d4083aea485eaf7e2d44bf51</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix assertion failure triple-clicking line with quote in last column</title>
<updated>2025-11-12T06:41:35Z</updated>
<author>
<name>Johannes Altmanninger</name>
<email>aclopte@gmail.com</email>
</author>
<published>2025-11-07T06:32:11Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=5cb8ff2e9c51c528589e5e1ef78b9a6bd554fc0d'/>
<id>urn:sha1:5cb8ff2e9c51c528589e5e1ef78b9a6bd554fc0d</id>
<content type='text'>
By default, triple-click tries to select quoted strings within a
logical line.  This also works if the line spans multiple screen lines.

If there is a quote character in the last column:

	printf %"$COLUMNS"s \'; printf wrapped; sleep inf

and I triple-click on the following soft-wrapped line, there's an
assertion failure because the column next to the quote is out of range.

The quote position has been found by walking at least one cell
backwards from "pos". This means that if the quote position is in
the very last column, there must be a row below.

Also move the assertion to be a pre-condition, though that's debatable.
</content>
</entry>
<entry>
<title>selection: fix crash when tripple clicking in a region containing NUL characters</title>
<updated>2024-12-22T06:09:37Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2024-12-22T06:09:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=67bd5dd460d646d49b9959ce3190272f2bfe06be'/>
<id>urn:sha1:67bd5dd460d646d49b9959ce3190272f2bfe06be</id>
<content type='text'>
If a cell contains a NUL character, it was incorrectly treated as a
quote, later triggering an assertion.

Patch by Johannes Altmanninger
</content>
</entry>
<entry>
<title>selection: set row-&gt;dirty when clearing the cell-&gt;attrs.clean bit</title>
<updated>2024-09-21T07:11:07Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2024-09-20T15:16:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=49ed8b5e21c5a46b9e32ae941ab2dbc2a0f61b88'/>
<id>urn:sha1:49ed8b5e21c5a46b9e32ae941ab2dbc2a0f61b88</id>
<content type='text'>
Closes #1715
</content>
</entry>
<entry>
<title>Don't use fancy Unicode quotes, stick to ASCII</title>
<updated>2024-02-06T11:36:45Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2024-02-06T11:36:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=7999975016a57cc0a2c2e20bc55f29de32df7044'/>
<id>urn:sha1:7999975016a57cc0a2c2e20bc55f29de32df7044</id>
<content type='text'>
</content>
</entry>
<entry>
<title>util: add streq() function and use in place of strcmp(...) == 0</title>
<updated>2024-02-05T11:09:52Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2024-01-24T23:17:28Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=e0f3703ae6c4084f9275cfc78d87e5604cc27a10'/>
<id>urn:sha1:e0f3703ae6c4084f9275cfc78d87e5604cc27a10</id>
<content type='text'>
</content>
</entry>
<entry>
<title>selection: find_word_boundary: ensure row number is bounded</title>
<updated>2023-10-08T08:38:39Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2023-10-03T12:07:41Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=ca128ae3802dde3b2bafab190a09911589d23e8a'/>
<id>urn:sha1:ca128ae3802dde3b2bafab190a09911589d23e8a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>selection: selection_update() uses view-local coordinates</title>
<updated>2023-10-08T08:38:38Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2023-09-27T14:23:30Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=5e013cad78a1989f4deb0972a465dfcdad0dc1d2'/>
<id>urn:sha1:5e013cad78a1989f4deb0972a465dfcdad0dc1d2</id>
<content type='text'>
</content>
</entry>
</feed>
