Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

nomousy - Disable/Hide your mouse pointer [CMD]


  • Please log in to reply
67 replies to this topic
wrybread2
  • Guests
  • Last active:
  • Joined: --
Looking at that AHK code in the previous post, does it actually make the mouse invisible, or simply move it off screen?

A good example of where simply moving the mouse offscreen isn't sufficient is if you're running a kiosk with touchscreen and you want to let people click buttons but you don't want them to see a mouse pointer.

Nomousy does the job very nicely.

Laszlo
  • Moderators
  • 4713 posts
  • Last active: Mar 31 2012 03:17 AM
  • Joined: 14 Feb 2005

does it actually make the mouse invisible, or simply move it off screen?

It disables the mouse (freezes where it is), so the cursor has to be moved off screen beforehand.

This script has fewer features, it is not a replacement of Nomousy. More like a demo, what you can do with 10 lines of AHK code. If you just need to remove the mouse cursor, you can do it without an external program.

corrupt
  • Members
  • 2558 posts
  • Last active: Nov 01 2014 03:23 PM
  • Joined: 29 Dec 2004
I might release the source code for nomousy soon and/or release an AutoHotkey function with similar functionality. It's been a while though. I'll need to remember where I saved it first... :oops: There's not much to it though. Nomousy doesn't actually hide the cursor. It loads and uses a transparent cursor instead. A lot of the code in the last release is for parsing the command line params...

SKAN
  • Administrators
  • 9115 posts
  • Last active:
  • Joined: 26 Dec 2005

Nomousy doesn't actually hide the cursor. It loads and uses a transparent cursor instead.


:idea: :O :D

Laszlo
  • Moderators
  • 4713 posts
  • Last active: Mar 31 2012 03:17 AM
  • Joined: 14 Feb 2005

Nomousy doesn't actually hide the cursor. It loads and uses a transparent cursor instead.

So, do mouse clicks (on surprise spots) still work?

corrupt
  • Members
  • 2558 posts
  • Last active: Nov 01 2014 03:23 PM
  • Joined: 29 Dec 2004

Nomousy doesn't actually hide the cursor. It loads and uses a transparent cursor instead.

So, do mouse clicks (on surprise spots) still work?

Yes, mouse clicks should still work ok. I'm not sure what you mean by "surprise spots" though. Would you mind clarifying? The mouse should still have full movement and capabilities when only the hide option is used with nomousy (as far as I remember...).

Laszlo
  • Moderators
  • 4713 posts
  • Last active: Mar 31 2012 03:17 AM
  • Joined: 14 Feb 2005
If you move the invisible mouse, it lands in surprise spots. Clicking will be on unknown controls...

corrupt
  • Members
  • 2558 posts
  • Last active: Nov 01 2014 03:23 PM
  • Joined: 29 Dec 2004
Ahh, I understand. There are ways around that but it will depend on the application/reason for hiding the mouse. In the case of a touch screen the user will typically know where they are pointing when they touch the screen so that shouldn't be an issue for that type of application. Hotkeys can likely be used to prevent the user from clicking at certain locations, which could allow the screen to be mapped for valid/invalid click locations if necessary. If a touch screen isn't in use then nomousy's freeze option can be used. The freeze option will lock the mouse position within an area that is only a few pixels in size at its current location. This will avoid the possibility of having someone move the mouse and accidentally click on something while the mouse is hidden if the mouse is moved to a home/safe location before being hidden.

Laszlo
  • Moderators
  • 4713 posts
  • Last active: Mar 31 2012 03:17 AM
  • Joined: 14 Feb 2005
Here is an even simpler script then this one (which I also updated) to move the cursor off screen and back with Alt-Z (not for Win9x). Mouse clicks are still processed, as they were in the lower right corner.
!z::

   If (BlockMouse := !BlockMouse) {

      MouseMove 9999,9999,0

      BlockInput MouseMove

   } Else {

      BlockInput MouseMoveOff

      MouseMove -A_ScreenWidth/2,-A_ScreenHeight/2, 5, R

   }


wrybread2
  • Guests
  • Last active:
  • Joined: --
