For English readers, please scroll down ⬇️
สคริปต์นี้ใช้สำหรับสลับระหว่างแป้นพิมพ์ภาษาอังกฤษ และภาษาไทย (และภาษาอื่นๆ) โดยใช้ปุ่ม grave/backquote (`)
-
ติดตั้งกฎ XKB และสัญลักษณ์สำหรับ
grp:grave_switch -
วางไฟล์ในไดเร็กทอรีระบบที่เหมาะสม:
rules/→/usr/share/X11/xkb/rules/symbols/→/usr/share/X11/xkb/symbols/
-
ทำงานได้ทั้งบน X11 และ Wayland ผ่าน libxkbcommon
- ระบบลินุกซ์ที่รองรับ X11 หรือ Wayland
- สิทธิ์ root (sudo) ในการคัดลอกไฟล์ไปยังไดเร็กทอรีระบบ
-
โคลนรีโพซิทอรี (repository)
git clone https://github.com/tackleza/linux-grave-key.git cd linux-grave-keyหรือดาวน์โหลดรีโพซิทอรีเป็นไฟล์ ZIP: ดาวน์โหลด ZIP
-
รันสคริปต์ติดตั้ง
chmod +x script.sh sudo ./script.sh
-
ออกจากระบบและเข้าสู่ระบบใหม่ หรือรีบูตเครื่อง เพื่อให้การตั้งค่ามีผล
เมื่อการติดตั้งเสร็จสิ้น โปรด Logout หรือ Reboot เครื่อง, หลังจากนั้นจะสามารถใช้ grave/backquote (`) เพื่อสลับภาษาได้
A simple script to install a custom XKB option that uses the grave/backquote key (`) to toggle keyboard layouts under X11 (and compatible with Wayland via libxkbcommon).
-
Installs custom XKB rules and symbols to enable
grp:grave_switchoption -
Places files in the proper system directories:
rules/→/usr/share/X11/xkb/rules/symbols/→/usr/share/X11/xkb/symbols/
-
Works out-of-the-box on X11 and is honored by Wayland compositors via libxkbcommon
- A Linux distribution with X11 and/or Wayland support
- Root (sudo) privileges to copy files into system directories
-
Clone the repository
git clone https://github.com/tackleza/linux-grave-key.git cd linux-grave-keyOr download the repository as a ZIP: Download ZIP
-
Run the install script
chmod +x script.sh sudo ./script.sh
-
Restart your session Log out and back in, or reboot your computer to apply the new layout switcher.
After installation and restarting your session, now you can use grave/backquote key (`) for switch the keyboard layout