Re: problem with left-handed mouse on X - is GPM to blame or is it X?

2004-05-21 Thread Branden Robinson
On Mon, May 10, 2004 at 07:28:57PM -0400, Zephaniah E. Hull wrote:
 Please see the last message, where I covered just this.
 
 Raw mode repeats byte for byte, it does not attempt to do ANYTHING to
 them.
 
 In addition, he is repeating a PS2 protocol, with all the problems
 involved in that.
 
 I will say it once more, this is a case of user error.
 
 The proper configuration for this is having gpm not repeat, and both X
 and gpm reading from /dev/input/mice, with X doing some button
 remapping in whatever manner is now suggested.

Okay.  I checked the manpage for this information and did not find it.

I also found that the gpm(8) manpage is ugly.

So I did something about it.  Please see two attached files; one
is a diff which patches the manpage to simply document these two minor
points.  The other one overhauls the manpage completely.  I looked into
the source package, but the method used to generate both Texinfo and
Roff document source from a single file is truly grody.

 If 'xmodmap -e pointer = 3 2 1' is no longer the suggested means, what
 is?

That's a good question, and I don't have the answer at present.

-- 
G. Branden Robinson| You are not angry with people when
Debian GNU/Linux   | you laugh at them.  Humor teaches
[EMAIL PROTECTED] | them tolerance.
http://people.debian.org/~branden/ | -- W. Somerset Maugham
--- gpm.8~  2004-05-20 15:05:38.0 -0500
+++ gpm.8   2004-05-20 15:09:34.0 -0500
@@ -145,6 +145,10 @@
 normal sequence, `321' can be used by left-handed people,
 and `132' can be useful with two-button mice (especially within
 Emacs). All the button permutations are allowable.
