From 002e8fb65e2ea1d0f3714bf192945734bca936d9 Mon Sep 17 00:00:00 2001 From: David Herrmann Date: Wed, 8 Aug 2012 11:27:19 +0200 Subject: [PATCH] text: move font_char_attr to text.h This way we can now remove all font.h includes. We can rename the structure later. Signed-off-by: David Herrmann --- src/console.c | 1 - src/console.h | 1 - src/terminal.c | 1 - src/text.c | 1 - src/text.h | 17 ++++++++++++++++- src/text_bblit.c | 1 - src/vte.c | 1 - 7 files changed, 16 insertions(+), 7 deletions(-) diff --git a/src/console.c b/src/console.c index c98152b..718afad 100644 --- a/src/console.c +++ b/src/console.c @@ -36,7 +36,6 @@ #include #include #include "console.h" -#include "font.h" #include "log.h" #include "text.h" #include "unicode.h" diff --git a/src/console.h b/src/console.h index e54dc3c..6c7d899 100644 --- a/src/console.h +++ b/src/console.h @@ -36,7 +36,6 @@ #include #include -#include "font.h" #include "text.h" #include "unicode.h" diff --git a/src/terminal.c b/src/terminal.c index 38321c7..a135365 100644 --- a/src/terminal.c +++ b/src/terminal.c @@ -36,7 +36,6 @@ #include "conf.h" #include "console.h" #include "eloop.h" -#include "font.h" #include "log.h" #include "pty.h" #include "static_misc.h" diff --git a/src/text.c b/src/text.c index 1a9bc60..177f3f1 100644 --- a/src/text.c +++ b/src/text.c @@ -35,7 +35,6 @@ #include #include #include -#include "font.h" #include "log.h" #include "static_misc.h" #include "text.h" diff --git a/src/text.h b/src/text.h index fccb877..86c56f2 100644 --- a/src/text.h +++ b/src/text.h @@ -39,10 +39,25 @@ #define KMSCON_TEXT_H #include -#include "font.h" #include "unicode.h" #include "uterm.h" +/* chars */ + +/* TODO: rename to kmscon_char_attr */ +struct font_char_attr { + uint8_t fr; /* foreground red */ + uint8_t fg; /* foreground green */ + uint8_t fb; /* foreground blue */ + uint8_t br; /* background red */ + uint8_t bg; /* background green */ + uint8_t bb; /* background blue */ + unsigned int bold : 1; /* bold character */ + unsigned int underline : 1; /* underlined character */ + unsigned int inverse : 1; /* inverse colors */ + unsigned int protect : 1; /* cannot be erased */ +}; + /* fonts */ struct kmscon_font_attr; diff --git a/src/text_bblit.c b/src/text_bblit.c index 18b492f..50ebb2c 100644 --- a/src/text_bblit.c +++ b/src/text_bblit.c @@ -36,7 +36,6 @@ #include #include #include -#include "font.h" #include "log.h" #include "static_misc.h" #include "text.h" diff --git a/src/vte.c b/src/vte.c index 2a01fe0..80ab6f8 100644 --- a/src/vte.c +++ b/src/vte.c @@ -55,7 +55,6 @@ #include #include "console.h" -#include "font.h" #include "log.h" #include "unicode.h" #include "vte.h"