Subject: FVWM: A cyclic Front Key

From: Richard Guay <[email-masked]>
Date: Tue, 19 Dec 1995 13:03:03 -0500

Hi,

I am still trying to learn how to do things on Fvwm2.  It is a great desktop!  My boss wants to be able to use the "Front" key on his Sparc Station 2 as it did work under olvwm (ie. if the window is in front, make it go to the back.  If the window is in back, make it come to the front).  Is there a way to toggle Raise/Lower commands?

Richard A. Guay
[email-masked]
http://www.asicint.com
--
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Gregory Margo <[email-masked]>
Date: Tue, 19 Dec 1995 11:15:40 -0800 (PST)

Richard Guay said:
> 
> I am still trying to learn how to do things on Fvwm2.  It is a great
> desktop!  My boss wants to be able to use the "Front" key on his Sparc
> Station 2 as it did work under olvwm (ie. if the window is in front, make
> it go to the back.  If the window is in back, make it come to the front).
> Is there a way to toggle Raise/Lower commands?
> 
> Richard A. Guay
> [email-masked]
> http://www.asicint.com

The "RaiseLower" command will do what you want.
I bind this command to Alt-F5.  This is not as convenient as just plain F5,
but it leaves the function key free.  To bind to plain F5, replace the 'M'
with an 'N'.

add to .fvwm2rc:
	Key F5		A	M	RaiseLower

While F5 is appropriate for my PC keyboard, it is probably *not* correct
for a Sparc keyboard.  Who knows the correct keycode?

gm
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Gregory H. Margo                 No free speech restrictions on the Internet!
[email-masked]
--
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: [email-masked] (Eric Ding)
Date: Tue, 19 Dec 95 12:33:27 PST

>>>>> Gregory Margo <[email-masked]> writes:

> The "RaiseLower" command will do what you want....
> add to .fvwm2rc:
> 	Key F5		A	M	RaiseLower

> for a Sparc keyboard.  Who knows the correct keycode?

Here's what I've got in my .fvwm2rc:

Key L5          A       A       RaiseLower
Key L7          A       A       Iconify

This also binds the "Open" key to toggle iconified/open windows.

Eric
--
1601 Technology Drive                         [email-masked]
San Jose, CA 95110-1397                   <><         PHONE: (408) 437-5068
http://web.mit.edu/ericding/www/home.html               FAX: (408) 437-5246
--
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: "Mr. Graeme McCaffery" <[email-masked]>
Date: Wed, 20 Dec 1995 13:56:52 +0000

Having taken a look at the fvwm2 code(pl 34) I noticed a small bit in a
function called SetTitleBar (borders.c)

In this you define where the title bar text goes.
If the horizontal offset is changed in a few different way you can have
left,right and center justification.

I did it by setting it to one of the 3 values below:

hor_off = (t->title_width - w)/2;          centre
hor_off = (t->title_width - w)-10;	   right
hor_off =10;				   left

if this could be incorporated into the fvwm config file I'm sure that it
would take very little code to do. I'm still a novice at X programming,
but I'm happy to help if I can because that way I can learn.

Graeme McCaffery
-- 
G. McCaffery
The University of Birmingham
http://sun1.bham.ac.uk/g.mccaffery/
--
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: <[email-masked]> (Charles Hines)
Date: Wed, 20 Dec 1995 10:35:25 -0500

>>>>> "Graeme" == Graeme McCaffery <[email-masked]> writes:

Graeme> Having taken a look at the fvwm2 code(pl 34) I noticed a small
Graeme> bit in a function called SetTitleBar (borders.c)

Graeme> In this you define where the title bar text goes.  If the
Graeme> horizontal offset is changed in a few different way you can
Graeme> have left,right and center justification.

Graeme> I did it by setting it to one of the 3 values below:

Graeme> hor_off = (t->title_width - w)/2;          centre
Graeme> hor_off = (t->title_width - w)-10;         right
Graeme> hor_off =10;                               left

Graeme> if this could be incorporated into the fvwm config file I'm
Graeme> sure that it would take very little code to do. I'm still a
Graeme> novice at X programming, but I'm happy to help if I can
Graeme> because that way I can learn.

Actually, this has been submitted by someone else as a patch against
1.xx, which I've had forever and have been meaning to incorporate into
2.xx, and it worked differently.  I'll see about starting to add it as
part of the TitleStyle option that I wanted (but for now it'll only
handle justification) for the next patchlevel, since it's only a very
little bit of code.

Chuck

---

From: [email-masked] (Jon Mountjoy)
Date: Wed, 20 Dec 1995 19:03:38 +0100 (MET)

Quoting Richard Guay,
| 
| Hi,
| 
| I am still trying to learn how to do things on Fvwm2.  It is a great =
| desktop!  My boss wants to be able to use the "Front" key on his Sparc =
| Station 2 as it did work under olvwm (ie. if the window is in front, =
| make it go to the back.  If the window is in back, make it come to the =
| front).  Is there a way to toggle Raise/Lower commands?

The following is my setting for some of the Sun keyboard keys.

/* Function keys on Sun Keyboard on Top Row*/
Key F1          A       N       Exec me(netscape) &
Key F2          A       N       Exec me(netscape -install) &
Key F5          A       N       Exec makex(Adder)
Key F6          A       N       Exec makex(Lambda) 
Key F7          A       N       Exec makex(Castor)
Key F8          A       N       Exec xterm -sb -si -sl 700 -font 7x14 -T Local &

