<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mirrors/foot.git/base64.c, branch 1.23.1</title>
<subtitle>A fast, lightweight and minimalistic Wayland terminal emulator</subtitle>
<id>https://git.0x0f.dev/mirrors/foot.git/atom?h=1.23.1</id>
<link rel='self' href='https://git.0x0f.dev/mirrors/foot.git/atom?h=1.23.1'/>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/'/>
<updated>2024-07-23T09:29:05Z</updated>
<entry>
<title>osc: kitty notifications: updated support for icons</title>
<updated>2024-07-23T09:29:05Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2024-07-23T09:29:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=ccb184ae645cd92a6e3aba429ab88a94a09bbf8c'/>
<id>urn:sha1:ccb184ae645cd92a6e3aba429ab88a94a09bbf8c</id>
<content type='text'>
This implements the suggested protocol discussed in
https://github.com/kovidgoyal/kitty/issues/7657.

Icons are handled by loading a cache. Both in-band PNG data, and
symbolic names are allowed.

Applications use a graphical ID to reference the icon both when
loading the cache, and when showing a notification.

* 'g' is the graphical ID
* 'n' is optional, and assigns a symbolic name to the icon
* 'p=icon' - the payload is icon PNG data. It needs to be base64
  encoded, but this is *not* implied. I.e. the application *must* use
  e=1 explicitly.

To load an icon (in-band PNG data):

    printf '\e]99;g=123:p=icon;&lt;base64-encoded-png-data&gt;\e\\'

or (symbolic name)

    printf '\e]99;g=123:n=firefox:p=icon;\e\\'

Of course, we can combine the two, assigning *both* a symbolic
name, *and* PNG data:

    printf '\e]99;g=123:n=firefox:p=icon;&lt;base64-encoded-png&gt;\e\\'

Then, to use the icon in a notification:

    printf '\e]99;g=123;this is a notification\e\\'

Foot also allows a *symbolic* icon to be defined and used at the same
time:

    printf '\e]99;g=123:n=firefox;this is a notification\e\\'

This obviously won't work with PNG data, since it uses the payload
portion of the escape sequence.
</content>
</entry>
<entry>
<title>base64: simplify lookup table initializer</title>
<updated>2024-03-17T15:27:22Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2024-03-17T15:27:22Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=5f41eb798b639774d5cb2a7656fbaf4c61a16352'/>
<id>urn:sha1:5f41eb798b639774d5cb2a7656fbaf4c61a16352</id>
<content type='text'>
</content>
</entry>
<entry>
<title>debug: rename assert() to xassert(), to avoid clashing with &lt;assert.h&gt;</title>
<updated>2021-01-16T20:16:00Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2021-01-16T20:16:00Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=e56136ce1192d04a52b01ccb41284f0b7896430e'/>
<id>urn:sha1:e56136ce1192d04a52b01ccb41284f0b7896430e</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Print stack trace on assert() failure or when calling fatal_error()</title>
<updated>2021-01-16T19:56:33Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2021-01-15T20:39:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=22f25a9e4feddbc093ae01cd53bdda3c2c3a82e9'/>
<id>urn:sha1:22f25a9e4feddbc093ae01cd53bdda3c2c3a82e9</id>
<content type='text'>
Note: this uses the __sanitizer_print_stack_trace() function from the
AddressSanitizer runtime, so it only works when AddressSanitizer is
in use.
</content>
</entry>
<entry>
<title>base64: only allow padding bytes at the end of a string when decoding</title>
<updated>2020-11-30T06:06:28Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2020-11-30T06:06:28Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=c66ad27cc8bab238d71dc3e1fca15c6a2665d49d'/>
<id>urn:sha1:c66ad27cc8bab238d71dc3e1fca15c6a2665d49d</id>
<content type='text'>
</content>
</entry>
<entry>
<title>base64: optimize error checking in base64_decode()</title>
<updated>2020-11-29T07:19:58Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2020-11-29T07:19:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=8d568143da42b3c7541b7b21552b69101edf4a36'/>
<id>urn:sha1:8d568143da42b3c7541b7b21552b69101edf4a36</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Convert most dynamic allocations to use functions from xmalloc.h</title>
<updated>2020-08-08T19:37:57Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2020-08-08T19:34:30Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=7a77958ba20c2b344be5e66e69e2f212a4bbf6b3'/>
<id>urn:sha1:7a77958ba20c2b344be5e66e69e2f212a4bbf6b3</id>
<content type='text'>
</content>
</entry>
<entry>
<title>base64: simplify is_valid() by using reverse_lookup table</title>
<updated>2020-08-08T02:55:23Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2020-08-08T02:55:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=745aeba382ffd0600a9f1e1ef1252d870b2295d5'/>
<id>urn:sha1:745aeba382ffd0600a9f1e1ef1252d870b2295d5</id>
<content type='text'>
</content>
</entry>
<entry>
<title>base64: implement encode()</title>
<updated>2019-07-19T12:19:42Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2019-07-19T12:19:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=9c3ccc182ef2eca08657ff2dc5bf0551c4ba26f7'/>
<id>urn:sha1:9c3ccc182ef2eca08657ff2dc5bf0551c4ba26f7</id>
<content type='text'>
</content>
</entry>
<entry>
<title>base64: initial base64 decode implementation</title>
<updated>2019-07-19T09:11:25Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2019-07-19T09:11:25Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=bb8a733758f1ca3137d2aef2665a05aa5b3859eb'/>
<id>urn:sha1:bb8a733758f1ca3137d2aef2665a05aa5b3859eb</id>
<content type='text'>
</content>
</entry>
</feed>
