#
# TNT Window Manager configuration file
#
# Users can tailor this file, providing any extra title buttons, menus, etc.
# that may be appropriate for their environment.
#

NoTitleHighlight
NoGrabServer
RestartPreviousState
UsePPosition	"on"
DecorateTransients
NoMenuShadows
#NoRaiseOnMove
#NoRaiseOnResize

# The next 6 lines make functional "Windows 95" style icons for window borders.
NoDefaults
LeftTitleButton "menuicon" = f.menu "defwinops"
#RightTitleButton "raiselwr" = f.raiselower
RightTitleButton "iconify" = f.iconify
RightTitleButton "maxicon" = f.fullzoom
RightTitleButton "cancel" = f.delete
# The next line allows the icons to not have borders.
TitleButtonBorderWidth 0
# The next line reduces the space between title bar elements.
TitlePadding 3

# On the next line, remove the "#" symbol to move the entire window's contents.
#OpaqueMove

# The following lines set fonts:
# For twmi18n, TNTmips overrides this anyway.
TitleFont "-misc-fixed-bold-r-normal--13-120-75-75-c-70-iso8859-1"
#TitleFont "-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*"

# These fonts look nice but take longer to load.  For speed, take the default
#ResizeFont "-adobe-helvetica-medium-r-normal--*-100-*-*-*-*-*-*"
#MenuFont "-adobe-helvetica-medium-r-normal--*-100-*-*-*-*-*-*"
#IconFont "-adobe-helvetica-medium-r-normal--*-100-*-*-*-*-*-*"
#IconManagerFont "-adobe-helvetica-medium-r-normal--*-100-*-*-*"
IconManagerGeometry "+2+2" 14
NoTitle { "TWM Icon Manager" }
#ClientBorderWidth

# The next line sets the grab width for window resizing.
BorderWidth 4
Zoom 64

Cursors {
	Frame	"top_left_arrow"
	Resize	"top_left_arrow"
#	Client	"left_ptr"
	}

Color {
	BorderColor "WhiteSmoke"
	BorderTileBackground "gray60"
	BorderTileForeground "gray60"
	DefaultBackground "maroon"
	DefaultForeground "gray85"
	TitleBackground "maroon"
	TitleForeground "gray85"
	MenuBackground "maroon"
	MenuForeground "gray85"
	MenuTitleBackground "gray70"
	MenuTitleForeground "maroon"
	IconBackground "maroon"
	IconForeground "gray85"
	IconBorderColor "gray85"
	IconManagerBackground "maroon"
	IconManagerForeground "gray85"
	}

#
# Define some useful functions for motion-based actions.
#

MoveDelta 3
Function "move-or-lower" { f.move f.deltastop f.lower }
Function "move-or-raise" { f.move f.deltastop f.raise }
Function "move-or-iconify" { f.move f.deltastop f.iconify }

#
# Set bindings for mouse buttons at various locations
#

Button1 = : root : f.menu "defops"
Button3 = : root : f.menu "defprogs"

Button1 = m : window|icon : f.function "move-or-lower"
Button2 = m : window|icon : f.iconify
Button3 = m : window|icon : f.function "move-or-raise"

Button1 = : title : f.function "move-or-raise"
Button2 = : title : f.raiselower
Button3 = : title : f.function "move-or-lower"

Button1 = : frame : f.resize

Button1 = : icon : f.function "move-or-iconify"
Button2 = : icon : f.iconify

Button1 = : iconmgr : f.iconify
Button2 = : iconmgr : f.iconify

#
# Define menus for Button1 and Button3
#

menu "defops" {
"Operations"	f.title
"Move"		f.move
"Size"		f.resize
"Minimize"	f.iconify
"Maximize"	f.fullzoom
"Raise"		f.raise
"Lower"		f.lower
"Tile"		f.menu "tile"
""		f.nop
"Focus"		f.focus
"Unfocus"	f.unfocus
"Show Iconmgr"	f.showiconmgr
"Hide Iconmgr"	f.hideiconmgr
""		f.nop
"Kill Process"	f.menu "kill"
"Close Window"	f.delete
}

menu "kill"
{
"Use only to close processes that"	f.nop
"have hung.  Data may be lost."		f.nop
""					f.nop
"Kill A Process"			f.destroy
}

menu "defwinops"
{
"Move"		f.move
"Size"		f.resize
"Minimize"	f.iconify
"Maximize"	f.fullzoom
"Raise"		f.raise
"Lower"		f.lower
"Tile"		f.menu "tile"
""		f.nop
"Close"		f.delete
}

menu "tile"
{
"Left"		f.leftzoom
"Right"		f.rightzoom
"Top"		f.topzoom
"Bottom"	f.bottomzoom
}

menu "defprogs" {
"MENU"		f.title
""		f.nop
"Xmag"		f.exec "xmag"
""		f.nop
}
