Skip to content

Commit

Permalink
Support italic and strikethrough attribute (osa1#404)
Browse files Browse the repository at this point in the history
  • Loading branch information
nthnd committed Aug 3, 2023
1 parent aaac385 commit 889dcf5
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion crates/libtiny_tui/src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,12 @@ const COLORS: [(&str, u16); 17] = [
("white", 15),
];

const ATTRS: [(&str, u16); 2] = [("bold", TB_BOLD), ("underline", TB_UNDERLINE)];
const ATTRS: [(&str, u16); 4] = [
("bold", TB_BOLD),
("underline", TB_UNDERLINE),
("italic", TB_ITALIC),
("strikethrough", TB_STRIKETHROUGH),
];

fn parse_color(val: String) -> Option<u16> {
for &(name, color) in &COLORS {
Expand Down

0 comments on commit 889dcf5

Please sign in to comment.