diff options
| author | Michael Brown | 2022-03-14 23:38:24 +0100 |
|---|---|---|
| committer | Michael Brown | 2022-03-15 18:27:18 +0100 |
| commit | ba93c9134ce9d9edcba117b690fbbdd35b3e066b (patch) | |
| tree | 91e226e7af8ffda69ac68e16a7be03778128e4d0 /src/core/fbcon.c | |
| parent | [efi] Support Unicode character output via text console (diff) | |
| download | ipxe-ba93c9134ce9d9edcba117b690fbbdd35b3e066b.tar.gz ipxe-ba93c9134ce9d9edcba117b690fbbdd35b3e066b.tar.xz ipxe-ba93c9134ce9d9edcba117b690fbbdd35b3e066b.zip | |
[fbcon] Support Unicode character output
Accumulate UTF-8 characters in fbcon_putchar(), and require the frame
buffer console's .glyph() method to accept Unicode character values.
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/core/fbcon.c')
| -rw-r--r-- | src/core/fbcon.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/core/fbcon.c b/src/core/fbcon.c index 44a56e105..ff3132ac7 100644 --- a/src/core/fbcon.c +++ b/src/core/fbcon.c @@ -446,6 +446,11 @@ void fbcon_putchar ( struct fbcon *fbcon, int character ) { if ( character < 0 ) return; + /* Accumulate Unicode characters */ + character = utf8_accumulate ( &fbcon->utf8, character ); + if ( character == 0 ) + return; + /* Handle control characters */ switch ( character ) { case '\r': |
