<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mirrors/foot.git/terminal.h, branch 1.6.0</title>
<subtitle>A fast, lightweight and minimalistic Wayland terminal emulator</subtitle>
<id>https://git.0x0f.dev/mirrors/foot.git/atom?h=1.6.0</id>
<link rel='self' href='https://git.0x0f.dev/mirrors/foot.git/atom?h=1.6.0'/>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/'/>
<updated>2020-12-16T13:30:49Z</updated>
<entry>
<title>vt: don’t ignore extra private/intermediate characters</title>
<updated>2020-12-16T13:30:49Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-12-16T13:30:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=2e137c0a7e747a781ec311c6aad656873072b96c'/>
<id>urn:sha1:2e137c0a7e747a781ec311c6aad656873072b96c</id>
<content type='text'>
Take ‘\E(#0’ for example - this is *not* the same as ‘\E(0’.

Up until now, foot has however treated them as the same escape,
because the handler for ‘\E(0’ didn’t verify there weren’t any _other_
private characters present.

Fix this by turning the ‘private’ array into a single 4-byte
integer. This allows us to match *all* privates with a single
comparison.

Private characters are added to the LSB first, and MSB last. This
means we can check for single privates in pretty much the same way as
before:

  switch (term-&gt;vt.private) {
  case ‘?’:
      ...
      break;
  }

Checking for two (or more) is much uglier, but foot only supports
a *single* escape with two privates, and no escapes with three or
more:

  switch (term-&gt;vt.private) {
  case 0x243f:  /* ‘?$’ */
      ...
      break;
  }

The ‘clear’ action remains simple (and fast), with a single write
operation.

Collecting privates is potentially _slightly_ more complex than
before; we now need mask and compare, instead of simply comparing,
when checking how many privates we already have.

We _could_ add a counter, which would make collecting privates easier,
but this would add an additional write to the ‘clean’ action which is
really bad since it’s in the hot path.
</content>
</entry>
<entry>
<title>term: enabling application synchronized updates clear pending grid refresh</title>
<updated>2020-12-14T18:05:54Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-12-14T18:05:03Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=6c8b034affae251cdb6645633c1b965c67e78850'/>
<id>urn:sha1:6c8b034affae251cdb6645633c1b965c67e78850</id>
<content type='text'>
This fixes issues with de-synchronized frames being rendered; we may
have scheduled a redraw earlier, that hasn’t yet triggered (probably
because we’re waiting for a frame callback), when we enable
application synchronized updates.

This means we risk rendering a partially updated state when the frame
callback finally arrives, if the application hasn’t yet ended its
synchronized update.
</content>
</entry>
<entry>
<title>config: add ‘notify’ to possible values for ‘bell’ in foot.ini</title>
<updated>2020-12-10T17:22:48Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-12-10T17:22:48Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=15d20af2a24664b09604f1ec5f121c38f1500c32'/>
<id>urn:sha1:15d20af2a24664b09604f1ec5f121c38f1500c32</id>
<content type='text'>
When `bell=notify`, foot will trigger a desktop notification when it
receives a BEL in an unfocused window.
</content>
</entry>
<entry>
<title>ime: store wchar version of pre-edit string in terminal struct</title>
<updated>2020-12-07T19:44:14Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-12-06T11:17:52Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=194fbff883e605a3a9afac4ecc66c6cf3cc6b7fa'/>
<id>urn:sha1:194fbff883e605a3a9afac4ecc66c6cf3cc6b7fa</id>
<content type='text'>
</content>
</entry>
<entry>
<title>csi: add DECSET 737769 - enables/disables IME input</title>
<updated>2020-12-07T19:44:12Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-12-04T20:26:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=0536bc41f4c3538aa1ad4cd68a5339de6a5a8613'/>
<id>urn:sha1:0536bc41f4c3538aa1ad4cd68a5339de6a5a8613</id>
<content type='text'>
73 77 69 = I M E
</content>
</entry>
<entry>
<title>ime: add functions to enable/disable IME, simplify code that enables IME</title>
<updated>2020-12-07T19:44:11Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-12-04T17:39:11Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=b59d695b2b00157e403399af78b3128848a65e0f'/>
<id>urn:sha1:b59d695b2b00157e403399af78b3128848a65e0f</id>
<content type='text'>
We may want to be able to enable/disable IME run-time, even though we
have received an ‘enter’ IME event.

This enables us to do that.

Also add functions to enable/disable IME on a per-terminal instance
basis.

A terminal may have multiple seats focusing it, and enabling/disabling
IME in a terminal instance enables/disables IME on all those seats.

Finally, the code to enable IME is simplified; the *only* surface that
can ever receive ‘enter’ IME events is the main grid. All other
surfaces are sub-surfaces, without their own keyboard focus.
</content>
</entry>
<entry>
<title>ime: make IME compile-time optional</title>
<updated>2020-12-07T19:44:10Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-12-03T17:36:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=05083110c3fad046ccf0838a364150b8d2bab888'/>
<id>urn:sha1:05083110c3fad046ccf0838a364150b8d2bab888</id>
<content type='text'>
</content>
</entry>
<entry>
<title>ime: render pre-edit text</title>
<updated>2020-12-07T19:44:10Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-12-02T17:52:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=8c3d48c5cdb2ae4e8bdbdc48f155f53d1a92973b'/>
<id>urn:sha1:8c3d48c5cdb2ae4e8bdbdc48f155f53d1a92973b</id>
<content type='text'>
This is done by allocating cells for the pre-edit text when receiving
the text-input::done() call, and populating them by converting the
utf-8 formatted pre-edit text to wchars.

We also convert the pre-edit cursor position to cell positions (it can
cover multiple cells).

When rendering, we simply render the pre-edit cells on-top off the
regular grid. While doing so, we also mark the underlying, “real”,
cells as dirty, to ensure they are re-rendered when the pre-edit text
is modified or removed.
</content>
</entry>
<entry>
<title>csi: add new private mode that makes the Escape key emit "\E[27;1;27~"</title>
<updated>2020-11-29T04:04:57Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2020-11-29T04:04:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=31c73f0cf01e1d0bdcd1435136b010c1c1ab442c'/>
<id>urn:sha1:31c73f0cf01e1d0bdcd1435136b010c1c1ab442c</id>
<content type='text'>
This mode can be set by client programs with the DECSET, DECRST,
XTSAVE and XTRESTORE sequences by using 27127 as the parameter.

The sequence "\E[27;1;27~" is encoded in the same way as is done by
xterm's "modifyOtherKeys" mode. Even though xterm itself never emits
such a sequence for the Escape key, many programs already have
support for parsing this style of key sequence.
</content>
</entry>
<entry>
<title>term: split cursor blink state into two</title>
<updated>2020-11-26T17:09:32Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-11-26T17:09:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=cb2f4962697ee62b9f6f403522e8a2ae7f213f9f'/>
<id>urn:sha1:cb2f4962697ee62b9f6f403522e8a2ae7f213f9f</id>
<content type='text'>
There are two different escape sequences that can be used to set the
cursor blink state: ‘CSI ? 12 h/l’ and ‘CSI Ps SP q’.

Up until now, they both modified the same internal state in foot. This
meant you could enable a blinking cursor with e.g. ‘CSI ? 12 h’ and
then disable it with ‘CSI 2 SP q’.

Since the ‘CSI ? 12’ escapes are used in the civis/cnorm/cvvis
terminfo entries, applications often ended up disabling the blink
state on exit (typically be emitting ‘cnorm’), requiring users to
manually re-enable blinking.

By splitting the internal state into two separate states, we can
improve the situation.

The cursor will blink if at least one of the two have been enabled.

The setting in foot.ini sets the default state of the ‘CSI Ps SP q’
escape.

This means if the user has enabled blinking in the configuration, the
cursor will blink regardless of civis/cnorm/cvvis. Which probably is
what the user wants.

If the user has NOT enabled blinking, civis/cnorm/cvvis act as
intended: cvvis blink, civis and cnorm do not.

If an application overrides the cursor blink/style with ‘CSI Ps SP q’,
that will override the user’s setting in foot.ini. But most likely
that too is intended (for example, the user may have configured the
application to use a different cursor style). And, a well written
application will emit the ‘Se’ terminfo sequence on exit, which in
foot is defined to ‘CSI SP q’, which will reset both the style and
blink state to the user configured style/state.

Closes #218
</content>
</entry>
<entry>
<title>term: remove read-only properties copied from the config</title>
<updated>2020-11-26T17:08:28Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-11-26T17:08:28Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=360cc8e6de8802015b3a4a744289c311beb8d82d'/>
<id>urn:sha1:360cc8e6de8802015b3a4a744289c311beb8d82d</id>
<content type='text'>
Use the config directly instead.
</content>
</entry>
<entry>
<title>term: place frequently accessed members first in term struct</title>
<updated>2020-11-24T19:55:41Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-11-24T19:55:41Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=22c354c8fd7f8bc7dbc9b27a2e2a3986666470f6'/>
<id>urn:sha1:22c354c8fd7f8bc7dbc9b27a2e2a3986666470f6</id>
<content type='text'>
To hopefully use the cache better.
</content>
</entry>
<entry>
<title>config: add ‘dpi-aware’ option, defaulting to enabled</title>
<updated>2020-11-19T18:25:48Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-11-17T16:59:31Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=8e7658a135ae05c790094f2b1b681c7f64f05cf0'/>
<id>urn:sha1:8e7658a135ae05c790094f2b1b681c7f64f05cf0</id>
<content type='text'>
When disabled, foot no longers uses outputs’ DPI to scale the
font. Instead, it uses the outputs’ scaling factor.

That is, instead of appending “:dpi=123” to the fontconfig string,
modify the “:pixelsize” or “:size” attribute.

Closes #206
</content>
</entry>
<entry>
<title>csi: implement “CSI ? 1035” - toggle Num Lock override</title>
<updated>2020-11-11T17:26:47Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-11-11T17:26:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=2382d6b4487cc9d599578034db8117eb3f1cc75f'/>
<id>urn:sha1:2382d6b4487cc9d599578034db8117eb3f1cc75f</id>
<content type='text'>
This adds a num_lock_modifier state to the terminal, and hooks up
“CSI?1035h/l” to toggle it.
</content>
</entry>
<entry>
<title>config: add font-bold, font-italic and font-bold-italic options</title>
<updated>2020-10-20T19:04:47Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-10-20T19:04:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=2c101a21ee6df096dadd60a77b4cb190f8503490'/>
<id>urn:sha1:2c101a21ee6df096dadd60a77b4cb190f8503490</id>
<content type='text'>
These options lets the user configure custom fonts and styles, to use
with the bold and italic cell attributes.

By default, they are unset, meaning we use the bold/italic variants of
the regular font.

Closes #169.
</content>
</entry>
<entry>
<title>wayland: properly restore window size when being un-tiled</title>
<updated>2020-10-20T18:58:03Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-10-20T18:58:03Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=f928c1fa682a3dd3728b290d8fa9de79a63538ed'/>
<id>urn:sha1:f928c1fa682a3dd3728b290d8fa9de79a63538ed</id>
<content type='text'>
Bind to xdg-shell version 2 if available, as this enables us to
track our window’s ‘tiled’ state in the ‘configure’ events.

This in turn allows us to stash the ‘old’ window size when being
tiled, to be used again when restoring the window size when un-tiled.
</content>
</entry>
<entry>
<title>term: remove unneeded blink.active field</title>
<updated>2020-10-13T17:28:05Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-10-13T17:28:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=1f650a7fdf9a7aa2088a303a7af77a2d05d73dd1'/>
<id>urn:sha1:1f650a7fdf9a7aa2088a303a7af77a2d05d73dd1</id>
<content type='text'>
We now use the timer FD instead; if it is -1, blinking is not active.
</content>
</entry>
<entry>
<title>Merge branch 'scroll-up-down-while-selecting' into master</title>
<updated>2020-10-12T18:20:26Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-10-12T18:20:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=d75e50230eb91b87bf6880177bd9fe32ab964140'/>
<id>urn:sha1:d75e50230eb91b87bf6880177bd9fe32ab964140</id>
<content type='text'>
Closes #149
</content>
</entry>
<entry>
<title>selection: auto-scroll: add SELECTION_SCROLL_NOT as a scroll ‘direction’</title>
<updated>2020-10-11T16:18:18Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-10-11T16:18:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=4ad7fdc19c386fada4e1f8401d6da95f2930c201'/>
<id>urn:sha1:4ad7fdc19c386fada4e1f8401d6da95f2930c201</id>
<content type='text'>
</content>
</entry>
<entry>
<title>csi: implement ‘CSI ? 1042 h/l’ - enable/disable bell-is-urgent</title>
<updated>2020-10-11T15:44:29Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2020-10-11T15:44:29Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=17761dce63100d287b62dda5bf2c49d5db5f2576'/>
<id>urn:sha1:17761dce63100d287b62dda5bf2c49d5db5f2576</id>
<content type='text'>
</content>
</entry>
</feed>
