1 ======================================================================
2 Fvwm Frequently Asked Questions
3 ======================================================================
5 Last updated 20 Jan 2009 for unstable release 2.5.26 and stable
10 0. *The* most frequently asked questions :)
12 0.1 A few minutes after fvwm is started my keyboard and
13 mouse bindings stop working. What can I do?
14 0.2 I use XMMS, but it ignores some window styles.
15 0.3 I like transparency. What can I do?
19 1.1 What does fvwm stand for?
20 1.2 Where do I find the current versions of fvwm?
21 1.3 Any WWW Sites about fvwm?
22 1.4 Where do I ask questions about fvwm?
23 1.5 What are the differences between fvwm 1.xx and 2.xx?
24 1.6 What's the relative memory usage for the various window
26 1.7 Why the rename of the various files (fvwm2, .fvwm2rc,
28 1.8 When will fvwm release X.Y.Z be ready?
32 2.1 I want to use fvwm, but I don't have root access on my
33 machine. Can I still install and run it?
34 2.2 I'm trying to use fvwm under CDE/COSE, but encountering
35 difficulties. Any suggestions?
36 2.3 I'm trying to compile fvwm under SunOS using cc, but the
37 compiler is having lots of problems. What gives?
38 2.4 I want colored icons, but they won't work. Why not?
39 When I run configure, it reports "no" to "Have XPM
40 support?" How can I get XPM support?
41 2.5 I'm a sysadmin, and if I wanted to force fvwm to read a
42 system rc file and then the user's rc file, how would I
44 2.6 I'm a sysadmin, and if I wanted fvwm to look for all of
45 its rc files in a hidden directory, say ~/.fvwm, much
46 like CDE does, how could I do that?
47 2.7 How can I use fvwm with GNOME version <= 1?
48 2.8 How can I use fvwm with GNOME version >= 2 or KDE
51 3. Features, Configuration, Functions & Commands
53 3.1 I use fvwm on a RedHat Linux system and can't figure out
54 how to change my fvwm configuration. I've read the fvwm
55 man page but when I edit my .fvwm2rc nothing seems to
56 happen. What's going on?
57 3.2 Is it possible to raise a window when I click into the
58 window itself, not just the border?
59 3.3 How do I get Alt-Tab behavior like another GUI?
60 3.4 What's the difference between the Focus and FlipFocus
62 3.5 You can bind mouse movements to keystrokes, how about
64 3.6 I'd like to bind a key to paste/use the current
65 selection, how can I do that?
66 3.7 Will fvwm ever support a separate colormap for each
68 3.8 I really like the horizontal bars that appear on the
69 title bars of sticky windows. Can I get those on other
71 3.9 How do I set the Sun keyboard key xxxx to an fvwm
72 command? Or more generally, I'm having problems defining
73 key bindings for fvwm - what can I do?
74 3.10 My .fvwmrc from version 1.xx no longer works. What do I
76 3.11 What happened to the fvwm 1.xx 'include' command?
77 3.12 How do I get window titles on sub windows of ...
78 3.13 I just upgraded to version >= 2.3.2, and my
79 configuration settings disappeared! How do I get them
81 3.14 Some applications (e.g. Eterm) don't use the icon I
82 defined for them. Why?
83 3.15 I don't like the gaps in my icon box when I de-iconify
84 an application. Is there some kind of auto arrange
86 3.16 How do I set up an fvwm menu item that shuts down my
88 3.17 Although the Recapture command is obsolete, do I still
89 need it to apply certain style changes?
90 3.18 When my specific window (or all windows) pops up, I want
91 it to get focus/be moved/be resized/be closed/be
93 3.19 When my specific window (or all windows) is closed, I
94 want to switch desks/wrap to my app X/popup a menu/start
96 3.20 I have a multi head setup (multiple screens used under
97 X). How can I tell fvwm to use different configurations
99 3.21 How do I maximize a window but not cover up FvwmTaskBar?
100 3.22 Why my close button looks pressed in maximized windows?
101 Why don't buttons show on the titlebar of some windows?
102 3.23 How to define transparent menus?
103 3.24 How to define transparent modules?
104 3.25 How to define transparent decorations?
105 3.26 How about transparent applications too?
106 3.27 How can I define emacs type multi-keystroke fvwm bindings?
107 3.28 How do I remove all decorations from a window?
108 3.29 What's the best way to make on-the-fly config changes?
112 4.1 I'm using FvwmButtons (or GoodStuff in 1.xx), and
113 sometimes the buttons stay depressed, and other times
114 they don't. Why is that?
115 4.2 When having FvwmButtons swallow an app, is it possible
116 to have button presses assigned to actions as well? For
117 instance, I'd like to swallow xload and have a button
118 press pop up an xterm, or swallow xbiff and have a
119 button press bring up the list of messages.
120 4.3 I'm seeing odd things when trying to preprocess files
121 with the FvwmM4/Cpp module...
122 4.4 I heard about this FvwmFileMgr module. Where can I find
124 4.5 I used to use GoodStuff in fvwm 1.xx, but it's not in
125 the 2.xx distribution. What do I use now?
126 4.6 I want to have the sub panels in FvwmButtons not at
127 their default position near the button but somewhere
128 else on the screen. Is this possible?
129 4.7 How can I open a sub panel or push buttons in
130 FvwmButtons with a keyboard shortcut?
132 5. Development, Known Problems & Bug Reports
134 5.1 I'd really like to see neat feature XYZ in
135 fvwm. Wouldn't that be cool? I even have a patch. When
137 5.2 How do I create/submit/apply patches?
138 5.3 How do I submit a bug report?
139 5.4 I have a window that is behaving unexpectedly under
140 fvwm, but just fine under (whatever other window
141 manager), or I have just some random bug. What do I do?
142 5.5 Why do NumLock, CapsLock and ScrollLock interfere with
143 ClickToFocus and/or my mouse bindings?
144 5.6 Menus with gradient backgrounds flicker or are very
146 5.7 Why won't the StartIconic style work with {Netscape,
148 5.8 How do I capture the output (e.g. errors) of fvwm?
149 5.9 I try to run some program under fvwm, but it dies with
150 an X11 error like BadAccess. The same program works
151 just fine under MWM or OLWM. What's going on?
152 5.10 Every time I update my install, my currently running
153 fvwm session dies. Why is that?
154 5.11 After I restart fvwm certain windows or icons raise
155 above all other windows and cannot be lowered by any
156 means. One example are the shortcuts of KFM (the KDE
157 file manager). What can I do about that?
158 5.12 The StartsOnPage style does not work for me. Why?
159 5.13 Some modules can not be started when I restart fvwm.
160 5.14 I'm running Rational Rose and fvwm ignores its windows.
161 5.15 Although I use the WindowListSkip style for my modules
162 they still show up in FvwmIconMan, FvwmWinList etc.
163 5.16 When I Maximize an application, sometimes I get gaps
164 around the edges, and other times I don't. What's going
169 6.1 What exactly is the difference between a DESK, a PAGE,
171 6.2 I'd really like {NeXT, Win95, etc} look and feel. Are
172 you going to support that?
173 6.3 Where can I get more XPMs for icons?
174 6.4 Linux XF86 virtual screen size & fvwm interaction...
175 6.5 I know this question doesn't have to do with fvwm, but
176 what happened to to rxvt and rclock which Rob Nation
177 used to support? Where can I find them now?
178 6.6 How do I set the background with fvwm?
179 6.7 When I use Fvwm, my XYZ isn't the right color. What's
181 6.8 I just got a mouse with 57 buttons. How do I make Fvwm
183 6.9 Why does fvwm change my X Cursor theme?
185 7. Hints and Examples from the Developers
187 7.1 An easy way to test new configurations.
188 7.2 Using shell commands for configuration.
189 7.3 How to start applications on a page or desk other than
191 7.4 How to start applications on a page or desk other than
192 the current without moving the viewport to the new page
194 7.5 A more efficient MWM menu style.
195 7.6 Placing menus on the screen.
196 7.7 Are you flipping pages by accident when moving the mouse
197 close to the border of the screen?
198 7.8 Lining up your windows and icons.
199 7.9 Moving the mouse/focus/page with the keyboard.
200 7.10 The cat safe desktop :-)
201 7.11 Lowering and moving windows.
202 7.12 Toggling windows on and off.
203 7.13 Starting applications by clicking on an icon (also known
204 as "docking" applications).
205 7.14 Positioning a window using arithmetic.
206 7.15 Hiding the mouse pointer.
207 7.16 Finding the mouse pointer.
208 7.17 Autohiding FvwmButtons or other windows.
209 7.18 Using application screenshots as icon or mini icon
212 ======================================================================
213 0 - The most frequently asked question
214 ======================================================================
216 0.1 A few minutes after fvwm is started my keyboard and mouse
217 bindings stop working. What can I do?
219 A: Probably your NumLock, CapsLock or ScrollLock key is pressed. See
220 Q 5.5 for more details.
222 Trivia: In all my years as an fvwm developer this has been by far the
223 most frequently asked question. Whoever can solve this problem so
224 that this question is never asked again will be mentioned in big
225 letters on the fvwm home page :-)
227 ----------------------------------------------------------------------
229 0.2 I use XMMS, but it ignores some window styles.
231 A: XMMS wants to do everything by itself and overrides many
232 settings of the window manager. Check the options menu in XMMS
233 and if that does not help, ask the XMMS people about it at
237 *Please* do not ask XMMS questions on the fvwm mailing lists
238 and do not report XMMS related bugs before you tried the XMMS
239 mailing lists. No offense meant, but we really have more
240 important things to do than providing user support for third
243 ----------------------------------------------------------------------
245 0.3 I like transparency. What can I do?
247 A: See questions 3.23, 3.24, 3.25, 3.26 that deal with transparency.
249 Also see configurations supplied in fvwm-themes package, some
250 themes use transparent menus, modules and/or decorations. E.g.:
252 http://fvwm-themes.sf.net/screenshots/full/transparent.png
253 http://fvwm-themes.sf.net/screenshots/full/transparent.jpg
256 ======================================================================
258 ======================================================================
260 1.1 What does fvwm stand for?
262 A: "Fill_in_the_blank_with_whatever_f_word_you_like_at_the_time
263 Virtual Window Manager". Rob Nation (the original Author of fvwm)
264 doesn't really remember what the F stood for originally, so we
265 have several potential answers:
267 Feeble, Fabulous, Famous, Fast, Foobar, Fantastic, Flexible,
268 F!@#$%, Flashy, fvwm (the GNU recursive approach), Free, Final,
269 Funky, Fred's (who the heck is Fred?), Freakin', Flawed,
270 Father-of-all, Feivel (the mouse from "An American Tail"),
271 Frungy (hey, where does that come from?), Floppy, Foxy,
272 Frenzied, Funny, Fumbling etc.
274 Just pick your Favorite (hey, there's another one!), which will of
275 course change depending on your mood and whether or not you've run
276 across any bugs recently. I prefer Fabulous or Fantastic myself,
277 although I often use F!@#$% or Freakin' while debugging...
279 Recently 'Feline' is becoming popular. Perhaps this has something
280 to do with the discovery that four of the six core developers have
281 cats (averaging 1.17 cats)? Miaow.
283 Know what? I found another one while stroking my cats: FEEDING :-)
286 http://fvwm.org/fvwm-cats/
288 ----------------------------------------------------------------------
290 1.2 Where do I find the current versions of fvwm?
292 A: New main distribution site (official + beta code):
294 ftp://ftp.fvwm.org/pub/fvwm/
299 ftp://sunsite.unc.edu/pub/Linux/X11/window-managers/
300 ftp://ftp.cs.columbia.edu/pub/cheah/
303 ftp://unix.hensa.ac.uk/pub/walnut.creek/FreeBSD/incoming/
304 ftp://ftp.jussieu.fr/pub/X11/fvwm/
305 ftp://ftp.loria.fr/pub/unix/fvwm/
307 By the way, 1.24r was the last released version of the 1.xx series
308 and the first official release of 2.xx is 2.2. As of 2.2, an odd
309 second digit denotes development releases and even numbers denote
312 ----------------------------------------------------------------------
314 1.3 Any WWW Sites about fvwm?
316 A: Yup. The official site is:
320 There are links on the official site to other related fvwm sites.
322 ----------------------------------------------------------------------
324 1.4 Where do I ask questions about fvwm?
326 A: If your local fvwm maintainer can't help you, then try the fvwm
327 mailing list. The fvwm discussion mailing list address is:
331 And there is an announce mailing list as well:
333 fvwm-announce@fvwm.org
335 They are maintained by Jason Tibbitts, and are Majordomo based
336 mailing lists. To subscribe to the list, send "subscribe fvwm" in
337 the body of a message to <list>-request@fvwm.org. For example, to
338 subscribe to the fvwm mailing list, send a request to
339 fvwm-request@fvwm.org.
341 To unsubscribe from a list, send "unsubscribe fvwm" in the body
342 of a message to <list>-request@fvwm.org. To report problems, send
343 mail to fvwm-owner@fvwm.org.
345 Here's the list descriptions and instructions directly from Jason:
347 ------------------------------------------------------------------
353 This list is for discussion relating to the fvwm window manager,
354 which is intended to have a small memory footprint and a rich
355 feature set, be extremely customizable and extendible and have a
356 high degree of Motif MWM compatibility. All relevant discussion
357 is encouraged. Posting of binaries or irrelevant discussion is
358 strongly frowned upon. Posting of short patches (less than 200
359 lines) is acceptable, but all patches should also be sent to the
360 fvwm-workers list (see Q5.2, below) for inspection and possible
361 inclusion in the distribution.
367 To send a message to the list, mail to fvwm@fvwm.org. For help on
368 dealing with the mailing list software (for getting the archives or
369 other files which may be made available) send the message "help" to
370 fvwm-request@fvwm.org. If you have problems with the mailing list
371 itself and need to talk to a human, send mail to
372 fvwm-owner@fvwm.org. This address is for mailing list issues only;
373 reports on the fvwm software will be sent to /dev/null.
375 Archives of previous messages are available; to get them send the
376 above mentioned help message and investigate the "index" and "get"
377 commands or ftp them from
378 ftp://ftp.fvwm.org/pub/fvwm/list-archive/.
383 This list is for announcements relating to the fvwm window manager,
384 which is intended to have a small memory footprint and a rich
385 feature set, be extremely customizable and extendible and have a
386 high degree of Motif MWM compatibility.
388 Replies to messages from this list are set by default to go the
389 fvwm discussion list, fvwm@fvwm.org.
391 The current fvwm distribution is available for ftp at
392 ftp://ftp.fvwm.org/pub/fvwm/
393 ------------------------------------------------------------------
395 ----------------------------------------------------------------------
397 1.5 What are the differences between fvwm 1.xx and 2.xx?
399 A: A lot. To name a few general ones:
400 - Bug fixes. 1.xx is not worked on at all any more.
401 - Better rc file format. No longer order dependent.
402 - More flexible and powerful. For example, many previously
403 global options now operate on a per window group level
405 - More and better modules.
406 - M4 preprocessing is no longer part of the fvwm exec, but
407 rather has been moved to a module. There is also a module
408 to use cpp too. See the FvwmM4 and FvwmCpp man pages.
410 Be sure to check the NEWS file for new or changed features too.
412 ----------------------------------------------------------------------
414 1.6 What's the relative memory usage for the various window managers
417 A: Here's a little table comparing some of them. It was done on an
418 AIX based IBM RS6000 model 355 using the same number of windows (3)
419 and XSession to switch between the window managers, and I used
420 'top' to show the values:
423 545K 652K fvwm2 (fvwm 2.0.35)
424 457K 528K fvwm (fvwm 1.24rb)
425 856K 960K ctwm (ctwm 3.2p1)
426 1004K 1156K mwm (mwm 1.2)
428 263K 328K aixwm (a simple ugly window manager included w/ aix)
430 Note: This information is terribly outdated.
432 ----------------------------------------------------------------------
434 1.7 Why the rename of the various files (fvwm2, .fvwm2rc, fvwm2.man)?
436 A: Some people find this annoying, but it was done for several reasons:
438 - so both 1.xx and 2.xx can be installed for use, in case some
439 people at the same site would rather stay at 1.xx
440 - the syntax of the rc files is pretty different and
441 completely incompatible
442 - when people ask questions, if they explicitly mention their
443 .fvwm2rc file I know that they are running one of the 2.xx
444 versions, since they rarely mention exactly what version
447 Note, starting from 2.5.1, the executable fvwm2 became fvwm again.
448 Also, starting from 2.5.11, the default config file is either
449 personal ~/.fvwm/config or system wide $datadir/fvwm/config.
450 So, we completely returned to the "fvwm" name.
452 ----------------------------------------------------------------------
454 1.8 When will fvwm release X.Y.Z be ready?
456 A: This is always a difficult question to answer. We work on fvwm on
457 a volunteer basis. Things get done when we have the time.
459 Joining the fvwm-workers mailing list might prove instructive.
462 ======================================================================
464 ======================================================================
466 2.1 I want to use fvwm, but I don't have root access on my machine.
467 Can I still install and run it?
469 A: Very easily, using the '--prefix' flag at configure time.
471 Suppose your home directory is /home/sam. After unpacking the
472 fvwm sources, do "./configure --prefix=/home/sam [other options as
473 needed]'. Now, after building ("make") and installing ("make
474 install"), you will find the binaries in /home/sam/bin, the
475 man pages in /home/sam/man, etc. The modules will be in
476 /home/sam/libexec, and fvwm binary will have this module path
479 ----------------------------------------------------------------------
481 2.2 I'm trying to use fvwm under CDE/COSE, but encountering
482 difficulties. Any suggestions?
484 A: Sure - here's one from Graeme McCaffery:
487 Finally I have found out how to run fvwm properly from CDE 8-))
488 (thanks to Lars Sodergren).
490 First set your home session in Dtwm. That usually is an empty
491 session, though you could have the CDE session manager remember
492 what your desktop was like instead of FvwmSaveDesk etc..
494 Then you have to set two resources in .Xdefaults:
496 Dtsession*wmStartupCommand: /home/orion/spxgm/bin/Fvwm
497 Dtsession*waitWmTimeout: 1
499 In this case I run fvwm from a shell script so that library
500 variables etc are set properly for everyone. The waitWmTimeout
501 tells the session manager how long to wait until it starts the
502 window manager. I've set it to 1 second. By default it's 60
505 Finally you have to quit with
507 /usr/dt/bin/dtaction ExitSession (or whatever your path is for dtaction)
509 Now you can happily use CDE programs and fvwm.
512 On the other hand, here is a link to a web page that describes
513 how to add multiple window managers to the CDE login menu:
515 http://twirl.mcc.ac.uk/~zzassgl/wm.html
517 ----------------------------------------------------------------------
519 2.3 I'm trying to compile fvwm under SunOS using cc, but the compiler
520 is having lots of problems. What gives?
522 A: cc under SunOS is not an ANSI C compiler. Try using acc or gcc
525 ----------------------------------------------------------------------
527 2.4 I want colored icons, but they won't work. Why not?
528 When I run configure, it reports "no" to "Have XPM support?" How
529 can I get XPM support?
531 A: Fvwm uses the XPM (X PixMap) library to provide support for colored
532 and shaped icons. XPM doesn't ship with the basic X distribution
533 as provided by The Open Group or XFree86. However, many vendors
534 will bundle it as a standard component anyway. If not, you can get
535 a copy of the source from ftp://ftp.x.org/contrib/libraries/ and
538 If you have XPM on your system, there are a number of ways
539 configure could still decide not to use it.
541 First, if you've installed XPM in a non-standard place (not in the
542 normal system or X11 directories--say in /opt/xpm or /usr/local or
543 similar) then you need to tell configure where to look. Use the
544 --with-xpm-library and --with-xpm-includes options (see
545 INSTALL.fvwm). Typically configure will say "Xpm library or header
546 not found" if this is the problem.
548 Second, your version of XPM may be too old. Fvwm requires XPM 3.4g
549 or better. Typically configure will say "Xpm library version is
550 too old!" if this is the problem. In that case, you'll need to
551 install a newer version.
553 Third, XPM may be mis-installed on your system. If configure says
554 " Xpm library version and header file version don't match!" then
555 this may be the problem. Either use the --with-xpm-library and
556 --with-xpm-includes options to specify more precisely what you
557 want, or try re-installing XPM.
559 Last, there could be a linker error. This is especially common on
560 systems where XPM may be built as a shared library and installed in
561 a non-standard directory (Solaris is a good example). There are
562 some notes about building using shared libraries in the
565 If you can't figure it out, contact the fvwm mailing list. Please
566 be sure to provide the type of hardware and operating system you're
567 using, how you invoked configure, and extract the lines dealing
568 with XPM from the config.log file and include that.
570 ----------------------------------------------------------------------
572 2.5 I'm a sysadmin, and if I wanted to force fvwm to read a system rc
573 file and then the user's rc file, how would I do that?
575 A: Well, you could probably do something like this. Have the first
576 line of everyone's ~/.fvwm/config or ~/.fvwm/.fvwm2rc files be
577 'Read global.config' and have global.config reside in
578 "$datadir"/fvwm (the value of $datadir is set on ./configure step).
580 ----------------------------------------------------------------------
582 2.6 I'm a sysadmin, and if I wanted fvwm to look for all of its rc
583 files in a hidden directory, say ~/.fvwm, much like CDE does, how
586 A: Fvwm now supports ~/.fvwm search directory by default.
588 This could be probably done similarly to Q2.5 above. The system rc
589 "$datadir"/fvwm/config (or system.fvwm2rc) could do something like:
599 or whatever breakdown you deemed appropriate, and you would have
600 default versions of these in "$datadir"/fvwm/ that it could find
601 in case the user was missing one of them and you wanted to supply
604 ----------------------------------------------------------------------
606 2.7 How can I use fvwm with GNOME (version <= 1)?
608 A: Since the latest fvwm versions are mostly GNOME compliant, you may
609 simply run GNOME applications, like panel, gmc, gnome-terminal and
610 all others with fvwm.
612 The included fvwm-menu-desktop script (with a massive man page)
613 will help you build fvwm menus for gnome applications.
615 To ensure you run fvwm and not gnome-session, create .Xclients file
616 in your home directory and put a call to fvwm in it. The file
617 ~/.xinitrc can be used for the same purpose if you want to bypass
618 any system-wide logic installed by your distributor or sysadmin.
620 An alternative solution is to run fvwm inside of
621 /usr/bin/gnome-session. After you start gnome-session (don't start
622 fvwm yourself), go to the foot menu in the GNOME panel, then choose
625 System menus / Settings / Desktop / Window Manager
627 and create an entry for fvwm. Fvwm supports session management.
629 If you run gnome-session, SessionInitFunction and
630 SessionRestartFunction are called instead of InitFunction and
631 RestartFunction, see the fvwm man page.
633 StartFunction, for running modules, is called as usual.
636 Here are examples of the GNOME Window Manager hints support in
639 o If you run gnome panel inside fvwm without GNOME support, you
640 can't fully use GNOME pager applets (if at all); with GNOME
641 support you can correctly see pages/desks and move windows
642 between them inside applets. You can also use the GNOME Tasklist
643 applet and manage your windows using it.
645 o If you run gmc and bind GnomeButton (see the man page), you can
646 pass root clicks to a gnome application (i.e. to gmc in this
649 ----------------------------------------------------------------------
651 2.8 How can I use fvwm with GNOME version >= 2 or KDE version >= 2?
653 A: Most standard applications work as any other application with
654 fvwm. However, some features and special applications such as
655 panels, pagers, taskbars and desktops need a special
656 support. Interaction between the window manager, the desktop
657 environment and applications is standardized in the Extended Window
658 Manager Hints specification. fvwm supports this specification since
659 the 2.5.x series (GNOME, GTK, KDE and QT since their version
660 2). See the "Extended Window Manager Hints" section of the fvwm
661 manual page and the commands and styles which start with "EWMH" for
664 You can use fvwm as the GNOME window manager. For this, start GNOME
665 (gnome-session). The game is to replace the running window manager
666 (sawfish or metacity by default) by fvwm. You may try to type "fvwm
667 --replace&" in a terminal. If this does not work kill fvwm and open
668 the session properties dialog (run "gnome-session-properties&" in a
669 terminal) and change, in the second tab, the metacity (or sawfish)
670 Style value from "Restart" to "Normal" (do not forget to "Apply"
671 this change), so that gnome-session won't restart it when you kill
672 it. Then, run "killall metacity; sleep 1; fvwm &" in a
673 terminal. After you have succeeded starting fvwm you just have to
674 save your session (say via GNOME session logout). The next time you
675 start gnome-session, fvwm will be used (and you do not need to save
676 the session again at logout). Note that if you use gnome-smproxy,
677 and run an FvwmButtons which swallows some applications which use
678 the old session protocol these applications are restarted by
679 gnome-session and FvwmButtons at session restart which can cause
682 You can also use fvwm as the KDE window manager. KDE is started by
683 a shell script called "startkde". This script starts ksmserver
684 which starts the window manager (kwin by default). To start fvwm
685 you should add the option "-w fvwm" to the ksmserver command line
686 (close to the end of the script). You may copy startkde to
687 startkde_fvwm somewhere in your path, edit startkde_fvwm and
688 finally replace startkde by startkde_fvwm in your X startup script
689 (e.g., ~/.xinitrc, ~/.Xclients or ~/.xsession). Note that ksmserver
690 does not support the fvwm Restart command. You should use "Restart
691 fvwm" for restarting fvwm. But if you do that it is a bad idea to
692 save the session later.
694 ======================================================================
695 3 - Features, Configuration, Functions & Commands
696 ======================================================================
698 3.1 I use fvwm on a RedHat Linux system and can't figure out how to
699 change my fvwm configuration. I've read the fvwm man page but
700 when I edit my .fvwm2rc nothing seems to happen. What's going
703 A: RedHat Linux installs the X server accompanied (by default) by a
704 configuration management system. In earlier releases it was called
705 TheNextLevel and in more recent releases it's called
706 AnotherLevel. For further information about TheNextLevel, consult
707 RedHat's documentation in /usr/doc/TheNextLevel/. For information
708 about AnotherLevel, do a 'man AnotherLevel'.
710 ----------------------------------------------------------------------
712 3.2 Is it possible to raise a window when I click into the window
713 itself, not just the border?
715 A: Any version later than 2.0.46 (i.e. 2.1.0 or later) has this
716 feature. In the 2.2.x series, use:
718 GlobalOpts MouseFocusClickRaises
720 With the later 2.3.x betas and after use:
722 Style * MouseFocusClickRaises
724 ----------------------------------------------------------------------
726 3.3 How do I get Alt-Tab behavior like another GUI?
728 A: The built in command WindowList provides a very close approximation
729 to the Alt-Tab feature found in another GUI. It doesn't look the
730 same but the following fvwm/config sample will provide a similar
733 Key Tab A M WindowList Root c c NoDeskSort
735 Starting with release 2.3.2, the above key binding is built-in.
737 Starting with release 2.3.15 you can hold the alt key down and keep
738 hitting tab. A single alt-tab selects the previous window. The
739 remainder of this FAQ entry describes releases prior to 2.3.2.
741 Hitting Alt-Tab will pop up the WindowList menu. Unlike another
742 GUI you should not keep the Alt key held down, the menu will stay
743 up until you hit Return/Enter/Space or Escape. You can change
744 focus to a window on the menu by using the up and down arrow keys
745 to move the menu selection and then hitting Return or
746 Enter. Hitting Escape will close the menu without doing anything.
747 The WindowList menu has hot keys assigned for the first 26 windows
748 and you can use the hot key to go directly to the window.
750 The menu invoked with the above line will show all windows in most
751 recently focused order unless you have used the Focus command (see
752 Q3.4). It shows each windows name and geometry with some extra
753 flags to indicate Sticky, OnTop and iconified windows.
755 A simpler style can be used with the following:
757 Key Tab A M WindowList Root c c CurrentDesk, NoGeometry
759 This will just list the windows on the current desk (titles only).
761 The other GUI has the feature of selecting the previous window if
762 Alt-TAB is hit and released quickly. This behavior can be exactly
763 duplicated with 2.5.1 or later but not with earlier fvwm versions.
765 Key Tab A M WindowList Root c c \
766 CurrentDesk, NoGeometry, CurrentAtEnd, IconifiedAtEnd
768 Similar functionality can be assigned to hitting Alt-TAB twice in
769 quick succession (like a double click for keys):
771 DestroyFunc my_dbltab2
775 DestroyFunc my_dbltab
777 + I Prev (CurrentDesk) my_dbltab2
779 Key Tab A M WindowList Root c c \
780 CurrentDesk, NoGeometry my_dbltab
782 There are a lot of options to the WindowList command to control
783 which windows are listed in which order and it may not be possible
784 to set conditions for the Prev command to reliably select the
785 second item when double keying. The WindowList command has no
786 parallel for CurrentPage, Transient, Visible, Maximized, Raised,
787 and pattern matching. The Prev conditions have no parallel for
788 OnTop, Alphabetic and desk sorting. The WindowList menu respects
789 the WindowListSkip style attribute whereas Prev respects the
790 CirculateSkip and CirculateSkipIcon style attributes.
792 ----------------------------------------------------------------------
794 3.4 What's the difference between the Focus and FlipFocus commands?
796 A: Both of these commands change the keyboard focus to the target
797 window. They differ only in the way they affect the internally
798 held list of windows. This list is used by the Next, Prev and
799 WindowList commands. The list is normally sorted in most recently
800 focused order with new windows being added to the end. The
801 FlipFocus command plucks the target window from the list and
802 inserts it at the beginning, The Focus command rotates the list
803 around until the target window is at the beginning. The behavior
804 of FlipFocus is also used when changing focus with the mouse and
805 the automatic focus changing when using ClickToFocus style.
807 If you never use the Focus command the list will remain in most
808 recently focused order. If you do use the Focus command the list
809 will gradually get back to most recently focused order as you use
812 The Focus command is very useful in conjunction with the Next and
815 Key KP_Add A M Next (AcceptsFocus, CurrentDesk, !Iconic) Focus
816 Key KP_Subtract A M Prev (AcceptsFocus, CurrentDesk, !Iconic) Focus
818 Or for fvwm versions earlier than 2.4.1:
820 Key KP_Add A M Next [CurrentDesk !Iconic] Focus
821 Key KP_Subtract A M Prev [CurrentDesk !Iconic] Focus
823 These bindings allow you to circulate the focus around the windows
824 on the current desk in both directions. If Prev FlipFocus were
825 used the focus would toggle between the top two windows on the
828 If you have several windows on a desk and you want to set the
829 circulation order for the Next and Prev commands you should focus
830 on the windows using the mouse or FlipFocus in the order you want.
831 Fvwm will learn the order and use it for the Next and Prev
832 commands. If you subsequently use the mouse to focus or FlipFocus
833 the order will be lost.
835 ----------------------------------------------------------------------
837 3.5 You can bind mouse movements to keystrokes, how about mouse
840 A: Although fvwm has commands for binding movements to keystrokes,
841 controlling the pointer with the keyboard should really be handled
842 by the X server. The following is an excerpt of the X FAQ on this
845 If you have the X Keyboard (XKB) Extension, you can enable mouse
846 keys, which makes it possible to generate mouse motion and button
847 events using the keyboard. Events generated by MouseKeys are
848 completely transparent -- they will work with any application
849 that connects to a server that has the X Keyboard Extension,
850 regardless of whether the application itself uses XKB.
852 XKB is enabled by default in X11R6.1.
854 First, set up the Num Lock key so that Shift+Num_Lock
857 $ xmodmap -e "keysym Num_Lock = Num_Lock Pointer_EnableKeys"
859 (XFree86 3.1.2E is based on R6.1 and has the X Keyboard
860 Extension; it also has a binding to Pointer_EnableKeys in
861 its default keymap. You use Alt+Shift+Num_Lock to toggle
862 MouseKeys on and off. If you are using an earlier release
863 of X or XFree86, you won't have XKB and the instructions
864 will not work. See http://www.XFree86.org/FAQ for more
867 You might also have to turn off server num lock for this to
868 work. Now press "Shift+Num_Lock" to enable MouseKeys. When
871 o) The keypad arrow keys move the pointer
872 o) The keypad '5' key behaves like the 'default' pointer
874 o) The keypad '0' key locks the default pointer button
876 o) The keypad '.' key unlock the default pointer button
878 o) The keypad '+' key double-clicks the default pointer
880 o) The keypad '/' key sets the 'default' button to Button1
881 o) The keypad '*' key sets the default button to Button2
882 o) The keypad '-' key sets the default button to Button3
884 This is the default configuration, but the mechanism allows
885 for nearly infinite configurability.
887 [thanks to Erik Fortune (erik@westworld.engr.sgi.com), 6/96]
889 ----------------------------------------------------------------------
891 3.6 I'd like to bind a key to paste/use the current selection, how can
894 A: You can't directly with fvwm, but there may be a solution that is
895 more generally applicable - use the program 'xcb' available at
896 ftp://ftp.x.org/contrib/utilities/ or from your favorite mirror.
897 It could probably be used to get the desired effect or close to
898 it. This is most useful for running programs and passing the
899 selection to them (e.g. - invoke your favorite browser with the
900 current selection as the URL). To get a semi-generic paste
901 facility to work, you'll probably need to use 'xse' (see Q3.5). If
902 anyone comes up with a good example of this, please send it to the
903 fvwm mailing list for inclusion here.
905 ----------------------------------------------------------------------
907 3.7 Will fvwm ever support a separate colormap for each desktop?
909 A: Doubtful, although I'd like to see it too. I believe that it'd be
910 possible to change the default colormap whenever you switch desks,
911 which would give programs started when that desk is active that
912 colormap, how would you deal with windows being moved across desks?
914 Plus fvwm itself needs certain colormap entries for all of its
915 drawing (borders, menus, etc), so these colors would have to be
916 pre-allocated in all of the colormaps, or something like that.
918 While this all *might* be technically possible, I don't feel that
919 it's really feasible right now (too much code bloat and
920 complexity), especially since most color hog programs
921 (i.e. Netscape) allow you to have them install private colormaps.
923 I may explore this a little at some point in the future though.
925 ----------------------------------------------------------------------
927 3.8 I really like the horizontal bars that appear on the title bars
928 of sticky windows. Can I get those on other windows as well?
930 A: Yes. For release 2.3.14 and after, put the line
932 Style * StippledTitle
934 in your fvwm/config (or .fvwm2rc). For earlier releases use
936 GlobalOpts StipledTitles
938 (Yes, the spelling was inconsistent.)
940 ----------------------------------------------------------------------
942 3.9 How do I set the Sun keyboard key xxxx to an fvwm command? Or
943 more generally, I'm having problems defining key bindings for
944 fvwm - what can I do?
946 A: From Jon Mountjoy, one of fvwm's users:
947 - Function keys on Sun Keyboard on Top Row are F1 - F8
948 - Keys on the function keypad on the Left of the Sun Keyboard
949 are F11 == Stop, F12 == Again, ..., F20 == Cut
953 # Function keys on Sun Keyboard on Top Row
954 Key F1 A N Exec me(netscape) &
955 Key F2 A N Exec me(netscape -install) &
956 Key F5 A N Exec makex(Adder)
957 Key F6 A N Exec makex(Lambda)
958 Key F7 A N Exec makex(Castor)
959 Key F8 A N Exec xterm -T Local &
961 # Keys on the function keypad on the Left of the Sun Keyboard:
962 # F11 = Stop, F12 = Again, ..., F20 = Cut
963 Key F11 AWF N Next (!iconic, CurrentPage) Focus
964 Key F12 AWF N Prev (!iconic, CurrentPage) Focus
965 Key F13 WF N Maximize 100 100
966 Key F15 WF N RaiseLower ""
967 Key F17 WIF N Iconify ""
968 Key F18 WF N Stick ""
969 Key F20 WIF N Delete ""
970 Key Help AWF N Iconify ""
972 A more general solution is to use xev (usually distributed w/ X11)
973 or xkeycaps (an X11 interface to xmodmap written by Jamie Zawinski,
974 available from ftp.x.org) to find out what the keysym for whatever
975 key you want REALLY is, and use that for binding fvwm commands.
977 ----------------------------------------------------------------------
979 3.10 My .fvwmrc from version 1.xx no longer works. What do I do?
981 A: Start with a new one or convert your old one. This can be done by
982 hand or with a little help from the 'fvwm-convert-2.2' in the
985 And here is a list of rc file command changes compiled by Makoto
986 'MAR_kun' MATSUSHITA <matusita@ics.es.osaka-u.ac.jp>. It may or
987 may not be 100% accurate or complete, especially as changes evolve,
988 but it's a good start.
990 Note that there have been some changes in 2.1.x and up that are not
991 reflected in the conversion script yet.
993 ** Fvwm-1.xx commands ** ** Fvwm-2.0.x equivalent **
995 AppsBackingStore (obsoleted)
996 AutoRaise delay (obsoleted, use FvwmAuto)
997 BackingStore (obsoleted)
998 BoundaryWidth Width Style (BorderWidth width)
999 ButtonStyle button# WidthxHeight <-
1000 CenterOnCirculate (obsoleted)
1001 CirculateSkip windowname Style (CirculateSkip)
1002 CirculateSkipIcons Style (CirculateSkipIcon)
1004 ClickToFocus Style (ClickToFocus)
1005 Cursor cursor_num cursor_type CursorStyle context cursornum
1006 DecorateTransients Style (DecorateTransient)
1007 DeskTopScale Scale (obsoleted, use FvwmPager)
1008 DeskTopSize HorizontalxVertical <-
1009 DontMoveOff (obsoleted)
1010 EdgeResistance scrolling moving <-
1011 EdgeScroll horizontal vertical <-
1012 Font fontname MenuStyle (arg4)
1013 Function FunctionName AddToFunc (not compatible)
1014 HiBackColor colorname Style (HilightFore color)
1015 HiForeColor colorname Style (HilightFore color)
1016 Icon windowname bitmap-file Style (Icon iconname-file)
1017 IconBox left top right bottom Style (IconBox l t r b)
1018 IconFont fontname Style (IconFont fontname)
1019 IconPath path ImagePath path
1020 Key keyname Context Modifiers Function <-
1021 Lenience Style (Lenience)
1022 MenuBackColor colorname MenuStyle (arg2)
1023 MenuForeColor colorname MenuStyle (arg1)
1024 MenuStippleColor colorname MenuStyle (arg3)
1025 Module ModuleName <-
1027 Mouse Button Context Modifiers Function <-
1028 MWMBorders Style (MWMBorder)
1029 MWMButtons Style (MWMButtons)
1030 MWMDecorHints Style (MWMDecor)
1031 MWMFunctionHints Style (MWMFunctions)
1032 MWMHintOverride Style (HintOverride)
1033 MWMMenus MenuStyle (arg5)
1034 NoBorder windowname Style (NoBorder)
1035 NoBoundaryWidth Width Style (HandleWidth width)
1036 NoPPosition Style (NoPPosition)
1037 NoTitle windowname Style (NoTitle)
1038 OpaqueMove percentage OpaqueMoveSize percentage
1039 OpaqueResize (obsoleted)
1040 Pager X_Location Y_Location (obsoleted, use FvwmPager)
1041 PagerForeColor colorname (obsoleted, use FvwmPager)
1042 PagerBackColor colorname (obsoleted, use FvwmPager)
1043 PagerFont fontname (obsoleted, use FvwmPager)
1044 PagingDefault pagingdefaultvalue (obsoleted)
1045 PixmapPath ImagePath path
1046 Popup PopupName AddToMenu (not compatible)
1047 RandomPlacement Style (RandomPlacement)
1048 SaveUnders (obsoleted)
1049 SloppyFocus Style (SloppyFocus)
1050 SmartPlacement Style (SmartPlacement)
1051 StartsOnDesk windowname desk-number Style (StartsOnDesk desk-number)
1052 StaysOnTop windowname Style (StaysOnTop)
1053 StdBackColor colorname Style (BackColor color)
1054 StdForeColor colorname Style (ForeColor color)
1055 StickyBackColor colorname (obsoleted)
1056 StickyForeColor colorname (obsoleted)
1057 Sticky windowname Style (Sticky)
1058 StickyIcons Style (StickyIcon)
1059 StubbornIcons (obsoleted)
1060 StubbornIconPlacement (obsoleted)
1061 StubbornPlacement (obsoleted)
1062 Style windowname options <-
1063 SuppressIcons Style (NoIcon)
1064 WindowFont fontname Style (Font fontname)
1065 WindowListSkip windowname Style (WindowListSkip)
1068 ** fvwm-1 built-in functions ***
1071 CirculateDown [ name window_name ] Next (not compatible)
1072 CirculateUp [ name window_name ] Prev (not compatible)
1074 CursorMove horizontal vertical <-
1078 Exec name command <-
1082 Iconify [ value ] <-
1084 Maximize [ horizontal vertical ] <-
1085 Module name ModuleName Module ModuleName
1094 Restart name WindowManagerName <-
1096 Scroll horizonal vertical <-
1098 TogglePage (obsoleted)
1100 Warp [ name window_name ] Next or Prev (not compatible)
1101 WindowsDesk new_desk (obsoleted, use MoveToDesk)
1102 WindowList arg1 arg2 <-
1104 *** New in fvwm-2 **
1124 Menu menu-name double-click-action
1127 Next (conditions) command
1128 None (arguments) command
1131 Prev (conditions) command
1144 (more functions are being added from time to time, so please check
1145 the man page and the NEWS file too).
1147 ----------------------------------------------------------------------
1149 3.11 What happened to the fvwm 1.xx 'include' command?
1151 A: It was actually part of the M4 preprocessing. You can use the
1152 'Read' builtin to get the same effect, or use the FvwmM4 module.
1154 ----------------------------------------------------------------------
1156 3.12 How do I get window titles on sub windows of ... (e.g.
1159 A: These windows are known as 'transient' windows because of their
1160 short lived nature. To get the window decorations for transient
1161 windows you can use the Style command:
1163 Style * DecorateTransient
1165 or to switch it off:
1167 Style * NakedTransient
1169 ----------------------------------------------------------------------
1171 3.13 I just upgraded to version >= 2.3.2, and my configuration
1172 settings disappeared! How do I get them back?
1174 A: The directory for system-wide configuration files changed from
1175 ${sysconfdir} (/usr/local/etc, unless set otherwise at configure
1176 time) to a subdirectory, ${sysconfdir}/fvwm. Move your config
1177 files by hand and restart fvwm.
1179 This change was made because fvwm now installs several files into
1182 ----------------------------------------------------------------------
1184 3.14 Some applications (e.g. Eterm) don't use the icon I defined for
1187 A: Eterm provides its own icon and fvwm does not know if it is a plain
1188 icon or if Eterm wants to draw into it (like xbiff does when you
1189 get new mail). You can explicitly override the application
1190 provided icon with a style command:
1192 Style <application-name> IconOverride
1194 ----------------------------------------------------------------------
1196 3.15 I don't like the gaps in my icon box when I de-iconify an
1197 application. Is there some kind of auto arrange function?
1199 A: Assuming you are using the IconBox option of the Style command
1200 this can be done with a tricky fvwm function. Put the
1201 DeiconifyAndRearrange function below in your configuration file:
1203 DestroyFunc DeiconifyAndRearrange
1204 AddToFunc DeiconifyAndRearrange
1206 + C All (CurrentPage, Iconic) PlaceAgain Icon
1208 This works with fvwm-2.5.3 and later. Older fvwm releases can
1209 achieve the same effect with:
1211 DestroyFunc DeiconifyAndRearrange
1212 AddToFunc DeiconifyAndRearrange
1214 + C All (CurrentPage, Iconic) RecaptureWindow
1216 However, as the Recapture and RecaptureWindow commands may be
1217 removed in the future, please use PlaceAgain instead of
1218 Recapture if possible.
1220 Also, replace all places where you call the Iconify builtin
1221 function to de-iconify an icon with a call to the new function.
1222 For example, replace
1224 DestroyFunc IconFunc
1233 DestroyFunc IconFunc
1235 + C DeiconifyAndRearrange
1238 + D DeiconifyAndRearrange
1242 Mouse 1 I A Iconify off
1246 Mouse 1 I A DeiconifyAndRearrange
1248 ----------------------------------------------------------------------
1250 3.16 How do I set up an fvwm menu item that shuts down my Linux
1253 A: Write a little shell script to run the shutdown command.
1255 Install sudo on your system (see the man page, etc.)
1257 Set up the sudoers config file to allow you, your wife, etc. to run
1258 that script with root permissions.
1260 Add a menu item to your fvwm root menu (or wherever) that invokes
1261 "sudo /my/script/name".
1263 ----------------------------------------------------------------------
1265 3.17 Although the Recapture command is obsolete, do I still need it
1266 to apply certain style changes?
1268 A: Excerpt from the man page:
1270 There are many commands that affect look and feel of specific,
1271 some or all windows, like Style, Mouse, the FvwmTheme module (for
1272 fvwm 2.4.x), Colorsets and many others. For performance reasons
1273 such changes are not applied immediately but only when fvwm is idle,
1274 i.e. no user interaction or module input is pending. Specifically,
1275 new Style options that are set in a function are not applied until
1276 after the function has completed. This can sometimes lead to
1277 unwanted effects. To force that all pending changes are applied
1278 immediately, use the UpdateStyles, Refresh or RefreshWindow commands.
1280 ----------------------------------------------------------------------
1282 3.18 When my specific window (or all windows) pops up, I want it to
1283 get focus/be moved/be resized/be closed/be shaded... How?
1285 A: The following discusses a general solution, you should substitute
1286 the application names used in the examples as well as fvwm commands
1287 (Move, Iconify, Close) with the ones you need. To get resource
1288 names of an application you want to catch, use FvwmIdent module.
1290 The first possible approach to achieve what you want is to have a
1291 separate function to start your application, like:
1293 DestroyFunc StartKedit
1294 AddToFunc StartKedit
1297 + I Next (kedit) Resize 100p 200p
1299 This approach has 3 problems:
1300 1) You need to use StartKedit function to start your application,
1301 this will not work if you start it from the command line.
1302 2) If for some reason the application is not started, fvwm waits
1303 for it in Wait, you will need to press Ctrl-Alt-Esc.
1304 3) If you have more than one kedit window, it is not guaranteed
1305 that the right one is resized.
1307 But this approach has one plus - it also enables any fvwm commands
1308 that you may want to issue before executing your command. For
1309 example, to start kedit window iconic, but not affect its
1310 subwindows, you can use:
1312 DestroyFunc StartAppIconic
1313 AddToFunc StartAppIconic
1314 + I Style $0 StartIconic
1317 + I Style $0 StartNormal
1320 StartAppIconic kedit /tmp/my.txt
1323 The second approach is to use FvwmEvent, this solves the first two
1324 problems (in fvwm 2.2) or all three problems (in fvwm 2.3 and
1327 The sample to use with fvwm 2.2.3+ versions (this resizes the newly
1328 created window "My Window", supposing you have only one such
1331 DestroyModuleConfig FvwmEvent*
1332 *FvwmEvent add_window SetGeometryForMyWindow
1334 DestroyFunc SetGeometryForMyWindow
1335 AddToFunc SetGeometryForMyWindow
1336 + I Next ("My Window") Move +10p +10p
1337 + I Next ("My Window") Resize 100p 200p
1339 AddToFunc StartFunction I Module FvwmEvent
1341 The sample to use with fvwm 2.3.21 to 2.4.15 versions (consider to
1342 upgrade and use the version below). This moves a newly created
1343 window named "My Window", and warps a pointer to all new windows
1344 regardless of their name:
1346 *FvwmEvent-NewWindow: Cmd
1347 *FvwmEvent-NewWindow: PassId
1348 *FvwmEvent-NewWindow: StartDelay 4
1349 *FvwmEvent-NewWindow: add_window FuncFocusWindow
1351 DestroyFunc FuncFocusWindow
1352 AddToFunc FuncFocusWindow
1353 + I WindowId $0 ("My Window") Move 200p 100p
1354 + I WindowId $0 Focus
1355 + I WindowId $0 WarpToWindow
1357 AddToFunc StartFunction I FvwmEvent FvwmEvent-NewWindow
1359 And finally the suggested configuration for 2.5.7+ and
1360 2.4.16+. This moves a newly created window named "My Window", and
1361 wraps a pointer to all new windows regardless of their name:
1363 *FvwmEvent-NewWindow: StartDelay 4
1364 *FvwmEvent-NewWindow: add_window FuncFocusWindow
1366 DestroyFunc FuncFocusWindow
1367 AddToFunc FuncFocusWindow
1368 + I ThisWindow ("My Window") Move 200p 100p
1372 AddToFunc StartFunction I FvwmEvent FvwmEvent-NewWindow
1374 ----------------------------------------------------------------------
1376 3.19 When my specific window (or all windows) is closed, I want to
1377 switch desks/wrap to my app X/popup a menu/start app X... How?
1379 A: Please read the answer to the previous question to understand
1382 Again, there are two approaches. The first is good in one kind of
1383 situations, bad in others:
1385 DestroyFunc StartKedit
1386 AddToFunc StartKedit
1387 + I Exec kedit; xmessage -name DummyWindow -g +10000+10000 "dummy"
1388 + I Wait DummyWindow
1389 + I Exec xmessage -timeout 10 "Sorry, you can't close kedit"
1392 The second approach is to use FvwmEvent:
1394 *FvwmEvent-OldWindow: Cmd
1395 *FvwmEvent-OldWindow: PassId
1396 *FvwmEvent-OldWindow: destroy_window FuncPopupMyMenu
1398 DestroyFunc FuncPopupMyMenu
1399 AddToFunc FuncPopupMyMenu
1400 # go to the desk 0 when any window is closed
1402 # popup my menu when "panel" is closed
1403 + I WindowId $0 ("panel") Popup MenuFvwmRoot
1405 AddToFunc StartFunction I FvwmEvent FvwmEvent-OldWindow
1407 ----------------------------------------------------------------------
1409 3.20 I have a multi head setup (multiple screens used under X). How
1410 can I tell fvwm to use different configurations for the screens?
1412 A: Fvwm spawns itself into all found screens unless -s command line
1413 parameter is specified, as explained in the man page. All spawned
1414 fvwm processes by default use the same configuration on each
1415 screen. There are several ways to change the default behavior.
1417 Write your configuration file as you would if you had only one
1418 screen. Then move the screen specific lines into separate
1419 configuration files and call them, for example, config.<screen>
1420 where <screen> is the screen number. Usually this will be 0 for
1421 the main screen and 1 for the secondary screen. Place the screen
1422 specific files in the $HOME/.fvwm directory or whatever you set
1423 $FVWM_USERDIR to. Now add this line to your config file:
1425 Read config.$[screen]
1427 The $[screen] will be replaced with the number of the screen each
1428 instance of fvwm is started on.
1431 Another method, which should work for older fvwm versions as well,
1432 is to specify a separate file for each screen explicitly. For
1433 this, start a separate fvwm for each screen in your .xinitrc (or
1436 fvwm -s -d :0.0 -f config-0 &
1437 fvwm -s -d :0.1 -f config-1 &
1438 fvwm -s -d :0.2 -f config-2
1440 Note that only the last command is without a trailing ampersand.
1441 If you wish, config-* files may all include "Read config-common".
1443 ----------------------------------------------------------------------
1445 3.21 How do I maximize a window but not cover up FvwmTaskBar?
1447 A: Instead of Maximize use "Maximize 100 -30p" where 30 is the width
1448 of your FvwmTaskBar.
1450 Or use EwmhBaseStruts in Fvwm 2.5.x or later.
1452 ----------------------------------------------------------------------
1454 3.22 Why my close button looks pressed in maximized windows?
1455 Why don't buttons show on the titlebar of some windows?
1457 A: Fvwm has some builtin idea of what the buttons do, and some
1458 applications can request that certain buttons not be shown.
1459 For example, it's normal for Fvwm to suppress the iconify button
1460 (builtin button 4, the second button from the right) on a
1461 transient (dialog) window.
1465 Style * DecorateTransient
1467 tells fvwm you want titles and buttons on transient windows.
1469 Style * MwmFunctions
1471 tells fvwm to accept application hints to hide certain buttons.
1473 ButtonStyle 2 - Clear MWMDecorMin
1475 says button 2 performs the minimize (iconify) function.
1479 makes any mouse button on button 2 iconify the window.
1480 Buttons won't show until some action is assigned to them using
1481 Mouse or Key commands.
1483 Things to look for in the man page are:
1485 DecorateTransient, MwmDecorXXX, MwmFunctions
1487 So, if you use Windows-like buttons, then redefine button hints:
1489 ButtonStyle 1 - Clear MWMDecorMenu
1490 ButtonStyle 2 - Clear
1491 ButtonStyle 4 - Clear MWMDecorMax
1492 ButtonStyle 6 - Clear MWMDecorMin
1494 Finally, this command makes button relief to follow the state:
1498 ----------------------------------------------------------------------
1500 3.23 How to define transparent menus?
1502 A: First, it may help to read about colorsets in fvwm and FvwmTheme
1505 We speak about transparency, not translucency here. This means
1506 the background of the parent window (for example the root window)
1507 will be used for our "transparent" areas, this is not always the
1508 window under our "transparent" window. However, it is possible
1509 to get a real transparency (i.e. translucency) by applying one
1510 patch and using new Colorset Translucent option the patch adds.
1511 We do not discuss this here, however you may get this patch with
1512 README.patch included from:
1514 http://fvwm-themes.sf.net/patch/
1517 To define a transparent colorset, use something like:
1519 Colorset 23 Transparent, fg rgb:ff/ff/c4, bg darkgray
1521 (you may use any other number greater than 0 instead of 23)
1523 There is another way to define transparent colorset, by using
1524 RootTransparent instead of Transparent, but please remember,
1525 you should use a good utility to set the root background image,
1526 like "fvwm-root -r" or "Esetroot" or "wmsetbg", otherwise
1527 RootTransparent will not work:
1529 Colorset 23 RootTransparent, fg rgb:ff/ff/c4, bg darkcyan
1531 The good thing about RootTransparent is that it is possible to
1532 automatically calculate the average background color (used for
1533 highlighting/shading) and efficiently tint the visible part of the
1534 root image using something like:
1536 Colorset 23 RootTransparent, fg rgb:ff/ff/c4, bg average, \
1537 Tint black 20, bgTint black 20
1539 If you have enough memory, you may use "RootTransparent buffer"
1540 to speed up transparent menus, modules or decorations.
1542 If you are not sure whether you use "fvwm-root -r" or similar
1543 utility to set the root background, do not use RootTransparent
1544 option, use Transparent option without tinting, and set the bg
1547 Once a transparent colorset is defined, use it in menus:
1549 MenuStyle * MenuColorset 23
1551 See the man pages for a more complete explanation of colorsets.
1553 ----------------------------------------------------------------------
1555 3.24 How to define transparent modules?
1557 A: See question 3.23 to learn how to define a transparent colorset
1558 (you may reuse the same transparent colorset or define separate
1559 colorsets for different modules).
1561 Then read the man page for your specific module that you want to
1562 make transparent and specify this transparent colorset(s), like:
1564 *FvwmPager: Colorset * 23
1565 *FvwmButtons: Colorset 23
1566 *FvwmIconMan: Colorset 23
1568 Style FvwmPager ParentalRelativity
1569 Style FvwmButtons ParentalRelativity
1570 Style FvwmIconMan ParentalRelativity
1572 A side note: the ParentalRelativity option is not always needed.
1573 It is not needed if you use RootTransparent or you never intend to
1574 move a module inside its parent, or you swallow a module, since
1575 FvwmButtons adds ParentalRelativity automatically for swallowed
1576 fvwm modules. Otherwise you need Style ParentalRelativity for
1577 transparent windows, but doing this for all windows is overhead.
1579 Note, that previously "Pixmap none" option was used to define
1580 transparency; Pixmap option is obsolete, use colorsets instead.
1582 If you swallow FvwmPager (or FvwmIconMan) into FvwmButtons, then
1583 you may configure both FvwmPager and FvwmButtons to be transparent
1584 or just one of them to be transparent, depending on what you want
1587 ----------------------------------------------------------------------
1589 3.25 How to define transparent decorations?
1591 A: See question 3.23 to learn how to define a transparent colorset.
1592 Only RootTransparent method works for transparent decorations!
1593 This basically means that you should use external utilities like
1594 "wmsetbg" or "Esetroot" to set background in JPG/GIF/TIFF format
1595 and our utility "fvwm-root -r" for XPM/PNG images.
1597 To get transparent decorations, use a configuration like this:
1599 AddToFunc StartFunction
1600 + I Exec fvwm-root -r $HOME/wallpapers/sea.png
1602 Colorset 41 RootTransparent buffer, fg white, bg average, \
1603 Tint cyan 15, bgTint cyan 15 # tint is optional
1604 Colorset 42 RootTransparent buffer, fg white, bg average, \
1605 Tint red 15, bgTint red 15 # tint is optional
1607 Style * Colorset 41, HilightColorset 42 # to use fg and bg
1608 BorderStyle Inactive Colorset 42 -- flat
1609 BorderStyle Active Colorset 41 -- flat
1610 TitleStyle AllInactive Colorset 42 -- flat
1611 TitleStyle AllActive Colorset 41 -- flat
1612 ButtonStyle All -- UseTitleStyle flat
1614 It is possible to define partially transparent decorations too.
1615 You may achieve this by adding "AddTitleStyle Colorset NN PP",
1616 or even "TitleStyle Colorset NN PP". Please read the man page.
1617 Also search in fvwm-themes to see whether some theme provides
1618 the window decoration look similar to what you want to achieve.
1620 ----------------------------------------------------------------------
1622 3.26 How about transparent applications too?
1624 A: This is not really an fvwm related question, you should find X
1625 applications supporting transparency and read their documentation.
1627 Depending on the application you should set the root image in one
1628 or another way. Usually utilities like fvwm-root (with possible
1629 "-r" parameter), Esetroot or wmsetbg should be used.
1631 There is a wide range of terminal emulators that may be configured
1632 to be transparent, like Eterm, aterm, gnome-terminal and others.
1633 Here is an example command line:
1635 aterm -ls -sh 70 -bg black -fg white -tr +sb -fn 7x14 -fb 7x14bold
1637 Some applications have transparent theme, e.g. gkrellm and xmms.
1639 Some applications may show text on the root image, e.g. root-tail.
1641 There are a lot of other applications supporting transparency not
1642 listed here, search in FreshMeat, http://freshmeat.net/.
1644 ----------------------------------------------------------------------
1646 3.27 How can I define emacs type multi-keystroke fvwm bindings?
1648 A: In emacs, keys can be set up as prefix keys, so that once
1649 you type the prefix key, a subsequent key has a special meaning.
1650 For example, Control-a would normally go to the beginning of a line
1651 but Control-c Control-a might do something completely different.
1652 There are at least 2 ways to do the same thing with fvwm.
1654 The simplest technique is to use the prefix key to invoke a menu
1655 and then use the menu hot keys as the second key in the binding.
1656 Since menu hot keys don't include modifiers, you can only use plain
1657 keys for the second key in the sequence.
1659 This second technique lets you use any key for the second key but
1660 only works with 2.5.x or later.
1661 This approach invokes a function on the first key that defines the
1662 action of the second key for a short time and then removes it:
1664 DestroyFunc Ctrl-Alt-F-Action
1665 AddToFunc Ctrl-Alt-F-Action
1666 + I Key X A A Exec xterm
1667 + I Key C A A Exec xcalc
1668 # optionally popup a prompt window here
1669 + I Schedule 5000 Key X A A -
1670 + I Schedule 5000 Key C A A -
1672 # Press Ctrl-Alt-F and then "x" or "c"
1673 Key F A CM Ctrl-Alt-F-Action
1675 With this, you press the second key in 5 seconds otherwise the
1676 binding for the second key is removed.
1679 With fvwm-2.5.24 or later (using SendToModule) a much better
1682 SendToModule buttons-alias PressButton A 1
1684 This would send the FvwmButtons instance "button-alias" a command
1685 to invoke the action that button "A" has as though the button were
1686 clicked with mouse button 1. For instance:
1688 *button-alias: (Id A, Title "My Button", Action (Mouse 1) \
1691 ----------------------------------------------------------------------
1693 3.28 How do I remove all decorations from a window?
1696 A: I see this a lot on IRC. Most people try and do this:
1698 Style * !Title, BorderWidth 0
1700 This doesn't always work because many forget about a window having
1701 having handles -- which sit on the border. If a window has defined
1702 handles, then these effectively override any of border settings --
1703 especially the "BorderWidth" option. But there are Handle
1704 equivalents, hence the correct way to remove decorations from a window
1707 Style * !Title, !Borders, !Handles
1709 To set the BorderWidth of a window which has handles:
1711 Style * HandleWidth 5
1713 ----------------------------------------------------------------------
1715 3.29 What's the best way to make on-the-fly config changes?
1717 A: Often is the case, one might want to make config changes to fvwm.
1718 Adding them to the .fvwm2rc file (or in more recent releases
1719 .fvwm/.fvwm2rc or ~/.fvwm/config) and then restarting fvwm is one
1720 way -- but this has problems with memory, especially with Colorset
1721 definitions being redeclared, etc.
1723 The better approach to making changes is instead to use FvwmConsole
1724 which is a way of making live changes to fvwm configs. When you're
1725 satisfied that they're correct, then you can add them to your fvwm
1726 config file so that they're there the next time fvwm loads, thus
1727 reducing the need to restart fvwm.
1729 ======================================================================
1731 ======================================================================
1733 4.1 I'm using FvwmButtons (or GoodStuff in 1.xx), and sometimes the
1734 buttons stay depressed, and other times they don't. Why is that?
1736 A: From the FvwmButtons man page:
1738 If command is an fvwm Exec command, then the button
1739 will remain pushed in until a window whose name or
1740 class matches the quoted portion of the command is
1741 encountered. This is intended to provide visual
1742 feedback to the user that the action he has requested
1743 will be performed. If the quoted portion contains no
1744 characters, then the button will pop out immediately.
1745 Note that users can continue pressing the button, and
1746 re-executing the command, even when it looks "pressed
1749 ----------------------------------------------------------------------
1751 4.2 When having FvwmButtons swallow an app, is it possible to have
1752 button presses assigned to actions as well? For instance, I'd
1753 like to swallow xload and have a button press pop up an xterm, or
1754 swallow xbiff and have a button press bring up the list of
1757 A: Yes, with the alpha release 2.5.0 or any later release. For older
1760 The button presses normally get passed through to the swallowed
1761 application, but if you put a title on the button, you can
1762 assign actions to that. Here's an example that someone sent to
1763 the mailing list once:
1766 Title 'System Info', \
1767 Swallow "xload" 'Exec xload', \
1768 Action(Mouse 1) 'Exec xosview -cua0 -net 200 -ul -l -geometry 325x325', \
1769 Action(Mouse 2) 'Exec xcpustate -interval 1 -bg "#a4978e" -fg black', \
1770 Action(Mouse 3) 'Exec rxvt -fg "khaki" -bg "dark olive green" \
1771 -fat -n top -T Top -7 -e top' )
1773 And you could come up with something similar for xbiff (untested):
1776 Title 'Check Mail' Swallow "xbiff" 'Exec xbiff', \
1777 Action(Mouse 1) 'Exec from | xmessage -file -' )
1779 plus you could bind another button (say Mouse 3) to run your
1782 Sometime in the future I'll probably try and fix it so that you can
1783 actually assign a button press over the application itself...
1785 ----------------------------------------------------------------------
1787 4.3 I'm seeing odd things when trying to preprocess files with the
1788 FvwmM4/Cpp module...
1790 A: Yup, I imagine that you might be. Things like the InitFunction not
1791 being called or windows that were running before fvwm started not
1792 getting their Borders & Style options set, etc.
1794 The reason for all this is because of the fact that FvwmM4 is a
1795 module. Fvwm won't be looking at the commands coming back from
1796 the module until after it hits the main loop of the code, AFTER the
1797 startup is all done and it has already tried to execute the
1800 To force synchronous execution of FvwmM4/Cpp use:
1802 ModuleSynchronous FvwmM4/Cpp -lock filename
1804 See the man page for more details.
1806 ----------------------------------------------------------------------
1808 4.4 I heard about this FvwmFileMgr module. Where can I find it?
1810 A: The FvwmFileMgr module disappeared because a file manager doesn't
1811 need to be integrated with a window manager and something like xfm
1812 does a much better job. I recommend you pick that up instead (from
1813 ftp.x.org or your favorite mirror).
1815 ----------------------------------------------------------------------
1817 4.5 I used to use GoodStuff in fvwm 1.xx, but it's not in the 2.xx
1818 distribution. What do I use now?
1820 A: GoodStuff was renamed to FvwmButtons. Same module, new name (that
1821 fits in with the other modules naming convention).
1823 ----------------------------------------------------------------------
1825 4.6 I want to have the sub panels in FvwmButtons not at their default
1826 position near the button but somewhere else on the screen. Is
1829 A: Yes, but not with the current implementation of the panels. Please
1830 read question 7.12 for instructions.
1832 ----------------------------------------------------------------------
1834 4.7 How can I open a sub panel or push buttons in FvwmButtons
1835 with a keyboard shortcut?
1837 A: FvwmButtons does not support keyboard shortcuts itself. Since
1838 fvwm version 2.3.24 the FakeClick command can be used to
1839 simulate a click in the FvwmButtons window:
1841 fvwm-2.3.24 or later:
1843 DestroyFunc press_fvwmbuttons
1844 AddToFunc press_fvwmbuttons
1845 + I Next (FvwmButtons, CirculateHit) WarpToWindow $1 $2
1846 + I FakeClick depth 2 press $0 release $0
1848 fvwm-2.5.1 or later (moves the pointer back to the original
1851 DestroyFunc press_fvwmbuttons
1852 AddToFunc press_fvwmbuttons
1853 + I SetEnv pointer_x $[pointer.x]
1854 + I SetEnv pointer_y $[pointer.y]
1855 + I Next (FvwmButtons, CirculateHit) WarpToWindow $1 $2
1856 + I FakeClick depth 2 press $0 release $0
1857 + I WindowId root WarpToWindow $[pointer_x]p $[pointer_y]p
1859 With this function, you can warp the pointer to the desired
1860 button to press and simulate a click. Call it with
1862 press_fvwmbuttons btn xoff yoff
1864 | | |___ y offset of the button
1865 | |________ x offset of the button
1866 |_____________ button to press
1868 For example, if the button of a panel is at 30% of FvwmButtons'
1869 width and 10% of its height and you want to simulate mouse
1872 press_fvwmbuttons 1 30 10
1874 You can bind this to a key. For example:
1876 Key f1 a n press_fvwmbuttons 1 30 10
1878 Note that this solution does not work well if the mouse is moved at
1881 With fvwm-2.5.24 or later (using SendToModule) a much better
1884 SendToModule buttons-alias PressButton A 1
1886 This would send the FvwmButtons instance "button-alias" a command
1887 to invoke the action that button "A" has as though the button were
1888 clicked with mouse button 1. For instance:
1890 *button-alias: (Id A, Title "My Button", Action (Mouse 1) \
1894 ======================================================================
1895 5 - Development, Known Problems & Bug Reports
1896 ======================================================================
1898 5.1 I'd really like to see neat feature XYZ in fvwm. Wouldn't
1899 that be cool? I even have a patch. When can it be added?
1901 A: If you plan to write a patch, *please*, first of all fetch the
1902 latest development release from our web site or better yet use CVS
1903 as described in http://fvwm.org/documentation/dev_cvs.php. It is
1904 also a good idea to contact the fvwm-workers list. At times,
1905 patches for older releases may prove completely worthless, e.g.
1906 because the fix has already been integrated, a feature already
1907 added or removed or simply because the code is very different to
1908 the code you patches. You will do yourself and us a great favor.
1909 Otherwise all your hard work may be wasted.
1911 People are always requesting or suggesting new features (many of
1912 which are great ideas and where a lot of the current features came
1913 from). One of the more common ones for example is Windows 95 look
1914 and feel (although since this was first written, that particular
1915 feature has actually been indirectly implemented via several
1916 appearance-affecting features).
1918 I'd like to make a statement about this. fvwm is supposed to be
1919 small, fast, powerful, and flexible, and sometimes tradeoffs have
1920 to be made here. The module interface helps here, as a lot of
1921 features that not everyone wants or needs don't have to be in the
1922 main module consuming resources for those people that don't want or
1925 So if you have a suggestion (or a patch), please think of a way to
1926 make it as small and generic as possible if you feel it belongs in
1927 the main module. Please have a look at the enhancements that are
1928 listed in our bug tracking system (see Q5.3).
1930 If you plan to make a patch, please contact the fvwm-workers
1931 mailing list first. From time to time we are changing the code in
1932 a very disruptive way and if you create a patch to a version before
1933 such changes were made we will all have a hard time to integrate
1934 the patch. Most of the time we will ask you to update the patch
1935 for the current code anyway.
1937 Bear in mind that we make no guarantees that we'll add any
1938 requested feature or apply any submitted patches to the official
1939 version, but please don't let this dissuade you from submitting
1940 them. We like to get new ideas and we're always curious to see how
1941 someone would implement a given feature, even if we never plan to
1942 put it in fvwm. Also, we may choose to re-implement any patches
1943 submitted, which may change the syntax, functionality, etc. Please
1944 don't take offense from that, as we mean no offense and we
1945 generally have a good reason (at least by our way of thinking) for
1948 ----------------------------------------------------------------------
1950 5.2 How do I create/submit/apply patches?
1952 A: First of all, please read the first section of the answer to Q5.1!
1954 Please add proper entries to the ChangeLog file(s) and possibly to
1955 NEWS and AUTHORS files whenever you submit a patch. The ChangeLog
1956 lists *all* changed files and functions along with a useful
1957 explanation of the change details. The NEWS file mentions all
1958 user-visible changes, including bug fixes. Also, do not forget to
1959 write a section for the man page if the patch includes new
1962 You can find more detailed instructions for working with the
1963 fvwm sources in the files doc/DEVELOPERS and doc/CONVENTIONS in
1964 CVS or the tarballs.
1966 Creating a patch against CVS sources (preferable) -
1968 1) Execute "cvs update -AdP" to ensure there are no conflicts
1969 with the most recent sources.
1970 2) Don't forget to update the ChangeLog file (see below) and
1971 all manual pages if needed.
1972 3) In the base cvs directory run: cvs diff -u >myfeature.patch
1974 Creating a patch against released sources -
1976 1) Copy the original file(s) to the same name with the
1977 additional extension of .orig (or something like that).
1978 2) Update the ChangeLog file. If you use (x)emacs, move the
1979 cursor into the function you changed and hit <ctrl>-x 4 a.
1980 This will generate an empty ChangeLog entry in the right
1981 file (there are several ChangeLogs). Add a description of
1982 what you did. Do this each time you change a function or
1983 file (for changes outside of functions). You should update
1984 the AUTHORS and NEWS files too if appropriate.
1985 Please take the time to add the ChangeLog entries, it makes
1986 our work a lot easier.
1987 3) Run diff with either the -c (context) or -u (unified)
1988 switch on the sets of files, with the .orig file FIRST. I
1989 prefer unified diff's because they are smaller, but
1990 sometimes they aren't as readable (and some diff versions
1991 don't support unified diffs), so either context or unified
1992 diffs are fine (but please, no "plain" diffs).
1994 ex: cp fvwm.c fvwm.c.orig ; <edit> ; diff -u fvwm.c.orig fvwm.c
1996 Submitting a patch -
1998 Mail it to the fvwm-workers mailing list
1999 <fvwm-workers@fvwm.org>.
2001 If your patch is large you should compress it (preferably with
2002 gzip). Should it still be larger than 25k you might want to
2003 to place it on a web page and email the URL to the mailing
2004 list or ask on the fvwm-workers list first.
2006 Be sure to read the answer to Q5.1.
2008 Don't forget the ChangeLog and the documentation.
2012 Get a copy of the program 'patch' from your favorite source,
2013 such as ftp://ftp.gnu.org/gnu/patch/, compile it, and then
2014 follow its directions (generally just cd into the appropriate
2015 directory and run 'patch < patchfile').
2017 ----------------------------------------------------------------------
2019 5.3 How do I submit a bug report?
2021 A: Please do not report any 'bugs' related to XMMS in the fvwm bug
2022 tracking system or the fvwm mailing lists but send them to the XMMS
2025 Please enter a DETAILED description of your problem in our
2026 web-based bug-tracking system. You can find a link on our web page
2027 (see Q1.3). By detailed we mean more than just "my window isn't
2028 behaving right" or "I found a bug":
2030 - First of all: use our bug tracking system! You will find
2031 a link to it on our main web page (see Q1.3). If for some
2032 reason the bug tracking system doesn't work for you, please
2033 use the fvwm-bug shell script that comes with fvwm.
2034 - Describe the problem as best you can, preferably with
2035 suggestions on how to reproduce it easily
2036 - If applicable, include information from:
2037 xwininfo (preferably w/ the -all option)
2041 - What exact version of fvwm you are running.
2042 - What OS & version you are running under
2043 - What version of X11 are you running under, and is it an MIT
2044 server or a vendor specific server (e.g. the OpenWindow X
2046 - How was fvwm compiled (compiler & version, options, etc)
2047 - What settings do you have in your config file that may be
2050 ----------------------------------------------------------------------
2052 5.4 I have a window that is behaving unexpectedly under fvwm, but
2053 just fine under (whatever other window manager), or I have just
2054 some random bug. What do I do?
2056 A: First, check your rc file and your .Xdefaults to make sure that
2057 something blatantly obvious in there isn't causing the problem.
2058 Second, *PLEASE PLEASE PLEASE* check the FAQ, BUGS, TODO, and man
2059 pages. Finally, check the official WWW page and the mailing list
2060 archives (which have a search facility) stored there.
2062 If you still can't figure it out, report your problem to our bug
2063 tracking system (see Q5.3).
2065 ----------------------------------------------------------------------
2067 5.5 Why do NumLock, CapsLock and ScrollLock interfere with
2068 ClickToFocus and/or my mouse bindings?
2070 A: Because they are treated as modifiers. You can use the
2071 IgnoreModifiers command to turn individual modifiers off for
2072 bindings. With XFree86 and fvwm version 2.4.0 or above, the
2077 If you changed your modifiers manually or are using a different
2078 X server use the 'xmodmap' command to find out which modifiers
2079 correspond to the keys you want to switch off.
2081 This command creates a lot of extra network traffic, depending
2082 on your CPU, network connection, the number of Key, Mouse or
2083 PointerKey commands in your configuration file and the number
2084 of modifiers you want to ignore. If you do not have a
2085 lightning fast machine or very few bindings you should not
2086 ignore more than two modifiers. So do not ignore scroll-lock
2087 if you have no problem with it.
2089 A better way to solve this problem is to modify the keyboard
2090 mapping of your X server. The commands
2092 xmodmap -e "clear Lock"
2093 xmodmap -e "clear Mod2"
2094 xmodmap -e "clear Mod5"
2096 remove the CapsLock, NumLock and ScrollLock from the keyboard
2097 map. Pressing these keys has no effect then. To re-add them
2100 xmodmap -e "add Lock = Caps_Lock"
2101 xmodmap -e "add Mod2 = Num_Lock"
2102 xmodmap -e "add Mod5 = Scroll_Lock"
2104 Fvwm has to be restarted to use the changes made by
2105 xmodmap. Please refer to the man page of the xmodmap command
2106 for further details. If you disable the CapsLock key in your
2107 keyboard map in this way, you can speed up fvwm a bit by
2108 removing the Lock modifier from the list of ignored modifiers:
2113 Since we all occasionally press NumLock or ScrollLock, it makes
2114 sense to redefine some main bindings to work with any modifiers.
2115 I.e. consider to replace something like this in your configuration:
2117 Mouse 1 R N Menu MenuFvwmRoot
2121 Mouse 1 R A Menu MenuFvwmRoot
2123 ----------------------------------------------------------------------
2125 5.6 Menus with gradient backgrounds flicker or are very slow.
2127 A: The flickering is caused by fvwm constantly redrawing the menus
2128 when a sub menu pops up or down. One way to help this is to use
2129 a X server with backing storage (XFree86 has backing storage
2130 support, I don't know about other servers but I guess that any
2131 decent X server has it). If your Xserver is started with the
2132 -bs option, remove it. If not try the -wm option, for example:
2136 You may have to adapt this example to your system (e.g. if you
2137 use xinit to start X).
2139 If that doesn't help, either because your X server does not have
2140 backing storage or because system resources are limited, make
2141 sure sub menus do not overlap the parent menu:
2143 MenuStyle <stylename> PopupOffset 1 100
2145 Unfortunately this does not work properly with the fvwm
2148 For the speed problem both suggestions above might help too.
2149 Another thing to try is to turn hilighting of the active menu
2150 item other than by foreground color off. Put these lines in your
2151 fvwm/config after the menu styles have been defined:
2153 MenuStyle <stylename> Hilight3DOff, HilightBackOff
2154 MenuStyle <Stylename> ActiveFore <preferred color>
2156 ----------------------------------------------------------------------
2158 5.7 Why won't the StartIconic style work with {Netscape, etc.}?
2160 A: The application won't allow it. This has only been observed with
2161 Netscape. When Netscape starts up, fvwm starts the main window in
2162 the iconic state. Netscape immediately issues another MapRequest,
2163 to which the window manager must respond by de-iconifying the
2164 window, according to the ICCCM rules. (Netscape can be persuaded
2165 to start iconic, however, by invoking it with the -iconic command
2168 ----------------------------------------------------------------------
2170 5.8 How do I capture the output (e.g. errors) of fvwm?
2172 A: Errors are reported to the standard error file. You can redirect
2173 standard error to a file when fvwm is started: "fvwm 2>
2174 fvwm-errors". X sessions started by xdm often redirect errors to a
2175 file named ".xsession-errors".
2177 Alternatively, FvwmConsole or "FvwmForm FvwmForm-Talk" modules
2178 will display error messages.
2180 ----------------------------------------------------------------------
2182 5.9 I try to run some program under fvwm, but it dies with an X11
2183 error like BadAccess. The same program works just fine under MWM
2184 or OLWM. What's going on?
2186 A: The error message usually looks something like this:
2188 X Error of failed request: BadAccess (attempt to access private
2190 Major opcode of failed request: 28 (X_GrabButton)
2191 Serial number of failed request: 1595
2192 Current serial number in output stream: 1596
2194 Well, this is telling you that there is a conflict in key/button
2195 assignments. In your config you have bound some key/button that
2196 this program really wants to bind to an action, but it can't since
2197 fvwm has already done so (but you weren't doing it in the rc file
2198 for your previous window manager). Figure out what the offending
2199 key binding is and remove it from your fvwm/config, or temporarily
2200 via "FvwmForm FvwmForm-Talk" by removing the fvwm binding (see the
2201 man page for the Key & Mouse commands).
2203 ----------------------------------------------------------------------
2205 5.10 Every time I update my install, my currently running fvwm
2206 session dies. Why is that?
2208 A: Many OSes swap the program from memory via the image on the disk,
2209 and if you overwrite it, and then the current one tries to swap
2210 something back into memory before you restart, it'll core dump. To
2211 avoid this, rename your old executables or move them to some other
2212 directory. The 'mv' command preserves the inode so it won't
2213 core dump, but then when you restart fvwm it'll pick up the new
2216 ----------------------------------------------------------------------
2218 5.11 After I restart fvwm certain windows or icons raise above
2219 all other windows and cannot be lowered by any means. One
2220 example are the shortcuts of KFM (the KDE file manager).
2221 What can I do about that?
2223 A: Some applications use so called 'override redirect' windows that
2224 are not (and cannot be) managed by the window manager. By
2225 convention as defined in the ICCCM, such windows must only be
2226 displayed for a very short time. KFM and possibly other
2227 applications ignore this convention and use permanent 'override
2228 redirect' windows, e.g. the KFM shortcuts. Fvwm can not easily
2229 detect these windows when it restarts and places the windows
2230 managed by fvwm below them.
2232 However, since fvwm version 2.3.8 there is a command that will
2233 help you, although it might cause trouble with other applications
2234 using 'override redirect' windows. We can't make any promises
2235 since KFM is violating the conventions and the applications may
2236 violate them in different ways.
2238 Now the command. Put this anywhere in your config file:
2240 BugOpts RaiseOverUnmanaged on
2242 ----------------------------------------------------------------------
2244 5.12 The StartsOnPage style does not work for me. Why?
2246 A: Many applications request a specific position where they want to
2247 appear (the so called 'program specified position'). Unless fvwm
2248 is told explicitly to ignore this, the program specified position
2249 overrides the StartsOnPage style. Use this line in your
2254 ----------------------------------------------------------------------
2256 5.13 Some modules can not be started when I restart fvwm.
2258 A: You may see the following error message on the console:
2260 [fvwm][PositiveWrite]: <<ERROR>> Failed to read descriptor:
2262 - terminate signal=N
2264 It means that fvwm has given up waiting for one of its modules to
2265 reply, and so has killed it. The length of the timeout is a
2266 configuration parameter - try adding
2270 to your config file. The units are in seconds and the default
2273 This problem will only occur on slow machines or high system load
2274 (many open windows).
2277 ----------------------------------------------------------------------
2279 5.14 I'm running Rational Rose and fvwm ignores its windows.
2281 A: This problem might occur on other applications besides the one
2284 The symptoms as reported by Raymond Toy are:
2286 I've been using fvwm for ages and it's always worked for me just
2287 fine. However, I've started using Rational Rose for Solaris. fvwm
2288 seems to get completely confused.
2290 o Fvwm doesn't draw any frames around the Rose window like it
2291 does for all other windows (except for those I explicit said
2294 o The Rose window is always on top. Nothing I do can bring
2295 another window above the Rose window.
2297 o Using fvwm's identify window module shows nothing. No identify
2298 window pops up showing the window info.
2300 o Focus sometimes seems to be lost. (I have focus follows
2301 mouse). I have to move the mouse out of the window and back in
2302 to get focus. Sometimes I also have to click in the window to
2305 The annoying thing is that this all seems to work with CDE and
2306 dtwm. I don't want to have to switch to dtwm so any hints or
2307 pointers on where to look to get fvwm to understand this window
2308 would help me a lot.
2311 Heres what we found out:
2313 Rational Rose uses software from Mainsoft that lets MS Windows
2314 applications be recompiled to run on UNIX.
2316 There are 2 Mainsoft Knowledgebase pages that relate to UNIX
2319 http://www.mainsoft.com/kb_mainwin/kbmw0027.html
2320 http://dev.mainsoft.com/Default.aspx?tabid=58 [KBMW0034]
2322 These pages suggest that you export MWWM=allwm or MWWM=MWM before
2323 starting the application. The first page is missing, but can be
2324 found using http://web.archive.org.
2328 This works just fine! Setting MWWM=allwm, Rose comes
2329 up like a normal X app where the WM draws the borders.
2330 With MWWM=MWM, it works ok too except that for the main
2331 window, no borders are drawn by the WM and Rose draws
2332 its own borders (I have fvwm respecting MWM decor
2333 hints). (This is correct as mentioned by the
2334 Knowledgebase pages above.) I don't recall what Rose
2335 looks like with dtwm, but I suspect it's quite close to
2338 Next we had Klaus Zeitler report that the Rational Rose official
2339 startup script is explicitly setting ALLWM to nothing. This makes
2340 it more difficult for an individual user to set this variable.
2341 If you can, you can just modify the script, otherwise, your other
2342 alternative is to copy the script somewhere where you can modify it
2343 and run it from there.
2345 ----------------------------------------------------------------------
2347 5.15 Although I use the WindowListSkip style for my modules they
2348 still show up in FvwmIconMan, FvwmWinList etc.
2350 A: Make sure you have
2352 *FvwmIconMan: UseWinList true
2354 in your config file. If that does not help, the modules you are
2355 using may not match the fvwm executable. Recompile and reinstall
2356 everything and the problem should go away.
2358 ----------------------------------------------------------------------
2360 5.16 When I Maximize an application, sometimes I get gaps around
2361 the edges, and other times I don't. What's going on?
2363 A: The ICCCM specification allows applications to specify certain
2364 properties the window manager should honor, such as aspect
2365 ratio (PAspect) or increments to be resized in (PResizeInc). Of
2366 course, sometimes these properties won't perfectly match the
2367 size of your desktop (or ewmh struts), if that should happen,
2370 In general, the application will have a good reason for doing
2371 this (for example, a terminal window may not want to have only
2372 part of a column visible), but you can make fvwm ignore the
2375 Style * ResizeHintOverride
2377 ======================================================================
2379 ======================================================================
2381 6.1 What exactly is the difference between a DESK, a PAGE, and the
2384 A: Our naming convention is sometimes a source of confusion, and when
2385 discussing problems and the like it's good to maintain a consistent
2386 meaning. To illustrate how features of fvwm should be referred to
2387 - fvwm has multiple disjoint DESKTOPS, each of which is comprised
2388 of M by N PAGES, which are each the size of the physical SCREEN.
2389 The physical SCREEN acts as a viewport over one of the PAGES of the
2390 current DESK. Here's a picture to clarify (also, take a look at
2391 the FvwmPager module):
2394 +----------+----------+ +----------+----------+
2396 | Page 0 0 | Page 1 0 | | | |
2399 +----------+----------+ +----------+----------+
2400 |+--------+| | | | |
2401 ||Page 0 1|| Page 1 1 | | | |
2403 |+--------+| | | | |
2404 +----------+----------+ +----------+----------+
2406 It shows two 2 x 2 DESKTOPS. If the current DESK were number 0,
2407 and the current PAGE were 0 1, the SCREEN would show only the
2408 windows located there, plus any sticky ones.
2410 Desktops are numbered consecutively, beginning with 0. The user is
2411 not responsible for creating new desktops, those details are
2412 handled inside fvwm. To display the different desktops, the user
2413 can configure key bindings that determine which desktop is
2414 displayed. For example, to have the combinations Meta-1 to Meta-4
2415 display desktop numbers 0 to 3, one would add this to her config:
2417 Key 1 A M GotoDesk 0
2418 Key 2 A M GotoDesk 1
2419 Key 3 A M GotoDesk 2
2420 Key 4 A M GotoDesk 3
2422 The same can be done for pages. For example, if each desktop has
2423 a size of 2 by to pages you could bind Meta-F1 to Meta-F4 to
2427 Key F1 A M GotoPage 0 0
2428 Key F2 A M GotoPage 1 0
2429 Key F3 A M GotoPage 0 1
2430 Key F4 A M GotoPage 1 1
2432 It is also a good idea to create a pager that displays several
2433 desktops, side by side. This command displays the first 4
2436 Module FvwmPager 0 3
2438 Or if you prefer to see only the current desktop in the pager:
2440 Module FvwmPager * *
2442 ----------------------------------------------------------------------
2444 6.2 I'd really like {OpenWindows, NeXT, Win95, Mac, etc} look and
2445 feel. Are you going to support that?
2447 A: This is not our primary mission, but we think fvwm does a pretty
2448 good job of producing these appearances.
2450 You may want to take a look at the
2451 http://fvwm-themes.sourceforge.net/
2454 ----------------------------------------------------------------------
2456 6.3 Where can I get more XPMs for icons?
2458 A: If you want more color icons, grab the ones out of the ctwm
2459 distribution (also at ftp.x.org) which has a lot of nice ones. You
2460 can also find more in other distributions at ftp.x.org, and at
2461 http://www.sct.gu.edu.au/~anthony/icons/ (which has a lot, I
2464 Icons used to be distributed along with fvwm. Now there is a basic
2465 set of icons available at the fvwm web site. You might find some
2466 links at the fvwm web site to other sources of icons.
2468 You may want to take a look at the
2469 http://wm-icons.sourceforge.net/
2472 ----------------------------------------------------------------------
2474 6.4 Linux XF86 virtual screen size & fvwm interaction...
2476 A: Turn off the Linux Virtual Screen stuff in your XF86Config file if
2477 you don't like it. The XFree86 virtual screen feature and hardware
2478 panning support in certain video cards is a pretty useless kludge
2479 when you're using a window manager that implements virtual
2482 ----------------------------------------------------------------------
2484 6.5 I know this question doesn't have to do with fvwm, but what
2485 happened to to rxvt and rclock which Rob Nation used to support?
2486 Where can I find them now?
2488 A: The official home for rxvt is:
2490 http://www.rxvt.org/
2492 and rclock can be found in that rxvt distribution as well.
2494 ----------------------------------------------------------------------
2496 6.6 How do I set the background with fvwm?
2498 A: Setting the background image is not really part of the window
2499 manager. If you are using one of the Linux distributions, most
2500 likely, some part of the distribution is setting the background for
2503 There is a program shipped with fvwm (fvwm-root, previously known
2504 as xpmroot) that you can use to set the background to an XPM or PNG
2505 image. Other programs like "xv", "xli", "xloadimage", "display",
2506 "feh" and "Esetroot", may be used too, they support some image
2507 formats that fvwm-root does not.
2509 If you just want a static image on your background, you might
2510 invoke one of these programs from your .xsession or .xinitrc file.
2511 You can also invoke one of these programs from the StartFunction in
2514 The fvwm module FvwmBacker can be used to change the background
2515 depending on the desk you are currently on by calling an external
2516 program. One big disadvantage of external programs is that
2517 changing the background on the fly can be pretty slow. FvwmBacker
2518 can use the image defined in a colorset and cached by fvwm for fast
2519 background changing. For example:
2521 Colorset 10 TiledPixmap foo.xpm
2522 Colorset 11 Pixmap bar.png
2523 FvwmBacker: Command (Desk *, Page * 0) Colorset 10
2524 FvwmBacker: Command (Desk *, Page * 1) Colorset 11
2526 However, fvwm can handle only xpm, xbm and png images. Other
2527 formats must be converted before they can be used in fvwm.
2529 If you want to set a different background per screen (i.e., you're
2530 using Xinerama), then the program "Nitrogen" can be used to do
2531 that. See: http://projects.l3ib.org/nitrogen/
2533 ----------------------------------------------------------------------
2535 6.7 When I use Fvwm, my XYZ isn't the right color. Whats wrong?
2537 A: Under this heading we've had questions about FvwmForm being all
2538 white, icons not displaying and messages about being unable to
2541 Older hardware uses something called 8 bit color. You can also
2542 mis-configure newer hardware so that it's only using 8 bit color.
2543 When you use 8 bit color, your display can only have 256 colors on
2546 This is explained in excruciating detail in the
2547 http://www.sunhelp.org/faq/FrameBuffer.html
2549 If your display can support more than 256 colors, that's the way to
2550 go. Look up the documentation for your X server. You may want to
2553 If you are stuck with 8 bit color, fvwm can help. In the 2.2.x
2554 releases, you can use the "ColorLimit" command to reduce the number
2555 of colors Fvwm uses in icons. In the 2.3.x releases and later,
2556 ColorLimiting is automatic, but you still might want to use this
2557 command to further reduce color use.
2559 Other things you may want to do:
2561 - Always run Netscape with the "-install" argument.
2563 - If you use an image on your screen background, reduce the number
2564 of colors it uses. For xv add the "-nc nn" argument. For
2565 xli use the "-colors nn" argument.
2567 - Don't use color gradients.
2569 - Some applications are color hungry. Beware of anything TK based,
2570 and FrameMaker in its default setting.
2572 If you still have problems after this, try the fvwm mailing list.
2574 ----------------------------------------------------------------------
2576 6.8 I just got a mouse with 57 buttons. How do I make Fvwm use them?
2578 A: Okay, we know you don't have 57 buttons, but we've seen reports
2579 of up to 7 so far. Starting with Fvwm 2.4.0 Fvwm supports all
2580 five mouse buttons that X officially supports, and since
2581 2.5.11, up to 9 buttons are supported by default.
2585 To use more than 9 buttons (up to 31), modify the file
2586 libs/defaults.h. Replace
2588 #define NUMBER_OF_EXTENDED_MOUSE_BUTTONS 9
2592 #define NUMBER_OF_EXTENDED_MOUSE_BUTTONS 15
2596 To use more than 5 buttons, modify the file libs/defaults.h.
2599 #define NUMBER_OF_MOUSE_BUTTONS 5
2603 #define NUMBER_OF_MOUSE_BUTTONS 7
2605 Then recompile and reinstall fvwm. However, the buttons with
2606 numbers higher than 5 do not work as well as 1 to 5. This is
2607 because X does not provide the necessary interface to handle more
2608 than 5 buttons in some functions. This means that some
2609 functionality is not available with buttons 6 and higher.
2611 The maximum possible number you can use is 31. Any higher value
2612 will probably not work and possibly even crash fvwm or its modules.
2614 ----------------------------------------------------------------------
2616 6.9 Why does fvwm change my X Cursor theme?
2618 A: It doesn't. There is a standard set of cursors that should
2619 always be available to applications, such as crosshair, left_ptr,
2620 arrow, pencil, and so on. Your theme should provide each of these
2621 cursors, but some don't. When something (for example, an
2622 application or fvwm) requests a cursor that your theme does not
2623 provide, X falls back to the default. If you are seeing fvwm
2624 using cursors that do not match your theme, you should use
2625 CursorStyle to change to a cursor that is available, or find a
2626 more complete theme. Note that fvwm does not control what cursors
2627 your applications request.
2629 ======================================================================
2630 7 - Hints and Examples from the Developers
2631 ======================================================================
2633 7.1 An easy way to test new configurations.
2635 Did you know that you do not need to restart X or fvwm to see what
2636 most configuration commands do? There are several modules
2637 that allow you to issue fvwm commands at any time. Among
2638 these are FvwmCommand, "FvwmForm FvwmForm-Talk" and FvwmConsole.
2639 Personally I use FvwmCommand and FvwmConsole.
2641 When you run FvwmConsole you get a shell like window where you can
2642 type configuration commands that are sent to fvwm. Just add an
2643 entry to some menu that starts it:
2646 + "FvwmConsole" Module FvwmConsole
2648 Using FvwmCommand is a bit more tricky. To use it you need to
2649 start a server in your config by adding this line:
2653 Make sure FvwmCommand is in your search path. Now you can enter
2654 commands on the command line of your favorite shell:
2656 FvwmCommand "MenuStyle * Font 6x9"
2658 Note that you have to quote the command. The advantage of
2659 FvwmCommand over FvwmConsole is that you can use your shell with
2660 all its features to run commands (command completion and history
2661 for example). The disadvantage is that it is a bit slow since a
2662 new FvwmCommand has to be started for each command.
2664 Other related modules and commands are FvwmScript and PipeRead.
2666 ----------------------------------------------------------------------
2668 7.2 Using shell commands for configuration.
2670 Sometimes you might want to use the output of a shell command or
2671 script in your config. For example you might need a menu that
2672 has all filenames in a certain directory as its entries. You can
2673 use the PipeRead command and the FvwmCommand module. I recommend
2674 using PipeRead since creating twenty menu items takes a
2675 considerable amount of time with FvwmCommand.
2677 Example from my config:
2679 # make the background menu
2680 DestroyFunc MakeBackgroundMenu
2681 AddToFunc MakeBackgroundMenu
2682 + I DestroyMenu BackgroundMenu
2683 + I AddToMenu BackgroundMenu Backgrounds Title
2684 + I PipeRead 'for i in `/bin/ls $HOME/.fvwm/backgrounds/*.bg.*`; \
2685 do echo -e AddToMenu BackgroundMenu `basename $i | sed -e \
2686 "s/\.bg\..*$//"` Function SetDefaultBackground $i; done'
2688 # set the default background
2689 DestroyFunc SetDefaultBackground
2690 AddToFunc SetDefaultBackground
2691 + I Exec echo -e $0 > $HOME/.fvwm/background
2694 # set a new background
2695 DestroyFunc SetBackground
2696 AddToFunc SetBackground
2697 + I Exec test -r $HOME/.fvwm/background && xv -root -quit -viewonly \
2698 `cat $HOME/.fvwm/background|tr -d "\n"`
2700 # activate setting from last session and build the menu
2701 AddToFunc StartFunction
2703 + I MakeBackgroundMenu
2706 The MakeBackgroundMenu function builds a menu that contains an item
2707 for every file that matches the pattern "*.bg.*" in the directory
2708 $HOME/.fvwm/backgrounds. The suffix .bg.* is removed. When I
2709 select an item the file is displayed in the background using
2710 xv. Furthermore the path and filename are stored in
2711 $HOME/.fvwm/background. When I start my next fvwm session the
2712 filename is fetched from there so I get the background from my last
2715 I have an even more complex setup for color palettes.
2717 ----------------------------------------------------------------------
2719 7.3 How to start applications on a page or desk other than the
2722 Use the 'StartsOnDesk' or 'StartsOnPage' style in your config:
2724 Style Netscape* StartsOnPage 0 1
2728 Style Netscape* StartsOnDesk 1
2730 Any window with a title that begins with 'Netscape' will be placed
2731 on page 0 1 (desk 1). You will probably want to use these options
2734 Style * RecaptureHonorsStartsOnPage, CaptureHonorsStartsOnPage
2736 If you want to start applications on a different page in the
2737 background without switching to this page, use the 'SkipMapping'
2740 Style Netscape* StartsOnPage 0 1, SkipMapping
2742 ----------------------------------------------------------------------
2744 7.4 How to start applications on a page or desk other than the
2745 current without moving the viewport to the new page or desk.
2747 Use the SkipMapping style:
2749 Style Netscape* StartsOnPage 0 1, SkipMapping
2751 ----------------------------------------------------------------------
2753 7.5 A more efficient MWM menu style.
2755 Perhaps you have noticed that with the MWM menu style your sub
2756 menus are shown as soon as the pointer enters their menu items,
2757 even if you just want to scroll down the list. You can prevent
2758 this with the 'PopupDelay' and 'PopupDelayed' options of the
2762 MenuStyle PopupDelayed, PopupDelay 80
2764 The sub menu will be shown 80 milliseconds after the pointer enters
2765 the menu item. You will hardly notice the delay. Note that 80 ms
2766 is just long enough to move through the menu with auto repeat on my
2767 cursor keys. You may have to experiment with this number to get it
2770 ----------------------------------------------------------------------
2772 7.6 Placing menus on the screen.
2774 Do you have to close windows or move the pointer all over the
2775 screen to find some part of the background where you can bring up
2776 your main menu (or any other root menu)?
2778 Then you should use a keyboard shortcut. For example
2780 Key space A M Menu root c c main_menu
2782 in your config gives you the menu 'main_menu' in the center of the
2783 screen when you press Alt-space. Or you might want a shortcut to
2786 Key space A SM Menu root c c WindowMenu
2788 You can place menus anywhere you like, not just where the mouse
2789 pointer is. Please read the section for the 'Menu' command in the
2792 ----------------------------------------------------------------------
2794 7.7 Are you flipping pages by accident when moving the mouse close to
2795 the border of the screen?
2797 You can disable page flipping with the EdgeScroll command:
2801 in your config turns it off.
2803 ----------------------------------------------------------------------
2805 7.8 Lining up your windows and icons.
2807 The SnapAttraction and SnapGrid commands really help to keep your
2808 desktop tidy. With SnapAttraction windows (or icons or both) are
2809 'attracted' to each other. When you drag a window (icon) and it
2810 comes close to another window (icon) it clings to it without a gap
2811 between the borders. Put this command in your config:
2813 SnapAttraction 8 SameType
2815 This means windows cling to other windows if they get closer than
2816 8 pixels and icons cling to icons. Or if you just want it for
2819 SnapAttraction 8 Windows
2823 SnapAttraction 8 Icons
2825 Or if you want icons to cling to windows and vice versa:
2827 SnapAttraction 8 All
2830 The SnapGrid command is a big help too:
2834 in your config tells fvwm to use a grid of 8 pixels to place
2835 windows and icons. Try it and see if you like it.
2837 Hint: It might be a good idea to use a divisor of your desktop
2838 width and height for SnapGrid.
2840 ----------------------------------------------------------------------
2842 7.9 Moving the mouse/focus/page with the keyboard.
2844 Try these key bindings for mouse movement:
2846 # shift-<direction> to move a few pixels
2847 Key Left A S CursorMove -1 0
2848 Key Right A S CursorMove +1 +0
2849 Key Up A S CursorMove +0 -1
2850 Key Down A S CursorMove +0 +1
2852 # shift-meta-<direction> to move 1/4 page
2853 Key Left A SM Scroll -25 +0
2854 Key Right A SM Scroll +25 +0
2855 Key Up A SM Scroll +0 -25
2856 Key Down A SM Scroll +0 +25
2858 or these to flip pages
2860 # shift-control-<direction> to move a full page
2861 Key Left A SC CursorMove -10 +0
2862 Key Right A SC CursorMove +10 +0
2863 Key Up A SC CursorMove +0 -10
2864 Key Down A SC CursorMove +0 +10
2866 # Alt-Fn to go to a specific page (like on the Linux console)
2867 Key F1 A M GotoPage 0 0
2868 Key F2 A M GotoPage 1 0
2869 Key F3 A M GotoPage 0 1
2870 Key F4 A M GotoPage 1 1
2872 or to change the focus to a window in a specific direction:
2874 # number keys on keypad to move the focus
2875 Key KP_1 A C Direction SouthWest (AcceptsFocus) Focus
2876 Key KP_2 A C Direction South (AcceptsFocus) Focus
2877 Key KP_3 A C Direction SouthEast (AcceptsFocus) Focus
2878 Key KP_4 A C Direction West (AcceptsFocus) Focus
2879 Key KP_6 A C Direction East (AcceptsFocus) Focus
2880 Key KP_7 A C Direction NorthWest (AcceptsFocus) Focus
2881 Key KP_8 A C Direction North (AcceptsFocus) Focus
2882 Key KP_9 A C Direction NorthEast (AcceptsFocus) Focus
2884 ----------------------------------------------------------------------
2886 7.10 The cat safe desktop ^_^
2888 If your cats keep stepping on your keyboard while you are brewing
2889 another cup of coffee, one of these hints may help:
2891 Use 'Style * MouseFocus' and move the mouse pointer over the
2892 background when you go away.
2894 If you can't do without your 'SloppyFocus' you can move the
2895 mouse pointer into a window that takes no keyboard input and
2896 give it the focus (e.g. FvwmButtons or a console message
2897 window). A true fanatic creates a separate window with a picture
2898 of his cat for this ^_^
2900 ----------------------------------------------------------------------
2902 7.11 Lowering and moving windows.
2904 In some configurations moving a window with the middle mouse
2905 button lowers the window after moving it. Lowering it before
2906 moving gives you a nice visual effect:
2908 Mouse 2 T A Function MoveOrLower
2910 DestroyFunc MoveOrLower
2911 AddToFunc MoveOrLower
2917 ----------------------------------------------------------------------
2919 7.12 Toggling windows on and off.
2921 It is often desirable to have a menu item or perhaps a button in
2922 FvwmButtons or FvwmWharf that launches an application when used
2923 the first time and closes it if used a second time. Although it
2924 is not obvious how to do this, it is possible. Let's assume you
2925 need a menu item that toggles an FvwmConsole window on and off.
2927 Then put the following lines in your config (for fvwm-2.5.11 or
2930 DestroyFync ToggleFvwmConsole
2931 AddToFunc ToggleFvwmConsole
2932 + I ToggleWindow FvwmConsole "Module FvwmConsole"
2934 # Application toggling function
2935 # First argument is the window name, second argument is the
2936 # command to start the application.
2937 DestroyFunc ToggleWindow
2938 AddToFunc ToggleWindow
2939 + I None ($$0, CirculateHit) $$1
2940 + I TestRc (Match) Break
2941 + I Next (currentpage, visible, !iconic, $$0, CirculateHit) Close
2942 + I TestRc (Match) Break
2943 + I Next ($$0, CirculateHit) Function MakeVisible
2946 DestroyFunc MakeVisible
2947 AddToFunc MakeVisible
2955 To invoke the function, you can add it to a menu
2957 AddToMenu <some menu>
2958 + "toggle FvwmConsole" Function ToggleFvwmConsole
2960 Or if you prefer a button in the button bar:
2962 *FvwmButtons: (Action ToggleFvwmConsole)
2964 The lines with MoveToDesk, MoveToPage and Raise will bring the
2965 window to the top of the current page if it is not visible
2966 instead of closing it. The generic function ToggleWindow can be
2967 reused to toggle all kinds of windows.
2969 If you want to toggle one specific window, e.g. an xterm, but
2970 still want to have other xterms that are not toggled, you must
2971 give the window an unique name:
2973 DestroyFunc RunXMessages
2974 AddToFunc RunXMessages
2975 + I Exec exec xterm -T XMessages -n XMessages \
2976 -e tail -f /var/adm/?* ~/.X.err
2978 DestroyFunc ToggleXMessages
2979 AddToFunc ToggleXMessages
2980 + I ToggleWindow XMessages RunXMessages
2982 Keep in mind that these functions simply check if a window with
2983 the specified name exists. They will happily close manually
2984 opened windows or launch an application multiple times if the
2985 application is slow to start (e.g. like netscape).
2987 For fvwm-2.5.10 or earlier, these functions should work too:
2989 DestroyFunc ToggleFvwmConsole
2990 AddToFunc ToggleFvwmConsole
2991 + I None (FvwmConsole, CirculateHit) FvwmConsole
2992 + I Next (FvwmConsole, CirculateHit, CurrentPage, Visible) Close
2993 + I Next (FvwmConsole, CirculateHit) MoveToDesk
2994 + I Next (FvwmConsole, CirculateHit) MoveToPage
2995 + I Next (FvwmConsole, CirculateHit) Raise
2997 DestroyFunc ToggleXMessages
2998 AddToFunc ToggleXMessages
2999 + I None (XMessages, CirculateHit) Exec exec \
3000 xterm -T XMessages -n XMessages -e tail -f /var/adm/?* ~/.X.err
3001 + I Next (XMessages, CirculateHit) Close
3003 ----------------------------------------------------------------------
3005 7.13 Starting applications by clicking on an icon (also known as
3006 "docking" applications).
3008 Normally an icon represents a minimized application. If you
3009 want to turn that around, and launch applications by clicking
3010 on icons we can't stop you. Heres a way to do that using
3013 # FvwmButtons icon launcher:
3014 DestroyFunc Launcher
3016 + I DestroyModuleConfig $0Launch: *
3017 + I *$0Launch: Geometry 64x68
3018 + I *$0Launch: Columns 1
3019 + I *$0Launch: Rows 4
3020 + I *$0Launch: Frame 0
3021 + I *$0Launch: (1x3+0+0, Icon $1, Action (Mouse 1) `Exec $2`)
3022 + I *$0Launch: Pixmap none
3023 + I *$0Launch: (1x1+0+3, Font 9x15, Fore White, Back DarkBlue, \
3024 Title $0, Action (Mouse 1) `Exec $2`)
3025 + I Style $0Launch HandleWidth 0, NoTitle
3026 + I Module FvwmButtons $3 $0Launch
3028 Launcher RXVT xterm.xpm "rxvt -bg black" "-g +0+0"
3029 Launcher XV xv.xpm "xv" "-g +0+100"
3031 Also, GNOME and KDE have desktop icon applications gmc and kfm,
3032 which enable this functionality. These applications may be run
3033 under fvwm. Nautilus (version >= 2) and kdesktop may be run under
3034 fvwm version 2.5.1 or better.
3036 ----------------------------------------------------------------------
3038 7.14 Positioning a window using arithmetic.
3040 This example shows how to center a window on the screen. Note
3041 how is uses PipeRead and the shell construct $(()) in order to
3044 DestroyFunc CenterWindow
3045 AddToFunc CenterWindow
3046 + I ThisWindow Piperead "echo Move \
3047 +$(( $[vp.width]/2-$[w.width]/2 ))p \
3048 +$(( $[vp.height]/2-$[w.height]/2 ))p"
3050 If you had a window named "MyWindow" you would center it using
3053 Next (MyWindow) CenterWindow
3055 ThisWindow may be removed, it is only needed to avoid errors when
3056 CenterWindow is called without a window context. (In which case
3057 see the Pick command.)
3059 With fvwm release 2.5.11, you can place windows in the center of
3060 the screen using "Style X CenterPlacement".
3062 But with fvwm release 2.5.22 and greater CenterPlacement is
3063 deprecated over the use of PositionPlacement style which allows for
3064 not only centering windows, but positioning windows anywhere on the
3065 screen using the same arguments as the Move command. But in terms of
3068 Style MyWindow PositionPlacement Center
3070 ----------------------------------------------------------------------
3072 7.15 Hiding the mouse pointer.
3074 Some users don't like the mouse pointer getting in the way of
3075 what they are looking at. You might want to search for and
3076 install the "unclutter" program. Unclutter hides the mouse
3077 pointer after you haven't moved the mouse for a while.
3079 If you find unclutter causes the pointer to flash on and off
3080 or move around on its own, run unclutter with the -noevents
3083 ----------------------------------------------------------------------
3085 7.16 Finding the mouse pointer.
3087 Sometimes its hard to see the mouse pointer. Here is a way to
3090 Key Super_L A A Exec xmessage -name "SmallBlob" -bg red \
3091 -fg white -nearmouse -timeout 1 'I am here!'
3092 Style SmallBlob UsePPosition, NoTitle, NoHandles, BorderWidth 10
3094 ----------------------------------------------------------------------
3096 7.17 Autohiding FvwmButtons or other windows.
3098 Some applications have a feature usually called "autohiding"
3099 which allows to withdraw a window to a location where it does
3100 not use precious desktop space. It is possible to write some
3101 small functions in fvwm that can hide any window you like:
3103 fvwm-2.5.11 or later:
3105 # The autohiding functions
3106 DestroyFunc autohide
3108 + I ThisWindow ($0) Deschedule $[w.id]
3109 + I ThisWindow ($0) KeepRc ThisWindow (shaded) WindowShade off
3110 + I TestRc (!Match) All ($0, !shaded) autohide_hide $1 $2
3112 DestroyFunc autohide_hide
3113 AddToFunc autohide_hide
3114 + I Schedule $0 $[w.id] WindowShade $1
3115 + I Schedule $0 $[w.id] Deschedule $[w.id]
3118 AddToFunc StartFunction
3119 + I Module FvwmAuto 1 -menter enter_handler
3121 # Add the windows you want to autohide
3122 DestroyFunc enter_handler
3123 AddToFunc enter_handler
3124 + I autohide FvwmButtons 500 S
3126 # | | |___ Shade direction (optional)
3127 # | |_______ Hide delay (milliseconds)
3128 # |___________________ Unique window name/resource
3130 Simply add any windows you like to the enter_handler function
3131 as in the example above. The autohide function is called with
3132 two or three parameters. The first one is the window's name or
3133 class, which must be unique. The second is the delay in
3134 milliseconds before the window is hidden after the pointer
3135 leaves it, and the last - optional - one indicates the
3136 direction in which it is hidden (N, S, E, W, NW, NE, SW or SE).
3138 You can find a slightly more complicated version below. The
3139 difference is that showing the window does not happen
3140 immediately, but can be delayed too.
3142 fvwm-2.5.11 or later:
3144 DestroyFunc autohide
3146 + I ThisWindow ($0) Deschedule $[w.id]
3147 + I TestRc (!Match) Deschedule -$[w.id]
3148 + I ThisWindow ($0) KeepRc ThisWindow (shaded) \
3150 + I TestRc (!Match) All ($0, !shaded) autohide_hide $2 $3
3152 DestroyFunc autohide_show
3153 AddToFunc autohide_show
3154 + I Schedule $0 -$[w.id] WindowShade $1 off
3155 + I Schedule $0 -$[w.id] Deschedule $[w.id]
3156 + I Schedule $0 -$[w.id] Deschedule -$[w.id]
3158 DestroyFunc autohide_hide
3159 AddToFunc autohide_hide
3160 + I Schedule $0 $[w.id] WindowShade $1 on
3161 + I Schedule $0 $[w.id] Deschedule $[w.id]
3162 + I Schedule $0 $[w.id] Deschedule -$[w.id]
3164 AddToFunc StartFunction
3165 + I Module FvwmAuto 1 -menter enter_handler
3167 DestroyFunc enter_handler
3168 AddToFunc enter_handler
3169 + I autohide FvwmButtons 250 500 S
3171 # | | | |__ Shade direction (optional)
3172 # | | |______ Hide delay
3173 # | |__________ Show delay
3174 # |______________________ Unique window name/resource
3176 These functions work too in 2.5.8 to 2.5.10, but you may have
3177 to remove the KeepRc command from the autohide function in both
3180 ----------------------------------------------------------------------
3182 7.18 Using application screenshots as icon or mini icon
3185 With a bit of scripting magic, fvwm can take a screenshot of an
3186 application window when it's iconified, resize it, and use it as
3187 the application's icon. However, there are some applications that
3188 can do it on their own, which is the recommended method.
3190 With xterm, you can use the +ai (active icon) option on the command
3195 There is a live-icon elisp package for XEmacs. Put this in your
3196 XEmacs configuration file:
3198 (load-library "live-icon")
3199 ; Control size, same as max icon size, uncomment if you want
3201 ;(setq live-icon-max-height 48)
3202 ;(setq live-icon-max-width 48)
3204 Make sure you are not using the style IconOverride for these
3205 applications. It disables the use of active icons. There may be
3206 other applications with similar features.
3209 Assuming you want application thumbnails as icons provided by fvwm,
3210 you need fvwm 2.5.8 or later, as this solution requires the
3211 WindowStyle command, and you should have the ImageMagick utilities
3212 available in your $PATH <URL:http://www.imagemagick.org/>.
3214 The function below provides a Replacement for the Iconify command
3215 called Thumbnail, which you can use in your bindings and raises
3216 each window, takes a screenshot and attempts to set the screenshot
3217 as the window's Icon. Taking a screenshot may take a couple of
3218 seconds. The window is iconified immediately, but the new
3219 thumbnail is activated when the screenshot is ready.
3221 Note that a screenshot can only be made reliably from the visible
3222 parts of a window. So if the window is halfway off screen, on a
3223 different desk, or buried beneath other windows, the thumbnail may
3224 be smaller than expected or be empty in the hidden parts. There is
3225 no way to prevent this.
3227 The same solution should work for mini icons. Just replace the
3228 word "icon" with "miniicon" everywhere.
3230 DestroyFunc Thumbnail
3233 + I ThisWindow (!Shaded, Iconifiable, !Iconic) PipeRead \
3234 "xwd -silent -id $[w.id] | convert -scale 64 -frame 1x1 \
3235 -mattecolor black -quality 0 xwd:- \
3236 png:$[FVWM_USERDIR]/icon.tmp.$[w.id].png \
3237 && echo WindowStyle IconOverride, \
3238 Icon $[FVWM_USERDIR]/icon.tmp.$[w.id].png \
3242 You can use FvwmEvent to remove the Icons when each window is
3243 returned to its non Iconic state.
3245 DestroyFunc DeThumbnail
3246 AddToFunc DeThumbnail
3247 + I Exec rm -f $[FVWM_USERDIR]/icon.tmp.$[w.id].png
3248 + I DestroyWindowStyle
3250 *FvwmEvent: deiconify DeThumbnail
3252 AddToFunc StartFunction I Module FvwmEvent
3254 If you cannot use DestroyWindowStyle as you require it for some
3255 other purpose, you can save the window's current Icon, and restore
3256 it when required, this solution requires fvwm 2.5.9 or later.
3258 The Thumbnail function should look like this:
3260 DestroyFunc Thumbnail
3263 + I SetEnv Icon-$[w.id] $[w.iconfile]
3264 + I ThisWindow (!Shaded, Iconifiable, !Iconic) PipeRead \
3265 "xwd -silent -id $[w.id] | convert -scale 64 -frame 1x1 \
3266 -mattecolor black -quality 0 xwd:- \
3267 png:$[FVWM_USERDIR]/icon.tmp.$[w.id].png \
3268 && echo WindowStyle IconOverride, \
3269 Icon $[FVWM_USERDIR]/icon.tmp.$[w.id].png \
3273 And then the Icon is restored with this function:
3275 DestroyFunc DeThumbnail
3276 AddToFunc DeThumbnail
3277 + I PipeRead "echo WindowStyle Icon \\$\\[Icon-$[w.id]\\]"
3278 + I UnsetEnv Icon-$[w.id]
3279 + I Exec rm -f $[FVWM_USERDIR]/icon.tmp.$[w.id].png
3281 These Icons can also survive a Restart by adding this check to your
3284 AddToFunc StartFunction I Test (Restart) All (Iconic) \
3285 Test (f $[FVWM_USERDIR]/icon.tmp.$[w.id].png) WindowStyle \
3286 IconOverride, Icon $[FVWM_USERDIR]/icon.tmp.$[w.id].png
3288 You can also check for any remaining icons left behind and remove
3289 them in your ExitFunction:
3291 DestroyFunc ExitFunction
3292 AddToFunc ExitFunction I Test (!ToRestart) \
3293 Exec rm -f $[FVWM_USERDIR]/icon.tmp.*
3295 The same solution should work for mini icons. Just replace the
3296 word "icon" with "miniicon" everywhere.
3298 ----------------------------------------------------------------------