One of the main reasons I stick to Fedora Core 4 is because it still supports fvwm1. What I want is a simply configured window with 4 xterms, a few of my menus and not much else. Trying to get this going with fvwm2 seems to require a Ph.D. (and I do have one, but not in window managers -- apparently that is now needed).

I'm attaching my current very simple .fvwmrc file. Is there any way to match its functionality with fvwm2? I've tried, in the past, to properly edit the .fvwmrc(2) file to give me the same functionality, with universally dismal failure.

Do you know if the source code for fvwm1 will still compile on, say, a Fedora 14 system?

                         Gordon Fenton
###########################################################################
# set up the colors
#
# OK some people like bright clear colors on their window decorations.
# These people, I guess would mostly be from nice sunny/good weather places
# line California.
#

# Me, I'm from Upstate New York, and live in New Hampshire, so I prefer
# these dark muddy colors...

# this is used for non-selected windows, menus, and the panner
StdForeColor            Black
StdBackColor            LightSkyBlue

# this is used for the selected window
HiForeColor             Black
HiBackColor             turquoise3

PagerBackColor          LightSkyBlue
PagerForeColor          orchid

StickyForeColor         White
StickyBackColor         FireBrick1

# Menu colors
MenuForeColor           Black
MenuBackColor           LightSkyBlue
MenuStippleColor        SlateGrey

############################################################################
# Now the fonts - one for menus, another for window titles, another for icons
Font                    -adobe-helvetica-medium-r-*-*-14-*-*-*-*-*-*-*
#Font                   -*-times-medium-i-*-*-*-140-*-*-*-*-*-*
WindowFont              -adobe-helvetica-bold-r-*-*-12-*-*-*-*-*-*-*
#IconFont               -adobe-helvetica-medium-r-*-*-11-*-*-*-*-*-*-*
IconFont                fixed

###########################################################################
# Set up the major operating modes
#
########################      FOCUS STUFF     ##############################
# Set windows to auto-raise after 750 milliseconds if you like it.
# Autoraise can sometimes obscure pop-up windows. Performance is now
# similar to olvwm's auto-raise feature.
AutoRaise 500

# Normally, we'll be in focus-follows mouse mode, but uncomment this 
# for mwm-style click-to-focus
#ClickToFocus

########################      ICON STUFF     ##############################
# Auto Place Icons is a nice feature....
# This creates two icon boxes, one on the left side, then one on the
# bottom. Leaves room in the upper left for my clock and xbiff,
# room on the bottom for the Pager.
# IconRegion "600x90+600+0" North East 90 90
IconBox -270 10 -1 90

# If you uncomment this, and make sure that the WindowList is bound to
# something, it works pretty much like an icon manager.
#SuppressIcons

# StubbornIcons makes icons de-iconify into their original position on the
# desktop, instead of on the current page.
#StubbornIcons

# With AutoPlacement, icons will normally place themselves underneath active
# windows. This option changes that.
#StubbornIconPlacement

# If you want ALL you icons to follow you around the desktop (Sticky), try
# this
#StickyIcons

########################      MWM EMULATION     #######################
#
# My feeling is that everyone should use MWMDecorHints and MWMFunctionHints,
# since some applications depend on having the window manager respect them

# MWMFunction hints parses the function information in the MOTIF_WM_HINTS
# property, and prohibits use of these functions on the window. Appropriate
# portions of the window decorations are removed.
MWMFunctionHints

# MWM is kinda picky about what can be done to transients, and it was keeping
# me from iconifying some windows that I like to iconify, so here's an
# over-ride that will allow me to do the operation, even tough the menu
# item is shaded out.
MWMHintOverride

# MWMDecor hints parses the decoration information in the MOTIF_WM_HINTS
# property, and removes these decoratons from the window. This does not affect
# the functions that can be performed via the menus.
MWMDecorHints

