Guest

FVWM2 Config

By: nstickney on Mar 21st, 2011  |  syntax: None  |  size: 10.43 KB  |  hits: 486  |  expires: Never
download  |  raw  |  embed  |  report abuse
Copied
  1. # ~nstickney/.fvwm/config [elisha]
  2. # Designed for 13.3" (1280x800), Arch Linux
  3. #
  4. # "frustra fit per plura quod potest fieri per pauciora"
  5. # ~William of Ockham
  6. #
  7. # CONTENTS:
  8. # Global Settings
  9. # Colorsets
  10. # Window Decor and Styles
  11. #  -Application Specific Configuration
  12. # Modules:
  13. #  -FvwmPager
  14. #  -FvwmEvent
  15. #  -FvwmIdent
  16. # Bindings
  17. #  -Mouse On Desktop
  18. #  -Window Buttons
  19. #  -Icons
  20. #  -Keyboard
  21. #  -Music Controls
  22. # Menus
  23. # Functions
  24. #
  25. # THOMAS ADAM'S RECOMMENDED LAYOUT:
  26. # SetEnv (Ugh!)
  27. # Colorsets
  28. # Style lines
  29. # Bindings
  30. # Functions
  31.  
  32. #########################
  33. ### GLOBAL STUFF      ###
  34. #########################
  35.  
  36. DesktopSize 2x2
  37. EdgeScroll 100 100
  38. EdgeResistance 0 0
  39. EdgeThickness 1 1
  40. Clicktime 100
  41. MoveThreshold 3
  42. EwmhBaseStruts 210 5 5 5
  43. IgnoreModifiers L25
  44. OpaqueMoveSize -1
  45. HideGeometryWindow Always
  46. CursorStyle root top_left_arrow
  47. DefaultFont "xft:DejaVu Sans Mono:size=09:antialias=True"
  48.  
  49. Style * IconBox 200x240+5+161, IconGrid 1 1
  50.  
  51. #########################
  52. ### COLORSETS         ###
  53. #########################
  54.  
  55. # 0 = Default colors
  56. # 1 = Inactive windows
  57. # 2 = Active windows
  58. # 3 = Inactive menu entry and menu
  59. # 4 = Active menu entry
  60. # 5 = greyed out menu entry (only bg used)
  61. # 6 = module foreground and background
  62. # 7 = hilight colors
  63.  
  64. Colorset 0 RootTransparent buffer, Tint #331100 50, fg #999999
  65. Colorset 1 RootTransparent buffer, Tint #331100 70, fg #999999
  66. Colorset 2 RootTransparent buffer, Tint #331100 90, fg #EEEEEE
  67. Colorset 3 RootTransparent buffer, Tint #331100 80, fg #999999
  68. Colorset 4 fg #EEEEEE
  69. #Colorset 5 RootTransparent buffer, Tint #111111 80
  70.  
  71. #########################
  72. ### WINDOW DECOR      ###
  73. #########################
  74.  
  75. DestroyDecor DefaultDecor
  76. AddToDecor DefaultDecor
  77. + BorderStyle Active Colorset 2 -- Flat
  78. + BorderStyle Inactive Colorset 1 -- Flat
  79. + ButtonStyle All ActiveUp Colorset 2 -- Flat
  80. + ButtonStyle All ActiveDown Colorset 2 -- Flat
  81. + ButtonStyle All Inactive Colorset 1 -- Flat
  82. + TitleStyle RightJustified Height 23 -- Flat
  83. + TitleStyle Active Colorset 2 -- Flat
  84. + TitleStyle Inactive Colorset 1 -- Flat
  85.  
  86. + AddButtonStyle 2 ActiveUp Vector 7 40x45@1 45x40@1 55x40@1 60x50@4 50x60@1 50x75@4 50x75@1 -- Flat
  87. + AddButtonStyle 2 Active Vector 9 40x40@3 45x35@3 55x35@3 60x40@3 60x45@3 50x50@3 50x55@3 50x65@4 50x65@3 -- Flat
  88. + AddButtonStyle 2 Active MiniIcon -- Flat
  89. + AddButtonStyle 2 InActive MiniIcon -- Flat
  90.  
  91. + AddButtonStyle 1 ActiveUp Vector 4 30x35@1 70x75@1 70x35@4 30x75@1 -- Flat
  92. + AddButtonStyle 1 Active Vector 4 30x30@3 70x70@3 70x30@4 30x70@3 -- Flat
  93.  
  94. + AddButtonStyle 3 ActiveUp Vector 7 30x35@1 30x75@4 70x75@1 70x35@4 30x35@1 30x40@4 70x40@1 -- Flat
  95. + AddButtonStyle 3 Active Vector 7 30x30@3 30x70@3 70x70@3 70x30@3 30x30@3 30x35@3 70x35@3 -- Flat
  96.  
  97. + AddButtonStyle 5 ActiveUp Vector 4 30x65@1 70x65@1 70x55@4 30x55@1 -- Flat
  98. + AddButtonStyle 5 Active Vector 5 30x60@3 70x60@3 70x50@3 30x50@3 30x60@3 -- Flat
  99.  
  100. Style * UseDecor DefaultDecor
  101. Style * TitleAtLeft
  102. Style * Colorset 1, HilightColorset 2
  103. Style * BorderColorset 1, HilightBorderColorset 2
  104. Style * BorderWidth 2, HandleWidth 2
  105. Style * WindowShadeScrolls, WindowShadeSteps 25
  106.  
  107. Style * IconTitleColorset 1, HilightIconTitleColorset 2, IconTitleRelief 1
  108. Style * IconBackgroundColorset 1, IconBackgroundRelief 1
  109.  
  110. Style * SloppyFocus, MouseFocusClickRaises
  111. Style * DecorateTransient, StackTransientParent
  112. Style * DontLowerTransient, DontRaiseTransient
  113. Style * GrabFocusOff, GrabFocusTransientOff
  114.  
  115. ### APP SPECIFIC CONF ###
  116. Style "Buddy List" !Title, Sticky, WindowListSkip, CirculateSkip
  117. Style "QuakeTerm" !Title, Sticky, WindowListSkip, CirculateSkip, PositionPlacement +210p +0p
  118. Style "Quick Search Box" !Title, !Borders, !Handles, WindowListSkip, CirculateSkip
  119. Style "stalonetray" !Title, !Borders, !Handles, Sticky, WindowListSkip, CirculateSkip
  120. Style "Conky" !Title, !Borders, !Handles, Sticky, WindowListSkip, CirculateSkip
  121. Style "nstickney - Skype*" !Title, Sticky, WindowListSkip, CirculateSkip
  122.  
  123. #########################
  124. ### MODULES           ###
  125. #########################
  126.  
  127. ### PAGER MODULE      ###
  128. DestroyModuleConfig FvwmPager: *
  129. *FvwmPager: Geometry 200x125+5+5
  130. *FvwmPager: Colorset 0
  131. *FvwmPager: Colorset * 1
  132. *FvwmPager: HilightColorset * 2
  133. *FvwmPager: WindowColorsets 1 2
  134. *FvwmPager: BalloonColorset * 1
  135. *FvwmPager: SloppyFocus
  136. *FvwmPager: MiniIcons
  137. *FvwmPager: UseSkipList
  138. *FvwmPager: Font none
  139. *FvwmPager: WindowBorderWidth 1
  140. *FvwmPager: NoSeparators
  141. *FvwmPager: Balloons All
  142. *FvwmPager: BalloonYOffset +1
  143. *FvwmPager: BalloonBorderWidth 0
  144.  
  145. Style FvwmPager NoTitle, !Handles, !Borders, Sticky, NeverFocus
  146. Style FvwmPager WindowListSkip, CirculateSkip, !Iconifiable
  147.  
  148. ### EVENT MODULE      ###
  149. DestroyModuleConfig FvwmEvent: *
  150. *FvwmEvent: add_window SetFocusTrans
  151. *FvwmEvent: leave_window SetUnfocusTrans
  152. *FvwmEvent: enter_window SetFocusTrans
  153. *FvwmEvent: deiconify DeThumbnail
  154. *FvwmEvent: deiconify RearrangeThumbs
  155.  
  156. ### IDENT MODULE      ###
  157. DestroyModuleConfig FvwmIdent: *
  158. *FvwmIdent: Colorset 0
  159.  
  160. #########################
  161. ### BINDINGS          ###
  162. #########################
  163.  
  164. ### Mouse on Desktop ###
  165. Mouse 1 R A Menu LeftMenu
  166. Mouse 1 R C Menu RightMenu
  167. Mouse 1 R M Menu CenterMenu
  168. Mouse 2 R A Menu CenterMenu
  169. Mouse 3 R A Menu RightMenu
  170.  
  171. ### Window Buttons ###
  172. Mouse 1 2 A FvwmIdentOrClose
  173. Mouse 3 2 A Menu WindowMenu
  174.  
  175. Mouse 1 T A MoveOrRaise
  176. Mouse 2 T A LeftMaximize
  177. Mouse 3 T A RightMaximize
  178.  
  179. Mouse 1 5 A Thumbnail
  180. Mouse 2 5 A WindowShade
  181. Mouse 3 5 A Stick
  182.  
  183. Mouse 1 3 A Maximize 100 100
  184. Mouse 2 3 A Maximize 0 100
  185. Mouse 3 3 A Maximize 100 0
  186.  
  187. Mouse 1 1 A DeleteOrDestroy
  188.  
  189. ### Icons ###
  190. Mouse 2 I A Menu WindowMenu
  191. Mouse 3 I A Iconify
  192.  
  193. ### Keyboard ###
  194. Key Super_L A A QuakeTerm
  195. Key Super_R A A QuakeChat
  196. Key Space A M QuakeChat
  197. Key Super_L A M Menu LeftMenu
  198. Key Super_R A M Menu CenterMenu
  199. Key Menu A M Menu RightMenu
  200. Key Tab A M WindowList NoGeometry, NoDeskNum, NoCurrentDeskTitle
  201. Key L A M Lock
  202. Key Print A A DesktopShot
  203. Key Print A M WindowShot
  204.  
  205. ### Music Controls ###
  206. Key XF86AudioNext A A Exec exec mpc next
  207. Key XF86AudioPrev A A Exec exec mpc prev
  208. Key XF86AudioPlay A A Exec exec mpc toggle
  209. Key XF86AudioRaiseVolume A A Exec exec amixer -c 0 set Master 2+
  210. Key XF86AudioLowerVolume A A Exec exec amixer -c 0 set Master 2-
  211. Key XF86AudioMute A A Exec exec amixer -c 0 set Master toggle
  212.  
  213. #########################
  214. ### MENUS             ###
  215. #########################
  216.  
  217. MenuStyle * PopupDelay 50, PopdownImmediately
  218. MenuStyle * PopupOffset 1 80
  219. MenuStyle * BorderWidth 1
  220. MenuStyle * Hilight3DThin
  221. MenuStyle * PopupAsSubmenu, HoldSubmenus, SubmenusRight
  222. MenuStyle * VerticalItemSpacing 3 3
  223. MenuStyle * MenuColorset 3
  224. MenuStyle * ActiveColorset 4
  225. MenuStyle * ActiveFore
  226.  
  227. ## Read in menus from separate file
  228. Read /home/nstickney/Dropbox/Config/menus.fvwm
  229.  
  230. #########################
  231. ### FUNCTIONS         ###
  232. #########################
  233.  
  234. DestroyFunc UrgencyFunc
  235.  
  236. DestroyFunc StartFunction
  237. AddToFunc StartFunction
  238. # Set the background
  239. + I Exec exec fvwm-root --retain-pixmap ~/Pictures/Backgrounds/current.png
  240. # Turn on powersave mode
  241. + I Exec exec xset +dpms
  242. # Start the pager and Event module
  243. + I Module FvwmPager
  244. + I Module FvwmEvent
  245. # Get rid of Adobe Flash cookies
  246. + I Exec exec rm -rf ~/.macromedia/Flash_Player/#SharedObjects/*
  247. # Start the composite manager
  248. + I Exec exec xcompmgr -cC
  249. # Remove any leftover thumbnail icons
  250. + I Test (init) Exec exec rm -rf /tmp/*.png
  251. # Start the "Kuake" terminal
  252. + I Test (init) QuakeURXVT
  253. # Start a bunch of stuff I use
  254. + I Test (init) Exec exec mpdscribble
  255. + I Test (init) Exec exec conky
  256. + I Test (init) Exec exec stalonetray --dockapp-mode
  257. + I Test (init) Exec exec pidgin
  258. + I Test (init) Exec exec skype
  259. + I Test (init) Exec exec dropboxd
  260. + I Test (init) Exec exec keepassx
  261. + I Test (init) Exec exec transmission-gtk
  262. # Fix stuff on restart
  263. + I Test (restart) All (Iconic) ReThumbnail
  264. + I Test (restart) All ("QuakeTerm" Shaded) WindowShade N
  265. + I Test (restart) All ("Buddy List" Shaded) WindowShade E
  266. + I Test (restart) All ("* - Skype*" Shaded) WindowShade E
  267. + I Test (restart) All SetUnfocusTrans
  268. + I All (QuakeURXVT) Move +210p +0p
  269.  
  270. DestroyFunc LeftMaximize
  271. AddToFunc LeftMaximize
  272. + C Raise
  273. + C ThisWindow (Maximized) Maximize
  274. + C Maximize 75 100
  275.  
  276. DestroyFunc RightMaximize
  277. AddToFunc RightMaximize
  278. + C Raise
  279. + C ThisWindow (Maximized) Maximize
  280. + C Maximize 75 100
  281. + C ThisWindow (Maximized) Move -+5p +5p
  282.  
  283. DestroyFunc MoveOrRaise
  284. AddToFunc MoveOrRaise
  285. + C Raise
  286. + M MovePretty
  287.  
  288. DestroyFunc MovePretty
  289. AddToFunc MovePretty
  290. + I SetUnfocusTrans
  291. + I Move
  292. + I SetFocusTrans
  293.  
  294. DestroyFunc FvwmIdentOrClose
  295. AddToFunc FvwmIdentOrClose
  296. + C FvwmIdent
  297. + D Delete
  298.  
  299. SetEnv fvwm_icon_size 96
  300. DestroyFunc Thumbnail
  301. AddToFunc Thumbnail
  302. + I Raise
  303. + I ThisWindow (!Shaded, Iconifiable, !Iconic) PipeRead \
  304.     "~/bin/thumb $[w.id] $[fvwm_icon_size] /tmp/icon.tmp.$[w.id].png \
  305.      && echo WindowStyle IconOverride, Icon /tmp/icon.tmp.$[w.id].png"
  306. + I Iconify
  307.  
  308. DestroyFunc DeThumbnail
  309. AddToFunc DeThumbnail
  310. + I Exec exec rm -rf /tmp/icon.tmp.$[w.id].png
  311.  
  312. DestroyFunc ReThumbnail
  313. AddToFunc ReThumbnail
  314. + I Iconify
  315. + I Thumbnail
  316.  
  317. DestroyFunc RearrangeThumbs
  318. AddToFunc RearrangeThumbs
  319. + I All (CurrentPage, Iconic) PlaceAgain Icon
  320.  
  321. DestroyFunc SetUnfocusTrans
  322. AddToFunc SetUnfocusTrans
  323. + I ThisWindow (!URxvt) SetUnfocusTrans2
  324.  
  325. DestroyFunc SetUnfocusTrans2
  326. AddToFunc SetUnfocusTrans2
  327. + I Exec exec transset-df --dec .5 -m .72 -i $[w.id]
  328.  
  329. DestroyFunc SetFocusTrans
  330. AddToFunc SetFocusTrans
  331. + I Exec exec transset-df --inc .5 -x .97 -i $[w.id]
  332.  
  333. DestroyFunc QuakeTerm
  334. AddToFunc QuakeTerm
  335. + I All ("QuakeTerm") WindowShade N
  336. + I All ("QuakeTerm" !Shaded) Raise
  337.  
  338. DestroyFunc QuakeChat
  339. AddToFunc QuakeChat
  340. + I All ("Buddy List") WindowShade E
  341. + I All ("nstickney - Skype*") WindowShade E
  342. + I All ("Buddy List" !Shaded) Raise
  343. + I All ("nstickney - Skype*" !Shaded) Raise
  344.  
  345. DestroyFunc Lock
  346. AddToFunc Lock
  347. + I Exec exec xlock
  348.  
  349. DestroyFunc DeleteOrDestroy
  350. AddToFunc DeleteOrDestroy
  351. + C Delete
  352. + D Destroy
  353.  
  354. DestroyFunc QuakeURXVT
  355. AddToFunc QuakeURXVT
  356. + I Exec exec urxvt -geometry 107x25+210+0 -name QuakeTerm
  357. + I Wait QuakeTerm
  358. + I All ("QuakeTerm") Move +210p +0p
  359. + I QuakeTerm
  360.  
  361. DestroyFunc DesktopShot
  362. AddtoFunc DesktopShot
  363. + I Exec exec scrot -d 5 ~/Pictures/Screenshots/`uname -n`-`date +%R.%d%b%Y`.png
  364.  
  365. DestroyFunc WindowShot
  366. AddToFunc WindowShot
  367. + I ThisWindow Exec exec ~/bin/screenshot $[w.id] $[w.width] ~/Pictures/Screenshots/$[w.name]-`date +%R.%d%b%Y`.png