I'm trying to hide the mouse only on Monitor 2, is this possible with NoMousy?

In other words, is it possible to hide the mouse only if it's x position is, for example, greater than 1024?

This is useful if, for example, you have a touchscreen on monitor 2 and don't want to see the mouse pointer when people click.

corrupt
  • Members
  • 2558 posts
  • Last active: Nov 01 2014 03:23 PM
  • Joined: 29 Dec 2004

I'm trying to hide the mouse only on Monitor 2, is this possible with NoMousy?

In other words, is it possible to hide the mouse only if it's x position is, for example, greater than 1024?

This is useful if, for example, you have a touchscreen on monitor 2 and don't want to see the mouse pointer when people click.

Yes and no. There is currently an option for hiding specific cursors (for example, you could hide the I Beam cursor so that the cursor doesn't appear when typing in Notepad or in any other application that would display the I Beam cursor. Hiding other specific cursors is also possible) but an option doesn't currently exist to only hide when within a specific area. You could possibility add this functionality by keeping track of the position of the mouse and only hide if it leaves the area for monitor 2. I'll look into adding this functionality in a future version of nomousy though. Thanks for the suggestion :) .

corrupt
  • Members
  • 2558 posts
  • Last active: Nov 01 2014 03:23 PM
  • Joined: 29 Dec 2004

Here is an even simpler script then this one (which I also updated) to move the cursor off screen and back with Alt-Z (not for Win9x). Mouse clicks are still processed, as they were in the lower right corner.

!z::

   If (BlockMouse := !BlockMouse) {

      MouseMove 9999,9999,0

      BlockInput MouseMove

   } Else {

      BlockInput MouseMoveOff

      MouseMove -A_ScreenWidth/2,-A_ScreenHeight/2, 5, R

   }

Thanks for providing another possible alternative :) . While moving the mouse off-screen can be useful, I have always tried to avoid using this method as it seems likely to not function as expected on some machines (although likely a small number ATM) and seems very likely to fail or produce undesireable results in the future, since the method relies on moving the mouse to a non-existent (or at least non-visible) location.

Laszlo
  • Moderators
  • 4713 posts
  • Last active: Mar 31 2012 03:17 AM
  • Joined: 14 Feb 2005

While moving the mouse off-screen can be useful, I have always tried to avoid using this method as it seems likely to not function as expected on some machines

You are absolutely right. One can try the lower right corner, sacrificing a couple of pixels, but all these solutions have their limitations. One can try them, and if one works for a particular task, use it.

Leon
  • Members
  • 179 posts
  • Last active: May 22 2008 02:41 PM
  • Joined: 27 Aug 2007
Laszlo, the last script you put up is the closest I've found so far to what I'm trying to do. I'd like to change it a little for my needs.

I understand the hotkey and If/Else part and I've been able to use BlockInput before, but Idon't understand the rest.
I assume it uses functions coz I haven't even started on them in the help files yet.
If not could you point me in the right direction.

What i'd like is for the mouse movement incurred by unhiding (short dart to center of my 2nd monitor) to not be seen.

Laszlo
  • Moderators
  • 4713 posts
  • Last active: Mar 31 2012 03:17 AM
  • Joined: 14 Feb 2005
Sorry for the cryptic code. Here it is commented:
!z::                                ; Alt-Z hotkey, change to your liking
   If (BlockMouse := !BlockMouse) { ; Toggle the BlockMouse variable and check if it is TRUE or FALSE
      MouseMove 9999,9999,0         ; Move the cursor to the lower right corner (= A_ScreenWidth, A_ScreenHeight) 
      BlockInput MouseMove          ; Freeze the mouse cursor
   } Else {                         ; If unblock: 
      BlockInput MouseMoveOff       ; allow the mouse cursor to move
      MouseMove -A_ScreenWidth/2,-A_ScreenHeight/2, 5, R ; move it to the center of the screen
   }
If you want the mouse cursor to instantly appear, change the 5 in the last line to 0. Also, you can use other relative coordinates (R in the end of this line = relative movement). If you remove this line, the mouse becomes active in the lower right corner.