+.IP
+.B Note:
+This option is ignored if the \(oq\-R\(cq option is used with the parameter
+\(oqraw\(cq.
 .TP
 -d \fIdelta\fP
 Set the delta value. When a single motion event
@@ -231,6 +235,9 @@
 an easy way to manage those stupid dual-mode mice which force you
 to keep the middle button down while changing video mode. The option
 is forced on by the `-M' option.
+.IP
+.B Note: The only repeat type reliably supported by version 4.3 or later of
+.B the XFree86 X server is \(oqms3\(cq.
 .TP
 -s \fInumber\fP
 Set the sample rate for the mouse device.
.TH gpm 8 20 May 2004 GPM General Purpose Mouse 1.19.6
.SH NAME
gpm \- cut\-and\-paste utility and mouse server for virtual consoles
.SH SYNOPSIS
.B gpm
[
.I options
]
.br
.SH DESCRIPTION
GPM (General Purpose Mouse) tries to be a useful mouse server for
applications running on the Linux console.  The information below is
extracted from the Texinfo documentation, which is the preferred source of
information.
.PP
GPM makes it easy to select and copy regions of text on the virtual
console, much as is done in graphical programs such as word processors.
Text regions are highlighted with the mouse in an area called the
\(oqselection buffer\(cq, or just \(oqselection\(cq.  The term
\(oqcut\-and\-paste\(cq can be a little misleading, because GPM never
deletes text from the console.  GPM is actually more of a
.RI \(oq copy \-and\-paste\(cq
utility.
.PP
The
.B gpm
executable is meant to act like a daemon (thus, \(oqgpmd\(cq would be a
better name for it).
.SS Operation
To select text press and hold the left mouse button and drag the mouse.
.PP
On three\-button mice, click the middle button to paste text in the same or
another console.  The right button is used to extend the selection, like in
.BR xterm (1x).
.PP
Two\-button mice use the right button to paste text.
.PP
Double\- and triple\-clicks of the left button select whole words and
whole lines.  Use of the
.B \-p
option is recommended for best visual feedback.  Which characters
constitute part of a \(oqword\(cq can be changed with the
.B \-l
option.
.PP
If a trailing space after the visible content of a line is highlighted, and
if there is no other text on the remainder of the line, the rest of the
line will be selected automatically.  If a number of lines are selected,
highlighted trailing spaces on each line will be removed from the selection
buffer.
.PP
Any output on the virtual console holding the selection will clear the
highlighted selection from the screen, to maintain integrity of the
display, although the contents of the selection buffer will be unaffected.
.PP
The selection mechanism is disabled if the controlling virtual console is
placed in graphics mode (for example when running an X server), and is
re\-enabled when text mode is resumed \(em but see the \(oqBUGS\(cq section
below.
.SS Special Commands
GPM has the ability to execute special commands via mouse actions under
certain circumstances.  The special commands default to rebooting and
halting the system, but the user can specify his or her personal choice.
The ability to invoke commands using only the mouse can be a handy one,
because it allows you to shut the system down cleanly when the keyboard is
locked and no network is available to restore the system to a sane 

Re: problem with left-handed mouse on X - is GPM to blame or is it X?

2004-05-10 Thread Branden Robinson
On Fri, Apr 30, 2004 at 10:14:32AM +0300, Martin-Éric Racine wrote:
 1) The information about using GPM's -B option is incorrect.  As you can see
 from the enclosed configs, I already use -B 321, but this is ignored by X.

Zeph, can you comment on this?

Is -B 321 really broken, or only broken for the raw repeat type?  I
think I can imagine why it might not work for the raw repeat type.

 2) xmodmap has been broken since XFree 4.3.0.  Any xmodmap receipe I had left
 from 4.2.1 either results in broken keyboard maps or in is simply ignored.

This is because the XKB configuration data has been overhauled.

xmodmap has been deprecated for years.

 Honnestly, the correct action would be for X to follow the button order
 configured for GPM.  I really wonder why that fails.

If you use the raw repeat type, there may be no way it *can* work.

Zeph, can you help clear up this issue?

-- 
G. Branden Robinson|It was a typical net.exercise -- a
Debian GNU/Linux   |screaming mob pounding on a greasy
[EMAIL PROTECTED] |spot on the pavement, where used to
http://people.debian.org/~branden/ |lie the carcass of a dead horse.


signature.asc
Description: Digital signature


Re: problem with left-handed mouse on X - is GPM to blame or is it X?

2004-05-10 Thread Zephaniah E. Hull
On Mon, May 10, 2004 at 04:10:18PM -0500, Branden Robinson wrote:
 On Fri, Apr 30, 2004 at 10:14:32AM +0300, Martin-?ric Racine wrote:
  1) The information about using GPM's -B option is incorrect.  As you can see
  from the enclosed configs, I already use -B 321, but this is ignored by X.
 
 Zeph, can you comment on this?
 
 Is -B 321 really broken, or only broken for the raw repeat type?  I
 think I can imagine why it might not work for the raw repeat type.

  Honnestly, the correct action would be for X to follow the button order
  configured for GPM.  I really wonder why that fails.
 
 If you use the raw repeat type, there may be no way it *can* work.
 
 Zeph, can you help clear up this issue?

Please see the last message, where I covered just this.

Raw mode repeats byte for byte, it does not attempt to do ANYTHING to
them.

In addition, he is repeating a PS2 protocol, with all the problems
involved in that.

I will say it once more, this is a case of user error.

The proper configuration for this is having gpm not repeat, and both X
and gpm reading from /dev/input/mice, with X doing some button
remapping in whatever manner is now suggested.

If 'xmodmap -e pointer = 3 2 1' is no longer the suggested means, what
is?

-- 
1024D/E65A7801 Zephaniah E. Hull [EMAIL PROTECTED]
   92ED 94E4 B1E6 3624 226D  5727 4453 008B E65A 7801
CCs of replies from mailing lists are requested.

Mercury Knghtbrd: Eww, find a better name, the movie sucked.. G
Knghtbrd Mercury: The engine is better than the movie



Re: problem with left-handed mouse on X - is GPM to blame or is it X?

2004-04-30 Thread Branden Robinson
[Zeph Hull dropped from Cc.]

On Thu, Apr 29, 2004 at 12:29:35PM +0300, Martin-Éric Racine wrote:
 Greetings,
 
 Given how everyone in this family is left-handed, I recently got around
 inverting the order of the mouse buttons in GPM; works great in console.  
 
 Since GPM is setup as a repeater for X, I thought that X would also end up
 defaulting to inverted button order, but it doesn't.
 
 I haven't found any option in X to configure the button order and Googling
 didn't tell me anything relevant about perhaps selecting a different protocol 
 in
 GPM to get everything working in X the same way it does on console.
 
 Would anybody happen to have a cure for this?

There is information in the Debian X FAQ about this.

/usr/share/doc/xfree86-common/FAQ.gz

http://necrotic.deadbeast.net/xsf/XFree86/trunk/debian/local/FAQ

Please let us know if it is insufficient.

-- 
G. Branden Robinson|Religion consists in a set of
Debian GNU/Linux   |things which the average man thinks
[EMAIL PROTECTED] |he believes and wishes he was
http://people.debian.org/~branden/ |certain of.   -- Mark Twain


signature.asc
Description: Digital signature


Re: problem with left-handed mouse on X - is GPM to blame or is it X?

2004-04-30 Thread Zephaniah E. Hull
On Thu, Apr 29, 2004 at 12:29:35PM +0300, Martin-?ric Racine wrote:
 Greetings,
 
 Given how everyone in this family is left-handed, I recently got around
 inverting the order of the mouse buttons in GPM; works great in console.  
 
 Since GPM is setup as a repeater for X, I thought that X would also end up
 defaulting to inverted button order, but it doesn't.
 
 repeat_type=raw
 type=imps2

 Section InputDevice
 Option  Device/dev/gpmdata
 Option  Protocol  ImPS/2
 EndSection

impolite rant removed

This is user error.

The raw repeat type is something that I am beginning to think is more of
a bug then a feature, it does a byte for byte repeat, making no changes
to the byte stream.

Further more, it seems to be most commonly used with the PS/2 protocols,
which, is another rant about two-way communications on a FIFO.

Kill the repeat type, have X read from /dev/input/mice as well, and use
xmodmap in your ~/.xsession.

-- 
1024D/E65A7801 Zephaniah E. Hull [EMAIL PROTECTED]
   92ED 94E4 B1E6 3624 226D  5727 4453 008B E65A 7801
CCs of replies from mailing lists are requested.

VOICE MODE=Pitr
So, you are thinking am Communist ? Deal, Comerade !
/VOICE
  -- Chris on ASR.


signature.asc
Description: Digital signature


problem with left-handed mouse on X - is GPM to blame or is it X?

2004-04-29 Thread Martin-Éric Racine
Greetings,

Given how everyone in this family is left-handed, I recently got around
inverting the order of the mouse buttons in GPM; works great in console.  

Since GPM is setup as a repeater for X, I thought that X would also end up
defaulting to inverted button order, but it doesn't.

I haven't found any option in X to configure the button order and Googling
didn't tell me anything relevant about perhaps selecting a different protocol in
GPM to get everything working in X the same way it does on console.

Would anybody happen to have a cure for this?

Thanks!

-
#  /etc/gpm.conf - configuration file for gpm(1)
#
device=/dev/input/mice
responsiveness=15
repeat_type=raw
type=imps2
append=-B 321
sample_rate=
-

-
# /etc/X11/XF86Config-4
Section InputDevice
Identifier  Configured Mouse
Driver  mouse
Option  CorePointer
Option  Device/dev/gpmdata
Option  Protocol  ImPS/2
Option  Emulate3Buttons   true
Option  ZAxisMapping  4 5
EndSection
-

-- 
Martin-Éric Racine, ICT Consultant
http://www.pp.fishpool.fi/~q-funk/