l i n u x - u s e r s - g r o u p - o f - d a v i s
L U G O D
 
Next Meeting:
August 5: Social gathering
Next Installfest:
TBD
Latest News:
Jul. 4: July, August and September: Security, Photography and Programming for Kids
Page last updated:
2001 Dec 30 17:07

The following is an archive of a post made to our 'vox-tech mailing list' by one of its subscribers.

Report this post as spam:

(Enter your email address)
Re: [vox-tech] help mapping mouse 1 click to the windows key
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [vox-tech] help mapping mouse 1 click to the windows key



Summary of this message:

         There is a console based copy and paste system that I have used
for many years (over a decade? almost 2 decades? dang, that is a long
time.)
         Have not researched much in the way of mapping the different
mouse button functions to a key, but offer some suggestions for your own
research.

On Tue, 31 Jul 2001, Peter Jay Salzman wrote:
> when replying to spam, i usually do a lot of cut and pasting from output of
> whois to mutt.  my life would be much better if my hands didn't have to move
> from the keyboard.

> is there a way of generating a mouse 1 click using the windows key?

Probably, have not examined it in much detail, but...

...do you use screen? Screen is an awesome tool for console users -
especially when remote or know you will change locations while in a
project being processed/compiled/used.

(For those that dont know about screen:
It allows you to set up one tty/session to have control to 10 session
(more are possible but require more work) and you can choose screen based
commands to copy and paste from one session in that screen session to
another session within the same screen session.)

screen allows for switching to 10 virtual sessions.

(mini tour of screen:)

After installing screen fire up an xterm, or go to a console. At the shell
prompt type "screen" and you may see a bunch of text about the author etc.
Press return.

Now you have a shell much like any other shell, except that control-a
allows you to access "Screen" commands.

control-a c   (spawn a new shell and console-like tty)
control-a 0   (jump to the screen/tty called number zero)
control-a 1   (jump to the new screen/tty spawned in the first step)

Many more commands exist for it too, including one to copy and paste
within the screen session. :-)

Screen also has a scroll back buffer (kind of like the ones on many linux
distro consoles with the PgUp, but controlled by a screen sequence.) The
buffer may be extended at the cost of memory used for each new shell, but
that should be obvious.

control-a 0  (jump back to screen 0)
from there, run mail or lynx or whois or whatever....
control-a 1  (jump back to screen 1)
Run something else that may produce text you might want to copy

control-a [ESC]  (now in copy mode)
use the vi keys (h,j,k,l) to move around the copy cursor until you get the
the beginning or end of the text you want to copy.
(You can even scroll back beyond the top of the screen if text "flew" by
in the output of something while in the copy mode)
press [SPACE] and then you have chosen a start spot.
use the vi move keys (h,j,k,l) to move the high-lighted area  from the
start/end point the other end of what you want copied.
press [SPACE] again and that text has been copied into the screen buffer.

Now, from any screen session, you should be able to 
control-a [   (paste the contents of the screen buffer into the present
active session)

In addition to the cool features of multiple shell sessions from one
shell, and copy/paste between them, you have the very, very cool feature
of being able to start something in many of these sessions under screen
then *detach* screen (control-a d) and then log out, move to a new
location, log back in to a shell, and then (screen -r) resume where you
left off.

Ever try to compile a huge project and know it may take longer than ytou
expect, and need to leave the lab, or work machine? if you ran screen
before starting, you can contrinue where you left off at the new location.

screen is one of those tools/applications I compile or install on a new
machine - even before bash, less, or others but after gcc if there is no
"secure" packaged screen available.

(screen was even more useful over dialup as you could contrinue a session
even when the modem was disconnected and be exactly where you were when
you left - well, except for a bit of occasional line noise left on the
other end. :-)

I feel that learning how to use screen should follow right after learning
your editor (vi or emacs). It makes learning how to use other tools much
easier with switching between man pages and a command line, or looking at
output vs source code, or web browsing in lynx while mail is still open or
whatever...

need to send a "real" control-a while in screen? then aontrol-a a

See the man page for screen for more useful command/functions.

(If you get trouble with it not knowing about a TERM of "screen" you can
export your TERM variable with your actual terminal type or if in csh
setenv etc.)

-ME

What to do:

> i've always had a very hard time using xmodmap; the syntax just
> doesn't seem to want to jellify in my brain.  everytime i've ever done
> anything with xmodmap, it seems like it's always been a 15 minute
> struggle with the man page.

Not sure it would be handled in xmodmap, but there might be a solution in
the XF86 config for mapping one of the mouse buttons functionality to a
key (say the MS windows key), but I have never looked to do this. I almost
want to research this to see how to do it. Perhaps when I have more free
time.
Another possible work around might be in your window manager settings. I
seem to recall something in fvwm's config files on functions of mouse
clicks being available to certain keys but I am not sure.

> but besides, i'm almost always in console, so xmodmap doesn't help me much
> anyway.  i'd rather have a console solution.

screen can do that for you. It is Kick Ass and get my approval for
critical sysadmin tools. (Whatever that may mean for you in your
evaluation.)

> while i'm at it -- if anyone knows of a guide, howto or webpage that
> is a more gentle introduction to xmodmap than the man page, i would be
> eager to read it.

Sorry, never really looked. :-/

-ME


-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GCS/CM$/IT$/LS$/S/O$ !d--(++) !s !a+++(-----) C++$(++++) U++++$(+$) P+$>+++ 
L+++$(++) E W+++$(+) N+ o K w+$>++>+++ O-@ M+$ V-$>- !PS !PE Y+ !PGP
t@-(++) 5+@ X@ R- tv- b++ DI+++ D+ G--@ e+>++>++++ h(++)>+ r*>? z?
------END GEEK CODE BLOCK------
decode: http://www.ebb.org/ungeek/ about: http://www.geekcode.com/geek.html
     Systems Department Operating Systems Analyst for the SSU Library


LinkedIn
LUGOD Group on LinkedIn
Sign up for LUGOD event announcements
Your email address:
facebook
LUGOD Group on Facebook
'Like' LUGOD on Facebook:

Hosting provided by:
Sunset Systems
Sunset Systems offers preconfigured Linux systems, remote system administration and custom software development.

LUGOD: Linux Users' Group of Davis
PO Box 2082, Davis, CA 95617
Contact Us

LUGOD is a 501(c)7 non-profit organization
based in Davis, California
and serving the Sacramento area.
"Linux" is a trademark of Linus Torvalds.

Sponsored in part by:
EDGE Tech Corp.
For donating some give-aways for our meetings.