# These are affect minor aspects for the look-and-feel.
# Sub-menus placement mwm-style?
# MWMMenus
# mwm-style border reliefs (less deep than default fvwm) ?
# MWMBorders
# Maximize button does mwm-inversion thingy
# MWMButtons
########################      MISCELLANEOUS STUFF     #######################
# If you don't like the default 150 msec click delay for the complex functions
# change this and uncomment it.
#ClickTime 150

# OpaqueMove has a number (N) attached to it (default 5).
# if the window occupies less than N% of the screen, 
# then opaque move is used. 0 <= N <= 100
OpaqueMove 100
#OpaqueMove 0

# flip by whole pages on the edge of the screen.
EdgeScroll 100 100

# A modest delay before flipping pages seems to be nice...
# I thresh in a 50 pixel Move-resistance too, just so people
# can try it out.
EdgeResistance 40 10

# I like to use a large virtual screen and move from page to page with the
# pager.
#EdgeResistance 10000 0


########################      WINDOW PLACEMENT     #######################
# RandomPlacement prevents user interaction while placing windows:
# RandomPlacement

# SmartPlacement makes new windows pop-up in blank regions of screen 
# if possible, or falls back to random or interactive placement.
#SmartPlacement

# With SmartPlacement, windows will normally place themselves over icons. 
# Uncomment this to change that.
#StubbornPlacement

# NoPPosition instructs fvwm to ignore the PPosition field in window 
# geometry hints. Emacs annoyingly sets PPosition to (0,0)!
NoPPosition


########################      DECORATIONS     #######################
# If you want decorated transient windows, uncomment this:
#DecorateTransients

###########################################################################
# Set up the virtual desktop and pager

#set the desk top size in units of physical screen size
#DeskTopSize 3x3
DeskTopSize 2x1

# and the reduction scale used for the panner/pager
DeskTopScale 24

# Use the Fvwm Pager
#Pager 8 1
Pager 752 2

##########################################################################
# Module path and paths to the icons
#
# ModulePath is a colon-separated list, just like regular unix PATH
ModulePath /usr/lib/X11/fvwm
PixmapPath /usr/include/X11/pixmaps/
IconPath   /usr/include/X11/bitmaps/

############################################################################
# Set the decoration styles and window options
# Order is important!!!!
# If compatible styles are set for a single window in multiple Style
# commands, then the styles are ORed together. If conflicting styles
# are set, the last one specified is used.

# These commands should command before any menus or functions are defined,
# and before the internal pager is started.

# change the default width.
Style "*" BorderWidth 5, HandleWidth 5, Color Black/#60a0c0,Icon unknown1.xpm

Style "Fvwm*"      NoTitle, Sticky, WindowListSkip
Style "*lock"      NoTitle, NoHandles, WindowListSkip
Style "xmailbox"   NoTitle, NoHandles, WindowListSkip
Style "xterm"      Icon xterm.xpm, Color black/white

#############################################################################

# Stuff to do at start-up

Function "InitFunction"
#       Module  "I"     FvwmBanner
#       Exec    "I"     xpmroot /usr/include/X11/pixmaps/fvwm.xpm &
#       Module  "I"     GoodStuff
#       Module  "I"     FvwmPager 0 3
#       Exec    "I"     exec xterm -geometry 80x64+0+0 &
#       Wait    "I"     xterm
#       Desk    "I"     0 2
#       Exec    "I"     exec xmh -font fixed -geometry 507x750+0+0 &
#       Wait    "I"     xmh
#       Desk    "I"     0 0
EndFunction

Function "RestartFunction"
#       Exec    "I"     xsetroot -solid "#266294"      
#       Module  "I"     GoodStuff
#       Module  "I"     FvwmPager 0 3
EndFunction


############################################################################
# Now define some handy complex functions

# This one moves and then raises the window if you drag the mouse,
# only raises the window if you click,  or does a RaiseLower if you double 
# click
Function "Move-or-Raise"
        Move            "Motion"
        Raise           "Motion"
        Raise           "Click"
        RaiseLower      "DoubleClick" 
