-
-
Notifications
You must be signed in to change notification settings - Fork 610
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: improve transparent background
- Loading branch information
Showing
3 changed files
with
85 additions
and
79 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,68 +1,60 @@ | ||
#!/bin/sh | ||
|
||
build_status_module() { | ||
local index=$1 | ||
local icon=$2 | ||
local color=$3 | ||
local text=$4 | ||
local index="$1" | ||
local icon="$2" | ||
local color="$3" | ||
local text="$4" | ||
|
||
if [ "$status_fill" = "icon" ] | ||
then | ||
if [ "$status_fill" = "icon" ]; then | ||
local show_left_separator="#[fg=$color,bg=$thm_gray,nobold,nounderscore,noitalics]$status_left_separator" | ||
|
||
local show_icon="#[fg=$thm_bg,bg=$color,nobold,nounderscore,noitalics]$icon " | ||
local show_text="#[fg=$thm_fg,bg=$thm_gray] $text" | ||
|
||
local show_right_separator="#[fg=$thm_gray,bg=$thm_bg,nobold,nounderscore,noitalics]$status_right_separator" | ||
|
||
if [ "$status_connect_separator" = "yes" ] | ||
then | ||
if [ "$status_connect_separator" = "yes" ]; then | ||
local show_left_separator="#[fg=$color,bg=$thm_gray,nobold,nounderscore,noitalics]$status_left_separator" | ||
local show_right_separator="#[fg=$thm_gray,bg=$thm_gray,nobold,nounderscore,noitalics]$status_right_separator" | ||
|
||
else | ||
local show_left_separator="#[fg=$color,bg=$thm_bg,nobold,nounderscore,noitalics]$status_left_separator" | ||
local show_right_separator="#[fg=$thm_gray,bg=$thm_bg,nobold,nounderscore,noitalics]$status_right_separator" | ||
local show_left_separator="#[fg=$color,bg=default,nobold,nounderscore,noitalics]$status_left_separator" | ||
local show_right_separator="#[fg=$thm_gray,bg=default,nobold,nounderscore,noitalics]$status_right_separator" | ||
fi | ||
|
||
fi | ||
|
||
if [ "$status_fill" = "all" ] | ||
then | ||
if [ "$status_fill" = "all" ]; then | ||
local show_left_separator="#[fg=$color,bg=$thm_gray,nobold,nounderscore,noitalics]$status_left_separator" | ||
|
||
local show_icon="#[fg=$thm_bg,bg=$color,nobold,nounderscore,noitalics]$icon " | ||
local show_text="#[fg=$thm_bg,bg=$color]$text" | ||
|
||
local show_right_separator="#[fg=$color,bg=$thm_gray,nobold,nounderscore,noitalics]$status_right_separator" | ||
|
||
if [ "$status_connect_separator" = "yes" ] | ||
then | ||
if [ "$status_connect_separator" = "yes" ]; then | ||
local show_left_separator="#[fg=$color,nobold,nounderscore,noitalics]$status_left_separator" | ||
local show_right_separator="#[fg=$color,bg=$color,nobold,nounderscore,noitalics]$status_right_separator" | ||
|
||
else | ||
local show_left_separator="#[fg=$color,bg=$thm_bg,nobold,nounderscore,noitalics]$status_left_separator" | ||
local show_right_separator="#[fg=$color,bg=$thm_bg,nobold,nounderscore,noitalics]$status_right_separator" | ||
local show_left_separator="#[fg=$color,bg=default,nobold,nounderscore,noitalics]$status_left_separator" | ||
local show_right_separator="#[fg=$color,bg=default,nobold,nounderscore,noitalics]$status_right_separator" | ||
fi | ||
|
||
fi | ||
|
||
if [ "$status_right_separator_inverse" = "yes" ] | ||
then | ||
if [ "$status_connect_separator" = "yes" ] | ||
then | ||
if [ "$status_right_separator_inverse" = "yes" ]; then | ||
if [ "$status_connect_separator" = "yes" ]; then | ||
local show_right_separator="#[fg=$thm_gray,bg=$color,nobold,nounderscore,noitalics]$status_right_separator" | ||
else | ||
local show_right_separator="#[fg=$thm_bg,bg=$color,nobold,nounderscore,noitalics]$status_right_separator" | ||
local show_right_separator="#[fg=$thm_bg,bg=default,nobold,nounderscore,noitalics]$status_right_separator" | ||
fi | ||
fi | ||
|
||
if [ $(($index)) -eq 0 ] | ||
then | ||
local show_left_separator="#[fg=$color,bg=$thm_bg,nobold,nounderscore,noitalics]$status_left_separator" | ||
if [ $(($index)) -eq 0 ]; then | ||
local show_left_separator="#[fg=$color,bg=default,nobold,nounderscore,noitalics]$status_left_separator" | ||
fi | ||
|
||
echo "$show_left_separator$show_icon$show_text$show_right_separator" | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters