feat(hyprlock): decreased blink count
This commit is contained in:
@@ -37,16 +37,21 @@ let
|
||||
echo "$pos" > "$state_file"
|
||||
echo "''${text:0:$pos}_"
|
||||
else
|
||||
# Blink cursor via foreground color toggle
|
||||
# Blink cursor via foreground color toggle (slow blink)
|
||||
if [ ! -f "$blink_file" ]; then
|
||||
echo 0 > "$blink_file"
|
||||
echo "0 0" > "$blink_file"
|
||||
fi
|
||||
blink=$(cat "$blink_file")
|
||||
read -r blink count < "$blink_file"
|
||||
count=$((count + 1))
|
||||
# Toggle every 5 updates (~600ms at 120ms interval)
|
||||
if [ "$count" -ge 5 ]; then
|
||||
count=0
|
||||
blink=$((1 - blink))
|
||||
fi
|
||||
echo "$blink $count" > "$blink_file"
|
||||
if [ "$blink" -eq 0 ]; then
|
||||
echo 1 > "$blink_file"
|
||||
echo "''${text}_"
|
||||
else
|
||||
echo 0 > "$blink_file"
|
||||
echo "''${text}<span fgalpha=\"1\">_</span>"
|
||||
fi
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user