EndFunction

# This one maximizes vertically if you click (leaving room for the GoodStuff
# bar at the bottom, or does a full maximization if you double click, or a
# true full vertical  maximization if you just hold the mouse button down.
Function "maximize_func"
        Maximize        "Motion" 0 100
        Maximize        "Click" 0 80
        Maximize        "DoubleClick" 100 100
EndFunction


# This one moves and then lowers the window if you drag the mouse,
# only lowers the window if you click,  or does a RaiseLower if you double 
# click
Function "Move-or-Lower"
        Move            "Motion"
        Lower           "Motion"
        Lower           "Click"
        RaiseLower      "DoubleClick"
EndFunction

# This one moves or (de)iconifies:
Function "Move-or-Iconify"
        Move            "Motion"
        Iconify         "DoubleClick"
EndFunction

# This one resizes and then raises the window if you drag the mouse,
# only raises the window if you click,  or does a RaiseLower if you double 
# click
Function "Resize-or-Raise"
        Resize          "Motion"
        Raise           "Motion"
        Raise           "Click"
        RaiseLower      "DoubleClick"
EndFunction


# This is provided as a hint only.
# Move to a known page on the desktop, then start an application in a 
# known location. Could also switch to a known desktop, I guess
#Function "abs_coord"
#       GoToPage "Immediate"    1,1
#       Exec    "Immediate"     exec xcalc -geometry +100+100&
#EndFunction


##############################################################################
#now define the menus - defer bindings until later
Popup "Xterms"
      Title "Xterms - 1024x768"
      Exec  "Xterm top-left"   xterm +sb -ls -geometry 80x56+0+0 &
      Exec  "Xterm bot-left"   xterm +sb -ls -geometry 80x51+30+62 &
      Exec  "Xterm top-right"  xterm +sb -ls -geometry 80x24+526+62 &
      Exec  "Xterm bot-right"  xterm +sb -ls -geometry 80x25+526+405 &
      Title "Xterms - 1280x1024"
      Exec  "Xterm top-left"   xterm +sb -ls -geometry 80x71+0+0 &
      Exec  "Xterm bot-left"   xterm +sb -ls -geometry 80x66+133+66 &
      Exec  "Xterm top-right"  xterm +sb -ls -geometry 80x32+706+66 &
      Exec  "Xterm bot-right"  xterm +sb -ls -geometry 80x32+706+544 &
EndPopup


Popup "Shells"
        Title   "Shells"
        Exec    "Xterm"     exec /usr/X11R6/bin/xterm &
        Exec    "NXterm"    exec /usr/X11R6/bin/nxterm &
        Exec    "Rxvt"      exec /usr/X11R6/bin/rxvt &
EndPopup

Popup "Applications"
        Title   "Applications"
        Exec    "Netscape"      exec netscape &
        Exec    "Ghostview"     exec ghostview &
        Exec    "GNU Emacs"     exec emacs &
        Exec    "Xfig"          exec xfig &
EndPopup

# This menu is invoked as a sub-menu - it allows you to halt,
# reboot, or change your mind.
Popup "Quit-Verify"
        Title   "Shutdown Computer?"
        Exec    "Yes, and Halt"         exec killme -h
        Exec    "Yes, and Reboot"       exec killme
        Nop     ""
        Nop     "No, Don't Shutdown"
EndPopup

# This menu will fire up some very common utilities
Popup "Utilities"
        Title   "Utilities"
        Quit    "Quit Fvwm?"
        Exec    "Top"           exec rxvt  -font 7x14 -T Top -n Top -e top &
        Exec    "Calculator"    exec xcalc &
        Exec    "Xman"          exec xman &
        Exec    "Xmag"          exec xmag &
        Exec    "Oclock"        exec oclock &
        Nop     ""
        Popup   "Applications"  Applications
        Nop     ""
        Popup   "Xterms"        Xterms
        Nop     ""
        Popup   "Shells"        Shells
        Nop     ""
        Popup   "Shutdown"      Quit-Verify
        Nop     ""
        Refresh "Refresh Screen"
