Disable on screen keyboard permanently.
#11
(02-15-2022, 11:48 AM)Zebulon Walton Wrote:
(02-15-2022, 08:05 AM)wibble Wrote: Based on the script on the wiki page I guess something like this should work as the basis for a script which you could then add a .desktop file for:

if [ $(gsettings get org.gnome.desktop.a11y.applications screen-keyboard-enabled) = "true" ]; then  gsettings set org.gnome.desktop.a11y.applications screen-keyboard-enabled false; else  gsettings set org.gnome.desktop.a11y.applications screen-keyboard-enabled true; fi

Thanks, that works great!

What I did was use that in a shell script ~/bin/keybd, that displays the result before exiting:

Code:
#!/bin/bash

if [ $(gsettings get org.gnome.desktop.a11y.applications screen-keyboard-enabled) = "true" ]; then gsettings set org.gnome.desktop.a11y.applications screen-keyboard-enabled false; else gsettings set org.gnome.desktop.a11y.applications screen-keyboard-enabled true; fi

echo ""
echo ""
echo ""
echo =====================================================""
echo "Toggling on-screen keyboard..."
echo "Keyboard is now: $(gsettings get org.gnome.desktop.a11y.applications screen-keyboard-enabled)"
echo =====================================================""

sleep 2

I installed xterm since I found that unlike King's Cross the xterm window closes completely after it exits (no need to swipe up).

Code:
sudo apt install xterm

Then I created the desktop file in ~/.local/share/applications/keybd_toggle.desktop:

Code:
[Desktop Entry]
Name=04 Toggle Keybd
Type=Application
Icon=input-keyboard.png
Exec=/usr/bin/xterm -fg white -bg black -e /home/mobian/bin/keybd
Categories=Utility;
X-Purism-FormFactor=Workstation;Mobile;

This makes for a very quick way to toggle the onscreen keyboard. (The reason for the number "04" in the name is to put this near the top of the screen. I have my most frequently used icons named that way, currently prefixed 00 through 04.)

Thanks for showing your work. I used it as a basis for my own and incorporated both turning the software keyboard off and changing the charging limits for use with the keyboard case.

echo -n 1500000 | sudo tee /sys/class/power_supply/axp20x-usb/input_current_limit

A side note, you can close force close kgx with "kill $PPID" at the end of the script.

Wish I could get around having to enter my password for the sudo part though
  Reply
#12
(06-08-2022, 08:25 PM)SwordfishII Wrote: echo -n 1500000 | sudo tee /sys/class/power_supply/axp20x-usb/input_current_limit

A side note, you can close force close kgx with "kill $PPID" at the end of the script.

Wish I could get around having to enter my password for the sudo part though

Check the NOPASSWD option in /etc/sudoers - you can use it to allow specific commands to be run without requiring the password. Something like:

Code:
your_user_name ALL=(ALL) NOPASSWD:/usr/bin/tee /sys/class/power_supply/axp20x-usb/input_current_limit,some_other_command_you_want
  Reply
#13
(06-09-2022, 04:47 AM)wibble Wrote:
(06-08-2022, 08:25 PM)SwordfishII Wrote: echo -n 1500000 | sudo tee /sys/class/power_supply/axp20x-usb/input_current_limit

A side note, you can close force close kgx with "kill $PPID" at the end of the script.

Wish I could get around having to enter my password for the sudo part though

Check the NOPASSWD option in /etc/sudoers - you can use it to allow specific commands to be run without requiring the password. Something like:

Code:
your_user_name ALL=(ALL) NOPASSWD:/usr/bin/tee /sys/class/power_supply/axp20x-usb/input_current_limit,some_other_command_you_want

That is exactly what I did the other day! It was quite handy
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  New keyboard issue sandspur 13 554 06-24-2022, 11:59 AM
Last Post: zltpxqhp69o2
  Disable vibrations 3x5co 8 3,501 06-11-2022, 09:59 AM
Last Post: iwakura_lain
  Disable *automatic* on-screen keyboard iwakura_lain 0 71 06-11-2022, 09:49 AM
Last Post: iwakura_lain
  Mobian virtual keyboard suddenly buggy HLing 1 264 04-22-2022, 01:21 PM
Last Post: HLing
  lost settings icon from screen kubussz 3 654 02-17-2022, 09:26 AM
Last Post: beretta
  Keyboard function keys F1-F10 vgnmnky 0 333 02-05-2022, 08:59 PM
Last Post: vgnmnky
  Screen/display gets switched on by itself / Phone wakes up from suspend Anna 5 1,182 01-04-2022, 01:24 PM
Last Post: pothos
  Screen now turning off (and on) after a few seconds 3x5co 3 1,048 10-24-2021, 09:27 AM
Last Post: 3x5co
  Sizing apps to fit to screen county93 4 1,448 10-23-2021, 11:36 PM
Last Post: bcnaz
  GDM3 Receiving call on login screen d-.-b 4 1,398 10-07-2021, 06:59 PM
Last Post: d-.-b

Forum Jump:


Users browsing this thread: 1 Guest(s)