# "Windows-like" mouse behaviour

## orkid

To make life in X a bit easier for those switching from Windows, here is a tip (from googling) about making the mouse work more like a Windows mouse.

As root edit the /etc/X11/XF86Config file. Look for the 

```
Section "InputDevice"
```

 part of the file; mine looks like this: 

```
Section "InputDevice"

        Identifier  "Mouse0"

        Driver      "mouse"

        Option      "Protocol" "IMPS/2"

        Option      "Device" "/dev/psaux"

        Option      "Buttons" "5"

        Option      "ZAxisMapping" "4 5"

        Option      "Resolution"  "1200"

EndSection
```

Add the line Option "Resolution" "1200" before the EndSection to make your mouse work 'nicer'. You can play around with the value to get different mouse speeds.

Hope this helps someone!

----------

## delta407

Huh. I switched from Windows and never noticed a mouse motion issue; X seems more 'natural' for me. I dunno... maybe I'm just weird.  :Very Happy: 

----------

## AutoBot

A optical mouse is great under linux and is all I use, but I have used a roller mouse that does indeed need some tweaking for smooth movement.

----------

## ee99ee2

If you all are having trouble seeing any difference in it after you edit your XF86Config file, your X server may be using the XF86Config-4 file. Edit that one first, and see if anything changes. Probably, it'll use XF86Config-4 now'a days.

----------

## AutoBot

 *ee99ee2 wrote:*   

> If you all are having trouble seeing any difference in it after you edit your XF86Config file, your X server may be using the XF86Config-4 file. Edit that one first, and see if anything changes. Probably, it'll use XF86Config-4 now'a days.

 

Are you using gentoo ? Gentoo uses /etc/X11/XF86Config  :Wink: 

----------

## sa

hmmm..

man XF86Config

...

       XFree86  uses  a  configuration file called XF86Config for

       its initial setup.  This configuration  file  is  searched

       for  in the following places when the server is started as

       a normal user:

           /etc/X11/<cmdline>

           /usr/X11R6/etc/X11/<cmdline>

           /etc/X11/$XF86CONFIG

           /usr/X11R6/etc/X11/$XF86CONFIG

           /etc/X11/XF86Config-4

           /etc/X11/XF86Config

           /etc/XF86Config

           /usr/X11R6/etc/X11/XF86Config.<hostname>

           /usr/X11R6/etc/X11/XF86Config-4

           /usr/X11R6/etc/X11/XF86Config

           /usr/X11R6/lib/X11/XF86Config.<hostname>

           /usr/X11R6/lib/X11/XF86Config-4

           /usr/X11R6/lib/X11/XF86Config

....

----------

## wilbertnl

When I switched back to MS Windows (Once in a while I do that) I always noticed the nicer mouse response.

This tip gives me that same response to Linux, thank you for this little jewel of a tip!

----------

## virus

Being a hardcore bloods music Xpilot player (old 2D multiplayer shoot'em up) I've done lots of experimenting with mouse action... but mainly aiming to get perfect linear mousemovement. (better control)... fiddling with mouseres certainly can give results, but never really gave better ones for me. Mainly I use 'xset m 0 0' for linearity and I'm done =) (first number accel. and second is threshold, behavior varies)

But 'good' settings are highly dependant on the mouse... never had any luck with optical ones... too early highspeed mouseaction convolution for my gaming style =)

Getting good mouse movement in windows has so far proved impossible =)

----------

## Mallrats

Do I need to put the resolution right before end section?

Changing the resolution, whether to 2 or 300 or 714000 doesn't seem to have any effect on mouse speed

I'm using fluxbox

----------

## Mallrats

I kept messing with Resolution, but it doesn't seem to effect my mouse speed, it must be something else.  I'm using the IMPS/2 Protocol, does that make a difference?

----------

## virus

If u really want to tweak mouse speed I suggest using xset m <acceleration> <threshold>

example: 

```
xset m 3 1
```

in a terminal window and trying different combinations 'til u find somethng u like, then putting that command in ur ~/.xinitrc file (which may or may not exist)

I prefer 

```
xset m 2 1
```

----------

## Mallrats

Thanks for the tip, but I want to raise overall speed, not just acceleration

https://forums.gentoo.org/viewtopic.php?t=8398&highlight=speed+acceleration

