fix subsep fg in right prompt

pull/145/head
romkatv 5 years ago
parent 0ad3a452ef
commit 13ce831b6b

@ -447,16 +447,7 @@ right_prompt_segment() {
local t=$#_P9K_T
_P9K_T+=$start_sep$style$left_space # 1
_P9K_T+=$w$style # 2
if [[ -n $fg_color && $fg_color == $bg_color ]]; then
if [[ $fg_color == $DEFAULT_COLOR ]]; then
_p9k_foreground $DEFAULT_COLOR_INVERTED
else
_p9k_foreground $DEFAULT_COLOR
fi
_P9K_T+=$w$_P9K_RETVAL$subsep$style$left_space # 3
else
_P9K_T+=$w$fg$subsep$style$left_space # 3
fi
_P9K_T+=$w$subsep$style$left_space # 3
_P9K_T+=$w%F{$bg_color}$sep$style$left_space # 4
local join="_P9K_I>=$_P9K_RIGHT_JOIN[$2]"
@ -520,7 +511,17 @@ right_prompt_segment() {
_p9k_escape $_P9K_RETVAL
p+=$_P9K_RETVAL
p+="\${\${_P9K_W::=${right_space_:+$style_}$right_space_%b$bg_}+}"
if [[ -n $fg_color && $fg_color == $bg_color ]]; then
if [[ $fg_color == $DEFAULT_COLOR ]]; then
_p9k_foreground $DEFAULT_COLOR_INVERTED
else
_p9k_foreground $DEFAULT_COLOR
fi
else
_P9K_RETVAL=$fg
fi
_p9k_escape_rcurly $_P9K_RETVAL
p+="\${\${_P9K_W::=${right_space_:+$style_}$right_space_%b$bg_$_P9K_RETVAL}+}"
if (( _P9K_EMULATE_ZERO_RPROMPT_INDENT )); then
p+="\${\${_P9K_SSS::=$bg_%E}+}"

Loading…
Cancel
Save