EndPopup

# This defines the most common window operations
Popup "Window Ops"
        Title           "Window Ops"
        Function        "Move"          Move-or-Raise
        Function        "Resize"        Resize-or-Raise
        Raise           "Raise"
        Lower           "Lower"
        Iconify         "(De)Iconify" 
        Stick           "(Un)Stick"
        Function        "(Un)Maximize"  maximize_func
        Nop             ""
        Destroy         "Destroy"
        Delete          "Delete"
        Nop             ""
        Refresh         "Refresh Screen"
EndPopup

# A trimmed down version of "Window Ops", good for binding to decorations
Popup "Window Ops2"
        Function        "Move"          Move-or-Raise
        Function        "Resize"        Resize-or-Raise
        Raise           "Raise"
        Lower           "Lower"
        Iconify         "Iconify"
        Stick           "(Un)Stick"
        Nop             ""
        Destroy         "Destroy"
        Delete          "Delete"
        Nop             ""
        Module          "ScrollBar"     FvwmScroll 2 2
EndPopup

#############################################################################
# One more complex function - couldn't be defined earlier because it used 
# pop-up menus
#
# This creates a motif-ish sticky menu for the title-bar window-ops
# pop-up
# Menu acts like normal twm menu if you just hold the button down,
# but if you click instead, the menu stays up, motif style
Function "window_ops_func"
        PopUp   "Click"         Window Ops2
        PopUp   "Motion"        Window Ops2
# Motif would add
#       Delete  "DoubleClick"  
EndFunction


##############################################################################
# This defines the mouse bindings

# First, for the mouse in the root window
# Button 1 gives the Utilities menu
# Button 2 gives the Window Ops menu
# Button 3 gives the WindowList (like TwmWindows)
# I use the AnyModifier (A) option for the modifier field, so you can hold down
# any shift-control-whatever combination you want!

#     Button    Context Modifi  Function
Mouse 1         R       A       PopUp "Utilities"
Mouse 2         R       A       PopUp "Window Ops"
Mouse 3         R       A       WindowList
#Mouse 3                R       A       Module "winlist" FvwmWinList transient



# Now the title bar buttons
# Any button in the left title-bar button gives the window ops menu
# Any button in the right title-bar button Iconifies the window
# Any button in the rightmost title-bar button maximizes
# Note the use of "Mouse 0" for AnyButton.

#     Button    Context Modifi  Function
Mouse 0         1       A       Function "window_ops_func"
Mouse 0         2       A       Function "maximize_func"
Mouse 0         4       A       Iconify

# Now the rest of the frame
# Here I invoke my complex functions for Move-or-lower, Move-or-raise,
# and Resize-or-Raise. 
# Button 1 in the corner pieces, with any modifiers, gives resize or raise
Mouse 1         F       A       Function "Resize-or-Raise"
# Button 1 in the title, sides, or icon, w/ any modifiers, gives move or raise
Mouse 1         TS      A       Function "Move-or-Raise"

# Button 1 in an icons gives move for a drag, de-iconify for a double-click,
# nothing for a single click
# Button 2 in an icon, w/ any modifiers, gives de-iconify

Mouse 1         I       A       Function "Move-or-Iconify"
Mouse 2         I       A       Iconify

# Button 2 in the corners, sides, or title-bar gives the window ops menu
Mouse 2         FST     A       Function "window_ops_func"
# Button 3 anywhere in the decoration (except the title-bar buttons)
# does a raise-lower
Mouse 3         TSIF    A       RaiseLower

# Button 3 in the window, with the Modifier-1 key (usually alt or diamond)
# gives Raise-Lower. Used to use control here, but that interferes with xterm
Mouse 3         W       M       RaiseLower

############################################################################

Reply via email to