Does anyone else have the problem of Resolution not doing anything?

----------

## Russki

 *Mallrats wrote:*   

> Thanks for the tip, but I want to raise overall speed, not just acceleration
> 
> https://forums.gentoo.org/viewtopic.php?t=8398&highlight=speed+acceleration
> 
> Does anyone else have the problem of Resolution not doing anything?

 

Wat do you expect from Resolution??

As I remember Resolution is a "sampling rate" of the mouse movement. It results in accuracy, not speed or acceleration

----------

## Mallrats

my bad   :Embarassed: 

So What exactly is resolution, and what raises my mouse speed?

----------

## Russki

 *Mallrats wrote:*   

> 
> 
> So What exactly is resolution,

 

Well, in XF86Config file they are tolking about resolution in DPI (dots per inch). And that is the most important factor in determining the smoothness and speed of a mouse. This is described by how many signals are sent when the mouse moves one inch. As the number of signals increases, mouse resolution becomes finer and the resulting motion smoother.  

But every mouse has it's limits, so "Option "Resolution" "1200"" might not work for you. For example:

 *AutoBot wrote:*   

> A optical mouse is great under linux and is all I use, but I have used a roller mouse that does indeed need some tweaking for smooth movement.

 

 An optical mouse has usually a higher resolution. (I use "1800" with my Logitech dual optical) Also USB has a greater "bandwidth" than PS/2.   

 *Mallrats wrote:*   

> 
> 
> and what raises my mouse speed?

 

The only way I know is this:

 *virus wrote:*   

> If u really want to tweak mouse speed I suggest using xset m <acceleration> <threshold>
> 
> example: 
> 
> ```
> ...

 

Success

----------

## Mallrats

"xset m # 1" does indeed raise my mouse speed

However I still get "jaggies" when I move the mouse (It looks like the mouse is climbing steps when I move diagonally

I tried to alleviate this my raising the resolution, but I've had no success with it

What should I be doing to fix the jagged motion?

----------

## Russki

Do you have a roller mouse? If so, your problem might be the dirty mechanical parts in your mouse. Try to clean it first.

----------

## Mallrats

no, it's optical

----------

## Malakin

 *Quote:*   

> Does anyone else have the problem of Resolution not doing anything?

 

Resolution and SampleRate only work on a few type of mice.

http://www.xfree86.org/4.2.1/mouse.4.html

----------

## BlackBart

 *AutoBot wrote:*   

>  *ee99ee2 wrote:*   If you all are having trouble seeing any difference in it after you edit your XF86Config file, your X server may be using the XF86Config-4 file. Edit that one first, and see if anything changes. Probably, it'll use XF86Config-4 now'a days. 
> 
> Are you using gentoo ? Gentoo uses /etc/X11/XF86Config 

 

'gentoo' dosn't use a certain XF86Config. It depends on how you set up your X server. (what program you use.) when X starts up it says what config file it is using. If you can't see it check in the X log.

----------

## Malakin

By default xfree86 4.x uses /etc/X11/XF86Config-4 if it exists, and if not then looks for /etc/X11/XF86Config

----------

## Uranus

I play a lot of Urban Terror... sometimes I play it on windows coz I'm already there programming or doing something else that explicitly needs windows, and I set my quake3's sensitivity to 9...

when I boot into linux, the sensitivity is way too high ... so I dropped it to 5.5 and set cl_mouse_accel to 0.2   ... it's beautiful! feels much smoother than windows now, and I aim WAYYYYY better  :Smile: 

----------

## Mallrats

 *Malakin wrote:*   

> Resolution and SampleRate only work on a few type of mice.

 

I know it's been a while.  If Resolution and SampleRate don't work for your mouse (they've never worked for any of the many mice I've tested), what can you do to emulate this speedup, short of the Acceleration settings

----------

## Przemek

 *virus wrote:*   

> Getting good mouse movement in windows has so far proved impossible =)

 

Turning off the accelerations completely requires some registry changes. I used a .reg file to tweak it for my ET.

It was SOME time ago and I can't remember where did I found it, but it is definitely possible.

----------

## steveL

 *Przemek wrote:*   

> It was SOME time ago..

 

Wow, so was this thread; that has to be the lengthiest zombie bump I've seen ;p

----------

