Screen edge mouse gestures

I think the "move mouse to top/bottom/left/right edge of screen" triggers could be greatly improved by incorporating simple gestures into them.

I get a lot of use from the "move mouse to corner" triggers, as they are incredibly quick and easy to hit. Although the "move mouse to edge of screen" triggers are very accessible, I don't think they're very useful (at least not without using modifier keys) as hitting the screen edges through normal use is such a common thing in normal use, especially when using the dock and menu.

My suggestion for a set of new triggers is simple gestures that are begun when hitting the screen edge. For example, if using the right hand edge of the screen: Once the cursor hits the edge of the screen there are only three directions it can go – up, down, and left (away from the edge, which there is already a trigger available for). Here I am talking about making use of the up/down movements the mouse can make.

At its simplest, this gives us two new triggers per edge:

  1. Cursor hits the right edge and then moves up
  2. Cursor hits the right edge and then moves down

The two directions (eg up/down for the right edge) give two available triggers, eight in total for all four edges. But many more are available without things getting complicated. For example:

  1. Cursor hits right edge of screen, moves up (moving left again away from edge terminates the gesture)
  2. Cursor hits right edge of screen, moves up until hitting top corner
  3. Cursor hits right edge of screen, moves up and then down

This gives us three new triggers per direction per edge, 24 in total. These triggers would be very easy to activate as they don't require any mouse button or modifier key to be pressed, and unlike conventional mouse gestures, there would be little worry about accuracy of the gesture as it is only operating on one dimension of movement. These can be activated reliably and almost instantly with a slight flick of the wrist.

Logical conditions to be set to avoid accidental triggering would be:

  1. A minimum distance to be moved before the command is triggered (eg 100 pixels)
  2. Timeout (so the minimum distance would need to be crossed within eg 0.5 seconds)

In addition to this, consider that the screen corners could behave in the same way. For example, instead of just having "mouse moves to top right corner" as a trigger, there could also be "mouse moves to top right corner then moves left" and "mouse moves to top-right corner then moves down", giving eight new triggers in total.

What I have outlined here gives potentially dozens of new triggers, all very easily activated, and doesn't seem that different to the way BTT currently operates, given that there are already similar triggers available, such as "move mouse away from screen edge" or "move mouse away from corner". What I suggest seems like just a refinement to these existing triggers.

Sorry this was so long, I thought it best to explain the idea properly.

Thanks.

I don't see any triggers for left/right edge, only top/bottom and the screen corners. How are you accessing these?

Upon checking it seems you're correct. Perhaps there were options for left/right edges when I made that post a year ago which have since been deprecated, but most likely I just didn't notice that there were only options for top/bottom and not left/right edges when I was writing up my suggestion. It seems logical that all edges would be available so I guess I just made an assumption. Still, I wish there was some interest in this suggestion, using these gestures would be so quick and powerful. Oh well.

I think I just forgot these :slight_smile: will add them soon.

4 Likes

Great to hear this! :grinning_face_with_smiling_eyes: I'm looking forward to left/right edge triggers. It would solve my similar request: Trigger request: Move mouse to left/right edge

1 Like

Eagerly awaiting these triggers :grinning_face_with_smiling_eyes: I check every day for an update in hopes that they've been added. Please don't forget about them. :pray: Thanks!

1 Like

@Andreas_Hegenberg You've been releasing wonderful features and updates. :grinning: Any idea when you might be able to add the "move mouse to left/right edge of screen " triggers? Thank you.

2 Likes

Curious about the status of these requested triggers. It would be great to have these triggers for the left and right edge @Andreas_Hegenberg.

1 Like

Triggers for moving to the left and right edges, and for moving away from them, have been added in 4.030 alpha (currently uploading should be available in 10 minutes)

2 Likes

@Andreas_Hegenberg, thank you for adding these! I just installed 4.030 alpha and the new triggers are working. I'll continue to test it this week. :+1:

@Andreas_Hegenberg If possible, a delay would be useful to avoid accidentally triggering an action. Something like this.

@frank1 ah I forgot to activate that UI element. Should be available in 4.031 in a few minutes

2 Likes

By the way, a "delay and wait for.... action" that cancels a macro or continues it in another way if the "wait for" does not come, does not yet exist to my knowledge. Or am I wrong?

Anyway, that would be very useful ... at some point :slightly_smiling_face:

1 Like

Not as an action. It can be done using the Apple Script trigger_named_async_without_response and cancel_delayed_named_trigger_execution
functions provided by BTT though.

E.g.

tell application "BetterTouchTool"
trigger_named_async_without_response "TheNameOfTheNamedTrigger" delay 5
end tell

To cancel:

tell application "BetterTouchTool"
cancel_delayed_named_trigger_execution "TheNameOfTheNamedTrigger"
end tell
1 Like

Mmm, ok, but since I am not a coder and have no idea about Apple Scripts or any scripts I leave that to others :sweat_smile:

It's basically just replacing "TheNameOfTheNamedTrigger" with your named trigger name :wink:
But I'll add a UI for this at some point :slight_smile:

1 Like

Ah, wait it seems easier than I thought. Run "Named Trigger" 1 or 2 right? If nothing happens in 5 s?

@Andreas_Hegenberg Is it possible to have a slightly faster trigger response or is that too resource intensive?

I have the delay set to zero but the mouse pointer still has to exist at the screen edge for a moment longer than I'd like before triggering.

I'm trying to mimic macOS Hot Corners where I can whip the mouse to the screen edge and back without any pause.

Here's a quick screen recording that shows how quickly I'm trying to trigger an action using "Move Mouse To Left Edge Of Screen." You can see it works if I'm a tiny bit slower. I also have macOS Hot Corner enabled in the video for speed comparison.

(BTT v4.031, Apple M1 Max, Ventura 13.2.1)

I can add it as an option, but it does cause some extra CPU usage. Currently the mouse position is checked every 0.2 seconds I think

1 Like

I'd love the option and would be willing to sacrifice some CPU resources for faster response time. Thank you!

1 Like