summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xA.sh7
-rwxr-xr-xC.sh7
-rwxr-xr-xD.sh7
-rwxr-xr-xE.sh7
-rwxr-xr-xQ.sh7
-rw-r--r--S.sh7
-rwxr-xr-xW.sh7
-rwxr-xr-xX.sh7
-rwxr-xr-xZ.sh7
-rwxr-xr-xactivate-type-to-move-cursor.sh7
-rw-r--r--deactivate-type-to-move-cursor.sh7
-rw-r--r--xbindkeysrc.keyboard.is.mouse61
-rw-r--r--xbindkeysrc.keyboard.only10
13 files changed, 148 insertions, 0 deletions
diff --git a/A.sh b/A.sh
new file mode 100755
index 0000000..cd9fda2
--- /dev/null
+++ b/A.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+capslock_status=$(xset q | grep "Caps Lock:" | awk '{print $4}')
+if [ "$capslock_status" = "on" ]; then
+ xdotool mousemove_relative -- -45 0
+else
+ xdotool mousemove_relative -- -11 0
+fi
diff --git a/C.sh b/C.sh
new file mode 100755
index 0000000..c15b817
--- /dev/null
+++ b/C.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+capslock_status=$(xset q | grep "Caps Lock:" | awk '{print $4}')
+if [ "$capslock_status" = "on" ]; then
+ xdotool mousemove_relative -- 45 45
+else
+ xdotool mousemove_relative -- 11 11
+fi \ No newline at end of file
diff --git a/D.sh b/D.sh
new file mode 100755
index 0000000..a68bb32
--- /dev/null
+++ b/D.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+capslock_status=$(xset q | grep "Caps Lock:" | awk '{print $4}')
+if [ "$capslock_status" = "on" ]; then
+ xdotool mousemove_relative -- 45 0
+else
+ xdotool mousemove_relative -- 11 0
+fi \ No newline at end of file
diff --git a/E.sh b/E.sh
new file mode 100755
index 0000000..d747d2c
--- /dev/null
+++ b/E.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+capslock_status=$(xset q | grep "Caps Lock:" | awk '{print $4}')
+if [ "$capslock_status" = "on" ]; then
+ xdotool mousemove_relative -- 45 -45
+else
+ xdotool mousemove_relative -- 11 -11
+fi \ No newline at end of file
diff --git a/Q.sh b/Q.sh
new file mode 100755
index 0000000..c794ae5
--- /dev/null
+++ b/Q.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+capslock_status=$(xset q | grep "Caps Lock:" | awk '{print $4}')
+if [ "$capslock_status" = "on" ]; then
+ xdotool mousemove_relative -- -45 -45
+else
+ xdotool mousemove_relative -- -11 -11
+fi
diff --git a/S.sh b/S.sh
new file mode 100644
index 0000000..cb814ae
--- /dev/null
+++ b/S.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+capslock_status=$(xset q | grep "Caps Lock:" | awk '{print $4}')
+if [ "$capslock_status" = "on" ]; then
+ xdotool mousedown 2
+else
+ xdotool mouseup 2
+fi \ No newline at end of file
diff --git a/W.sh b/W.sh
new file mode 100755
index 0000000..5265846
--- /dev/null
+++ b/W.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+capslock_status=$(xset q | grep "Caps Lock:" | awk '{print $4}')
+if [ "$capslock_status" = "on" ]; then
+ xdotool mousemove_relative -- 0 -45
+else
+ xdotool mousemove_relative -- 0 -11
+fi \ No newline at end of file
diff --git a/X.sh b/X.sh
new file mode 100755
index 0000000..5f521a8
--- /dev/null
+++ b/X.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+capslock_status=$(xset q | grep "Caps Lock:" | awk '{print $4}')
+if [ "$capslock_status" = "on" ]; then
+ xdotool mousemove_relative -- 0 45
+else
+ xdotool mousemove_relative -- 0 11
+fi \ No newline at end of file
diff --git a/Z.sh b/Z.sh
new file mode 100755
index 0000000..18231ec
--- /dev/null
+++ b/Z.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+capslock_status=$(xset q | grep "Caps Lock:" | awk '{print $4}')
+if [ "$capslock_status" = "on" ]; then
+ xdotool mousemove_relative -- -32 32
+else
+ xdotool mousemove_relative -- -8 8
+fi
diff --git a/activate-type-to-move-cursor.sh b/activate-type-to-move-cursor.sh
new file mode 100755
index 0000000..26e36e4
--- /dev/null
+++ b/activate-type-to-move-cursor.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+
+pkill herbe
+killall xbindkeys
+cp /home/user/.type-to-move-cursor/xbindkeysrc.keyboard.is.mouse ~/.xbindkeysrc
+xbindkeys
+herbe 'Keyboard is mouse' \ No newline at end of file
diff --git a/deactivate-type-to-move-cursor.sh b/deactivate-type-to-move-cursor.sh
new file mode 100644
index 0000000..5a00ae0
--- /dev/null
+++ b/deactivate-type-to-move-cursor.sh
@@ -0,0 +1,7 @@
+#!/bin/dash
+
+pkill herbe
+killall xbindkeys
+cp /home/user/.type-to-move-cursor/xbindkeysrc.keyboard.only ~/.xbindkeysrc
+xbindkeys
+herbe 'Keyboard is keyboard' \ No newline at end of file
diff --git a/xbindkeysrc.keyboard.is.mouse b/xbindkeysrc.keyboard.is.mouse
new file mode 100644
index 0000000..37fbcfe
--- /dev/null
+++ b/xbindkeysrc.keyboard.is.mouse
@@ -0,0 +1,61 @@
+# IS MOUSE
+
+"xbindkeys_show"
+control+shift + g
+
+"dash /home/user/.type-to-move-cursor/deactivate-type-to-move-cursor.sh"
+Mod4 + 1
+
+"echo -n ''"
+Mod4 + 2
+
+"dash /home/user/.type-to-move-cursor/Q.sh"
+q
+
+"dash /home/user/.type-to-move-cursor/A.sh"
+a
+
+"dash /home/user/.type-to-move-cursor/Z.sh"
+z
+
+"dash /home/user/.type-to-move-cursor/X.sh"
+x
+
+"dash /home/user/.type-to-move-cursor/C.sh"
+c
+
+"dash /home/user/.type-to-move-cursor/D.sh"
+d
+
+"dash /home/user/.type-to-move-cursor/E.sh"
+e
+
+"dash /home/user/.type-to-move-cursor/W.sh"
+w
+
+# Asigna clic izquierdo a la tecla F
+"xdotool click 1"
+f
+
+# Asigna clic derecho a la tecla J
+"xdotool click 3"
+j
+
+# Asigna rueda hacia arriba a la tecla U
+"xdotool click --repeat 3 4"
+u
+
+# Asigna rueda hacia abajo a la tecla M
+"xdotool click --repeat 3 5"
+m
+
+"dash /home/user/.type-to-move-cursor/S.sh"
+s
+
+# Asigna Control + Rueda Arriba a Ctrl + U
+"( xdotool keydown Control && sleep 0.1s && xdotool keyup Control) & (xdotool click --repeat 3 4)"
+control+u
+
+# Asigna Control + Rueda Abajo a Ctrl + M
+"( xdotool keydown Control && sleep 0.1s && xdotool keyup Control) & (xdotool click --repeat 3 5)"
+control+m
diff --git a/xbindkeysrc.keyboard.only b/xbindkeysrc.keyboard.only
new file mode 100644
index 0000000..0ff79da
--- /dev/null
+++ b/xbindkeysrc.keyboard.only
@@ -0,0 +1,10 @@
+# IS NOT MOUSE
+
+"xbindkeys_show"
+ control+shift + q
+
+"echo -n ''"
+Mod4 + 1
+
+"dash ~/.type-to-move-cursor/activate-type-to-move-cursor.sh"
+ Mod4 + 2