]> git.ipfire.org Git - thirdparty/plymouth.git/commit
wip! Add ply-terminal-buffer object plymouth-terminal-buffer
authorRay Strode <rstrode@redhat.com>
Fri, 5 May 2023 20:22:11 +0000 (16:22 -0400)
committerRay Strode <rstrode@redhat.com>
Fri, 5 May 2023 20:33:30 +0000 (16:33 -0400)
commit1559e1d78101d772b2fc57ee761aef8ce5595520
tree56bf710efc7b46fc99b93e38934071648af8e81b
parentfcaa382d535edb12461fbbc9942dc49b549d091b
wip! Add ply-terminal-buffer object

We're going to need to do at least basic parsing of terminal text
so we can show the console to the user in color when they hit
escape and VTs are disabled.

This commit adds the start of a class to do this basic parsing.

The way it works is the terminal text is inject into the object
and all escape sequences are filtered out. When a color control
sequence is found, the current color is noted, along with which
characters it applies to. A list of the text spans and their
color attributes is then iteratable using a an api.
src/libply-splash-core/meson.build
src/libply-splash-core/ply-terminal-buffer.c [new file with mode: 0644]
src/libply-splash-core/ply-terminal-buffer.h [new file with mode: 0644]