]> git.ipfire.org Git - people/ms/network.git/commitdiff
Make fonts properly bold without changing the colour of the normal font
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 8 Sep 2016 12:49:09 +0000 (14:49 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 8 Sep 2016 12:49:09 +0000 (14:49 +0200)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/functions/functions.cli
src/functions/functions.colors

index 25d0b2a08241f6a557c67630a410597fbbe5b195..b5b164d75543c138b045450251b2c1e747918659 100644 (file)
@@ -250,7 +250,7 @@ cli_headline() {
        local ident=$(cli_ident ${level})
 
        local out
-       printf -v out "${ident}${CLR_WHITE_B}${format}${CLR_RESET}\n" "$@"
+       printf -v out "${ident}${FONT_BOLD}${format}${FONT_RESET}\n" "$@"
        printf "${out}"
 }
 
index 7f7e82110406ebc0a19bb1b977d1315dac2c09ff..8d7193c3abdd30b3eac0189fd306f8c7039b92d2 100644 (file)
@@ -49,8 +49,15 @@ CLR_PURPLE_BG='\e[45m'
 CLR_CYAN_BG='\e[46m'
 CLR_WHITE_BG='\e[47m'
 
-# Reset everything.
-CLR_RESET="\e[0m"
+# Font decoration
+FONT_RESET="\e[0m"
+FONT_BOLD="\e[1m"
+FONT_UNDERLINED="\e[4m"
+FONT_BLINKING="\e[5m"
+FONT_INVERTED="\e[7m"
+
+# Reset everything
+CLR_RESET="${FONT_RESET}"
 
 # Predefined messages
 MSG_HOOK_UP="${CLR_GREEN_BG}${CLR_WHITE_B}     UP     ${CLR_RESET}"