== compares double quoted strings stringsJerry3904 wrote: Tue Nov 14, 2023 6:40 am Perfect, thanks. I had been using "On" and only switched to "1" in trying to fix it; but I never had the extra quote marks.
Is there any way to show a notification when Caps Lock is pressed?
Re: Is there any way to show a notification when Caps Lock is pressed?
Re: Is there any way to show a notification when Caps Lock is pressed?
hello fehlix and Jerry3904
Why ask for $key_caps_lock twice? is it necessary for translate On?
${if_match "${key_caps_lock}"=="On"}${color orange}${font :bold:size=14}caps LOCK is ON${color}$font${endif}
Why ask for $key_caps_lock twice? is it necessary for translate On?
${if_match "${key_caps_lock}"=="On"}${color orange}${font :bold:size=14}caps LOCK is ON${color}$font${endif}
Re: Is there any way to show a notification when Caps Lock is pressed?
It works that way if translation is not a problem. I was thinking of increasing the size too.
Production: 5.10, MX-23 Xfce, AMD FX-4130 Quad-Core, GeForce GT 630/PCIe/SSE2, 16 GB, SSD 120 GB, Data 1TB
Personal: Lenovo X1 Carbon with MX-23 Fluxbox
Other: Raspberry Pi 5 with MX-23 Xfce Raspberry Pi Respin
Personal: Lenovo X1 Carbon with MX-23 Fluxbox
Other: Raspberry Pi 5 with MX-23 Xfce Raspberry Pi Respin
Re: Is there any way to show a notification when Caps Lock is pressed?
This kind of works for both insert buttons, but without the on-off indicator - if they have been toggled to function as insert keys, i.e. maybe fn for delete/insert, and the number-lock for 0/insert key.
This does work correctly for Num Lock:
Complicated coding. 
Code: Select all
sh -c 'sleep 0.2; notify-send -t 5000 -i insert "Insert" $(xset -q | grep -oP "Insert:\s*\K(off|on)")'
Code: Select all
sh -c 'sleep 0.2; notify-send -t 5000 -i num-lock "Num Lock" $(xset -q | grep -oP "Num Lock:\s*\K(off|on)")'