/*  Keys on the function keypad on the Left of the Sun Keyboard:
    F11 = Stop, F12 = Again, ..., F20 = Cut
*/
Key F11         AWF       N       Next [!iconic CurrentScreen CurrentDesk] Focus
Key F12         AWF       N       Prev [!iconic CurrentScreen CurrentDesk] Focus
Key F13          WF       N       Maximize     100 100
Key F15          WF       N       RaiseLower ""
Key F17          WIF      N       Iconify ""
Key F18          WF       N       Stick ""
Key F20         WIF      N       Delete ""
Key Help         AWF       N       Iconify ""

--

So F11 = the Stop key.  I have mapped this and F12 (Again) to left
and right cycle through open windows on current screen.

F13 = Props: I have mapped to Maximise
F15 = Front: I mapped to RaiseLower, which is what you want I think.
F17 = Open : I map to iconify...
F18 = Paste: The perfect name for the key to make something sticky
F20 = Cut  : The perfect name for the key to close a window :-)

Cheerio,
Jon

---

From: Fredrik \Vhrstr\vm <[email-masked]>
Date: Wed, 20 Dec 1995 20:55:57 +0100 (MET)

I have activated the module autoraise with a delay of 2 seconds or so.
When I enter any motif program and after 1.9 seconds press the Filemenu 
choice, the filemenu is nicely popped. But then, since now it has passed 
0.1 second and since i am not in the newly popped up filemenu window. 
Autoraise decides to raise the main window above this popped window!
Oups where did the filemenu go! Is there some way to detect if a 
menuwindow is a child of a window and should not be put behind it?
Is there any way to prevent this? I am using version 2.0.38.

//Fredrik

---

From: <[email-masked]> (Charles Hines)
Date: Wed, 20 Dec 1995 16:19:19 -0500

>>>>> "Fredrik" == Fredrik Vhrstrvm <[email-masked]> writes:

Fredrik> I have activated the module autoraise with a delay of 2
Fredrik> seconds or so.  When I enter any motif program and after 1.9
Fredrik> seconds press the Filemenu choice, the filemenu is nicely
Fredrik> popped. But then, since now it has passed 0.1 second and
Fredrik> since i am not in the newly popped up filemenu window.
Fredrik> Autoraise decides to raise the main window above this popped
Fredrik> window!  Oups where did the filemenu go! Is there some way to
Fredrik> detect if a menuwindow is a child of a window and should not
Fredrik> be put behind it?  Is there any way to prevent this? I am
Fredrik> using version 2.0.38.

No way to prevent this except to wait until the window is raised
before popping up the menu.  The reason is that override redirect
windows are used for the popups, and are ignored by the window
manager.  I don't believe that this can really be helped.

Chuck

---

From: Chad Coulliette <[email-masked]>
Date: Wed, 20 Dec 1995 15:32:38 -0800 (PST)

Hello,

I tried the key mappings that were given for the Sun keyboard "Props"
and "Front" and "Open" keys.  Unfortunately, they have no effect.  I
think the problem is that I am not using the proper key identifier. 
Does anyone know how find out what FVWM2 calls certain keys.  In other
words, is their someway to tell FVWM2 to echo the identifier of a key,
so that we know what it is called.  Under emacs, there is facility for
doing this, if you type C-h c and then the desired key.  How about FVWM2?

I have been able to assign functions such as page scrolling  and desk
moving to the keys "Next" "Prior" "Left" "Right".  These work fine.

Thanks,

Chad
--------------------------------------------------------
Chad M. Coulliette
[email-masked]
Applied Mechanics and Engineering Sciences
University of California, San Diego
--
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: [email-masked] (Jon Mountjoy)
Date: Thu, 21 Dec 1995 14:03:01 +0100 (MET)

Quoting Chad Coulliette,
| 
| Hello,
| 
| I tried the key mappings that were given for the Sun keyboard "Props"
| and "Front" and "Open" keys.  Unfortunately, they have no effect.  I
| think the problem is that I am not using the proper key identifier. 
| Does anyone know how find out what FVWM2 calls certain keys.  In other
| words, is their someway to tell FVWM2 to echo the identifier of a key,
| so that we know what it is called.  Under emacs, there is facility for
| doing this, if you type C-h c and then the desired key.  How about FVWM2?
| 
| I have been able to assign functions such as page scrolling  and desk
| moving to the keys "Next" "Prior" "Left" "Right".  These work fine.

Odd that they don't work.  Work for me and all the various suns here
in the neighbourhood.
What you should do is use the unix command 'xev' to find the names
that your X server assigns the keys.

Jon

---

From: Grant McDorman <[email-masked]>
Date: Thu, 21 Dec 95 09:33 EST

> moving to the keys "Next" "Prior" "Left" "Right".  These work fine.

Are you running X11R6? The key names change when you do so. Try
SunProps, SunFront and SunOpen as well as the L* keys.

To determine what keys you have, you can use "xev" (if installed).
It produces a lot of output, regrettably.

A very good program for looking at your keymap - and customizing it -
is xkeycaps, available from ftp.x.org.

I used to have a simple program for displaying the key name; don't
think I brought it with me when I changed jobs, though.