]> git.phdru.name Git - dotfiles.git/blob - .fvwm/main.m4
6f444fd2f1821d3fc2886b377adc687ece971534
[dotfiles.git] / .fvwm / main.m4
1 ##########################################################################
2 # FVWM - F? Virtual Window Manager, Version 2.x (fvwm2) Configuration File
3 #
4
5 dnl The file is in m4 format, use FvwmM4 module to read it
6 dnl like this: ModuleSynchronous FvwmM4 -lock main.m4
7 dnl
8 dnl This is to prevent FvwmM4 to shadow $HOME
9 undefine(`HOME')dnl
10 dnl
11 dnl Echo dimension
12 `#' width = WIDTH()dnl
13 divert(-1)
14
15 dnl TrueType Fonts
16 define(`VERY_SMALL_FONT', `xft:Sans:size=10')
17 define(`SMALL_FONT', `xft:Sans:size=12')
18 define(`MEDIUM_FONT', `xft:Sans:size=14')
19 define(`BIG_FONT', `xft:Sans:size=16')
20 define(`LARGE_FONT', `xft:Sans:size=18')
21 define(`HUGE_FONT', `xft:Sans:size=20')
22 define(`GIGANTIC_FONT', `xft:Sans:size=22')
23
24 dnl Bold TT fonts
25 define(`SMALL_BOLD_FONT', SMALL_FONT`:Bold')
26 define(`MEDIUM_BOLD_FONT', MEDIUM_FONT`:Bold')
27 define(`BIG_BOLD_FONT', BIG_FONT`:Bold')
28
29 define(`TITLE_FONT', MEDIUM_FONT)
30 define(`ICON_FONT', LARGE_FONT)
31
32 dnl Font and geometry aliases that depend on whether the screen resolution is
33 dnl 800x600, 1024x768 or 1920x1200
34
35 define(`PAGER_GEOM',
36 ifelse(eval(WIDTH < 1024), 1, `365x100+0+0',
37        eval(WIDTH < 1920), 1, `365x100+0+0', `600x160+0+0'))
38
39 define(`SMALL_PAGER_FONT', ifelse(eval(WIDTH < 1920), 1, VERY_SMALL_FONT, SMALL_FONT))
40 define(`PAGER_FONT', ifelse(eval(WIDTH < 1920), 1, SMALL_FONT, BIG_FONT))
41 define(`BUTTONS_FONT', PAGER_FONT)
42
43
44 define(`MENU_FONT',
45 ifelse(eval(WIDTH < 1024), 1, BIG_FONT,
46        eval(WIDTH < 1920), 1, LARGE_FONT, GIGANTIC_FONT))
47 define(`IDENT_FONT', MENU_FONT)
48 define(`WIN_LIST_FONT', MENU_FONT)
49 define(`ICON_BOX_FONT', MENU_FONT)
50
51
52 dnl XSetBg message width and font
53 define(`TEXT_WIDTH',
54 ifelse(eval(WIDTH < 1024), 1, 70,
55        eval(WIDTH < 1920), 1, 75, 80))
56
57 define(`MESSAGE_FONT', `Nimbus Sans L 18')
58
59
60 dnl Terminal emulator
61 define(`TERM_GEOM',
62 ifelse(eval(WIDTH < 1024), 1, `80x25',
63        eval(WIDTH < 1920), 1, `80x30', `80x32'))
64
65 define(`TERM_GEOM_BOTLT', TERM_GEOM`+0-0')
66 define(`TERM_GEOM_BOTRT', TERM_GEOM`-0-0')
67
68 define(`TERM_GEOM_BIG',
69 ifelse(eval(WIDTH < 1024), 1, `96x30',
70        eval(WIDTH < 1920), 1, `112x32+2-0', `119x32+1-0'))
71
72
73 define(`TERM', `urxvt')
74 define(`TERM_KOI8', `Exec LC_CTYPE=ru_RU.KOI8-R exec TERM')
75 define(`TERM_RU_UTF8', `Exec LC_CTYPE=ru_RU.UTF-8 exec TERM -name URxvt')
76 define(`TERM_EN_UTF8', `Exec LC_CTYPE=en_US.UTF-8 exec TERM -name URxvt')
77 define(`TERM_HEB_UTF8', `Exec LC_CTYPE=he_IL.UTF-8 exec TERM -name URxvt')
78 define(`TERM_KOI8_BOTLT', `TERM_KOI8 -geometry TERM_GEOM_BOTLT')
79 define(`TERM_RU_UTF8_BOTLT', `TERM_RU_UTF8 -geometry TERM_GEOM_BOTLT')
80 define(`TERM_KOI8_BOTRT', `TERM_KOI8 -geometry TERM_GEOM_BOTRT')
81 define(`TERM_RU_UTF8_BOTRT', `TERM_RU_UTF8 -geometry TERM_GEOM_BOTRT')
82 define(`TERM_KOI8_BIG', `TERM_KOI8 -geometry TERM_GEOM_BIG')
83 define(`TERM_UTF8_BIG', `TERM_RU_UTF8 -geometry TERM_GEOM_BIG')
84
85
86 define(`SSH', `cgmem_nice 300 ssh')
87
88 define(`TERM_SSH', `$1 -e SSH $2')
89
90 define(`TERM_TITLE_SSH', `$1 -title "$3" -n "$3" -e SSH $2')
91
92 define(`TERM_KOI8_SSH',
93 `TERM_TITLE_SSH(`TERM_KOI8', $1, $2)')
94
95 define(`SSH_SCREEN_KOI8',
96 `SSH -t $1 TZ="$(cat /etc/timezone)" exec /usr/bin/screen -xRR -S default-koi8')
97 define(`SSH_SCREEN_UTF8',
98 `SSH -t $1 TZ="$(cat /etc/timezone)" exec /usr/bin/screen -xRR -S default-utf8')
99
100 define(`TERM_TITLE_SSH_SCREEN_KOI8',
101 `$1 -title "$3 scr" -n "$3 scr" -e SSH_SCREEN_KOI8($2)')
102
103 define(`TERM_TITLE_SSH_SCREEN_UTF8',
104 `$1 -title "$3 scr" -n "$3 scr" -e SSH_SCREEN_UTF8($2)')
105
106 define(`MENU_TERM_KOI8_SSH',
107 `"$2 (koi8)" TERM_KOI8_SSH($1, $2)')
108
109 define(`TERM_KOI8_BOTLT_SSH',
110 `TERM_TITLE_SSH(`TERM_KOI8_BOTLT', $1, $2)')
111
112 define(`TERM_KOI8_BOTRT_SSH',
113 `TERM_TITLE_SSH(`TERM_KOI8_BOTRT', $1, $2)')
114
115 define(`MENU_TERM_KOI8_BOTLT_SSH',
116 `"$2 (btlt,koi8)" TERM_KOI8_BOTLT_SSH($1, $2)')
117
118 define(`MENU_TERM_KOI8_BOTRT_SSH',
119 `"$2 (btrt,koi8)" TERM_KOI8_BOTRT_SSH($1, $2)')
120
121 define(`TERM_KOI8_SSH_SCREEN',
122 `TERM_TITLE_SSH_SCREEN_KOI8(`TERM_KOI8', $1, $2)')
123
124 define(`MENU_TERM_KOI8_SSH_SCREEN',
125 `"$2 (koi8,scr)" TERM_TITLE_SSH_SCREEN_KOI8(`TERM_KOI8', $1, $2)')
126
127 define(`TERM_KOI8_BOTLT_SSH_SCREEN',
128 `TERM_TITLE_SSH_SCREEN_KOI8(`TERM_KOI8_BOTLT', $1, $2)')
129
130 define(`TERM_KOI8_BOTRT_SSH_SCREEN',
131 `TERM_TITLE_SSH_SCREEN_KOI8(`TERM_KOI8_BOTRT', $1, $2)')
132
133 define(`MENU_TERM_KOI8_BOTLT_SSH_SCREEN',
134 `"$2 (btlt,koi8,scr)" TERM_KOI8_BOTLT_SSH_SCREEN($1, $2)')
135
136 define(`MENU_TERM_KOI8_BOTRT_SSH_SCREEN',
137 `"$2 (btrt,koi8,scr)" TERM_KOI8_BOTRT_SSH_SCREEN($1, $2)')
138
139 define(`TERM_UTF8_SSH',
140 `TERM_TITLE_SSH(`TERM_RU_UTF8', $1, $2)')
141
142 define(`MENU_TERM_UTF8_SSH',
143 `"$2 (utf8)" TERM_UTF8_SSH($1, $2)')
144
145 define(`TERM_UTF8_BOTLT_SSH',
146 `TERM_TITLE_SSH(`TERM_RU_UTF8_BOTLT', $1, $2)')
147
148 define(`TERM_UTF8_BOTRT_SSH',
149 `TERM_TITLE_SSH(`TERM_RU_UTF8_BOTRT', $1, $2)')
150
151 define(`MENU_TERM_UTF8_BOTLT_SSH',
152 `"$2 (btlt,utf8)" TERM_UTF8_BOTLT_SSH($1, $2)')
153
154 define(`MENU_TERM_UTF8_BOTRT_SSH',
155 `"$2 (btrt,utf8)" TERM_UTF8_BOTRT_SSH($1, $2)')
156
157 define(`TERM_UTF8_SSH_SCREEN',
158 `TERM_TITLE_SSH_SCREEN_UTF8(`TERM_RU_UTF8', $1, $2)')
159
160 define(`MENU_TERM_UTF8_SSH_SCREEN',
161 `"$2 (utf8,scr)" TERM_UTF8_SSH_SCREEN($1, $2)')
162
163 define(`TERM_UTF8_BOTLT_SSH_SCREEN',
164 `TERM_TITLE_SSH_SCREEN_UTF8(`TERM_RU_UTF8_BOTLT', $1, $2)')
165
166 define(`TERM_UTF8_BOTRT_SSH_SCREEN',
167 `TERM_TITLE_SSH_SCREEN_UTF8(`TERM_RU_UTF8_BOTRT', $1, $2)')
168
169 define(`MENU_TERM_UTF8_BOTLT_SSH_SCREEN',
170 `"$2 (btlt,utf8,scr)" TERM_UTF8_BOTLT_SSH_SCREEN($1, $2)')
171
172 define(`MENU_TERM_UTF8_BOTRT_SSH_SCREEN',
173 `"$2 (btrt,utf8,scr)" TERM_UTF8_BOTRT_SSH_SCREEN($1, $2)')
174
175 define(`TERM_KOI8_BIG_SSH',
176 `TERM_KOI8_BIG -title "$2" -n "$2" -e SSH "$1"')
177
178 define(`MENU_TERM_KOI8_BIG_SSH',
179 `"$2 (koi8)" TERM_KOI8_BIG_SSH($1, $2)')
180
181 define(`TERM_KOI8_BIG_SSH_SCREEN',
182 `TERM_KOI8_BIG -title "$2" -n "$2" -e SSH_SCREEN_KOI8 "$1"')
183
184 define(`MENU_TERM_KOI8_BIG_SSH_SCREEN',
185 `"$2 (koi8,scr)" TERM_KOI8_BIG_SSH_SCREEN($1, $2)')
186
187 divert
188
189 ##########################################################################
190 # PATH Setup
191 #
192 # Colon seperated unix directory paths for Modules, xpm files, and bitmaps
193 #ModulePath /usr/lib/fvwm
194 ImagePath /usr/share/icons/hicolor/32x32/apps/:/usr/share/pixmaps/fvwm:/usr/share/pixmaps:/usr/include/X11/bitmaps #:/usr/local/firefox/browser/chrome/icons/default:/usr/local/firefox/browser/icons
195
196 ############################################################################
197 # COLORS and FONTS
198 #
199 # Set the fore and back border colors for the window that has focus
200 Style * HilightFore Black, HilightBack #c06077
201
202 # Set fore/back border colors for all other windows
203 Style * Color Black/#60a0c0
204
205 # Set colors/font for pop-up menus
206 # Syntax: MenuStyle forecolor backcolor shadecolor font style(fvwm/mwm)
207 MenuStyle * FVWM, Foreground Black, Background grey, Greyed SlateGrey, Font MENU_FONT
208
209 # Set fonts to use on title bar and icon label
210 Style * Font              TITLE_FONT
211
212 ############################################################################
213 # ICON Setup
214 #
215 # If you don't want icons for some or all windows (or all of them!)
216 # Style * !Icon
217
218 # If you want ALL icons to follow you around the desktop (Sticky)
219 #Style * StickyIcon
220
221 # Auto Place Icons is a nice feature (Left Top Right Bottom)
222 #Style * IconBox 10 -75 -10 -0
223
224 Style * IconFont          ICON_FONT
225
226 ############################################################################
227 # FOCUS Setup
228 #
229 # Does the window with focus control the colormap, or the one under the mouse
230 ColormapFocus FollowsMouse
231
232 # Uncomment this to force you to click in a window to give it focus
233 #Style * ClickToFocus
234
235 # default: focus follows mouse
236 #Style * MouseFocus
237 #Style * FocusFollowsMouse
238
239 # If you knock your mouse out of the term, it keeps focus while in root window
240 Style *           SloppyFocus
241
242 ############################################################################
243 # MISC Setup
244 #
245 # click/release must occur in <n milliseconds to be a "click"
246 ClickTime 250
247
248 # if the window occupies less than n% of the screen, draw it opaque
249 OpaqueMoveSize 100
250
251 # Do not flip pages on the edge of the screen, but allow to move windows
252 EdgeScroll 0 0
253 EdgeResistance 10000
254 Style * EdgeMoveDelay 500
255 Style * EdgeMoveResistance 100
256
257 # MWM Emulation: Don't ignore hints for functions and transient decoration
258 #Style * MWMFunctions, MWMDecor, MWMButtons, MWMMenus
259 Style * MWMFunctions, MWMDecor, MWMButtons
260
261 # Changes the look of the "rubberband" you see when moving windows (0 - 255)
262 XORvalue 80
263
264 ###########################################################################
265 # PAGER Setup
266 #
267 # set the desk top size in units of physical screen size (width x height)
268 DesktopSize 2 2
269
270 ############################################################################
271 # WINDOW Placement
272 #
273 Style * PositionPlacement Center
274
275 ############################################################################
276 # STYLE Flag Setup
277 #
278 # (decorations and window options)
279 # Note: Order is important!! If compatible styles are set, styles are ORed
280 # together. If conflicting styles are set, the last one specified is used.
281
282 # change the default width, set a global icon, and give borders to popups
283 Style * BorderWidth 5, HandleWidth 5, Icon unknown1.xpm
284 Style * DecorateTransient, ClickToFocusRaisesOff
285
286 Style "Fvwm*"           !Title, Sticky, WindowListSkip
287 Style "FvwmButtons"     !Handles, BorderWidth 0, Layer 2
288 Style "FvwmPager"       Layer 2
289
290 # Terminals
291 Style "*term"           Icon term.xpm
292 Style "*rxvt"           Icon term.xpm
293 Style "term-im-local"   Icon pidgin-menu.xpm
294 Style "term-im-remote"  Icon rcalc2.xpm
295 Style "term-im-*"       IconBox 630 -75 -2 -2, IconGrid 200 80
296 Style "term-im-*"       StartsOnPage 1 1 0, StartIconic
297
298 # Browsers' windows
299 Style "Certificate Manager" PositionPlacement Center
300 Style "*Downloads"      PositionPlacement 50-50w +5
301 Style "*Mozilla*"       PositionPlacement +0 -0
302
303 Style "*Chromium*"      PositionPlacement +0 -0
304
305 # IM
306 Style "Gajim"           PositionPlacement +0 -0
307 Style "* - Gajim"       MinOverlapPercentPlacement
308 # Pidgin
309 Style "Buddy List"      PositionPlacement +0 -0
310 Style "*Pidgin*"        MinOverlapPercentPlacement
311
312 # (S)MPlayer
313 Style "*MPlayer*"       Layer 6, PositionPlacement 250p 100p
314 Style "*mpv"            Layer 6, PositionPlacement 250p 100p
315
316 Style "*clock"          !Title, Sticky, WindowListSkip, Color Black/#40c040, NeverFocus, PositionPlacement 50-50w +1p, Layer 2
317 Style "deadbeef"        PositionPlacement -0 -0
318 Style "gxmessage"       PositionPlacement 50-50w +20
319 Style "*lock"           !Title, Sticky, WindowListSkip
320 Style "Mosaic"          NoPPosition
321 Style "xbiff"           Icon mail1.xpm, !Title, Sticky, WindowListSkip
322 Style "xcalc"           Icon xcalc.xpm
323 Style "xconsole"        !Title, Sticky, WindowListSkip, NeverFocus
324 Style "xload"           !Title, Sticky, WindowListSkip, NeverFocus
325 Style "xman"            Icon xman.xpm
326 Style "xmh"             Icon mail2.xpm
327 Style "xsession"        !Title, Sticky, WindowListSkip, ClickToFocus
328 Style "XXkb"            !Title, !Borders, Sticky, WindowListSkip, Layer 5
329
330 ############################################################################
331 # BUTTON Setup
332 #
333
334 ## Buttons actually being used (duplicated below)
335 # small up triangle
336 #ButtonStyle 2 4 50x35@1 65x65@0 35x65@0 50x35@1
337 # small down triangle
338 #ButtonStyle 4 4 50x65@1 35x35@1 65x35@1 50x65@0
339 # Stylized X
340 #ButtonStyle 3 16 20x20@1 30x20@1 50x40@1 70x20@1 80x20@1 80x30@0 60x50@0 80x80@0 70x80@0 50x60@0 30x80@0 20x80@0 20x70@0 40x50@1 20x30@0 20x20@1
341
342 ## Triangles
343 #
344 # Small up Triangle
345 # ButtonStyle * 4 50x35@1 65x65@0 35x65@0 50x35@1
346 # Small down Triangle
347 #ButtonStyle * 4 50x65@1 35x35@1 65x35@1 50x65@0
348 # Large up Triangle
349 #ButtonStyle 6 4 50x25@1 75x75@0 25x75@0 50x25@1
350 # Large down Triangle
351 #ButtonStyle 8 4 50x75@1 25x25@1 75x25@1 50x75@0
352
353 ## Boxes
354 #
355 # Big Box
356 ButtonStyle 4 5 25x25@1 25x75@1 75x75@0 75x25@0 25x25@1
357 # Little Box
358 ButtonStyle 5 5 40x40@1 60x40@1 60x60@0 40x60@0 40x40@1
359 # Tall Box
360 #ButtonStyle 7 5 40x25@1 60x25@1 60x75@0 40x75@0 40x25@1
361 # Dot
362 #ButtonStyle 5 5 45x45@1 55x45@1 55x55@0 45x55@0 45x45@1
363 # Big Box with arrow (left-up to right-down) to little box (iconify)
364 #ButtonStyle 6 14 20x20@1 20x70@1 70x70@0 70x20@0 20x20@1 60x60@0 60x50@0 60x60@0 50x60@0 60x60@0 60x80@0 80x80@0 80x60@0 60x60@0
365 # Big Box with arrow (right-up to left-down) to little box (iconify)
366 ButtonStyle 6 14 70x20@0 70x70@0 20x70@1 20x20@1 70x20@1 30x60@0 30x50@0 30x60@0 40x60@0 30x60@0 30x80@0 10x80@0 10x60@0 30x60@0
367
368 ## X's
369 #
370 # Standard X
371 #ButtonStyle 3 17 20x20@1 30x20@1 50x40@1 70x20@1 80x20@1 80x30@0 60x50@0 80x70@1 80x80@0 70x80@0 50x60@0 30x80@0 20x80@0 20x70@0 40x50@1 20x30@0 20x20@1
372 ButtonStyle 2 17 20x20@1 30x20@1 50x40@1 70x20@1 80x20@1 80x30@0 60x50@0 80x70@1 80x80@0 70x80@0 50x60@0 30x80@0 20x80@0 20x70@0 40x50@1 20x30@0 20x20@1
373 # Funky X
374 #ButtonStyle 3 13 26x29@1 34x21@1 50x35@1 70x21@1 79x29@1 63x48@0 79x65@1 70x75@0 50x61@0 34x75@0 26x65@0 44x48@1 26x29@0
375 # Stylized X
376 #ButtonStyle 3 16 20x20@1 30x20@1 50x40@1 70x20@1 80x20@1 80x30@0 60x50@0 80x80@0 70x80@0 50x60@0 30x80@0 20x80@0 20x70@0 40x50@1 20x30@0 20x20@1
377
378 ## Lightning Bolts
379 #
380 # Small Lightning Bolt (skinny at both ends)
381 #ButtonStyle 5 7 70x15@0 30x55@1 50x55@0 40x85@1 80x45@0 60x45@1 70x15@0
382 # Big Lighting Bolt (Fat at top, comes to a point)
383 #ButtonStyle 6 8 35x15@1 20x50@1 40x50@0 30x80@1 75x40@0 50x40@1 75x15@0 35x15@1
384
385 ## Miscellaneous Buttons
386 #
387 # Nested Right Angles (looks kinda crappy)
388 #ButtonStyle 5 13 10x0@1 80x0@1 80x10@1 80x80@0 0x80@0 0x60@1 10x65@1 70x65@0 70x0@0 55x0@1 55x10@1 55x55@0 10x55@0
389 # Nested Right Angles (looks nice)
390 #ButtonStyle 6 14 0x0@1 0x20@1 20x20@0 20x0@0 0x0@1 0x25@1 25x25@1 25x0@1 55x0@1 55x55@0 0x55@0 0x60@1 60x60@1 60x0@1
391 # 4 Horizontal bars (sticky)
392 #ButtonStyle 7 12 10x23@0 90x23@0 90x28@0 10x28@1 10x47@1 90x47@0 90x52@0 10x52@1 10x70@2 90x70@0 90x76@0 10x76@1
393 ButtonStyle 3 12 10x23@0 90x23@0 90x28@0 10x28@1 10x47@1 90x47@0 90x52@0 10x52@1 10x70@2 90x70@0 90x76@0 10x76@1
394 # Expanding Windows (iconify -- looks NICE)
395 #ButtonStyle 8 16 60x40@1 60x80@0 15x80@0 15x40@1 60x40@1 40x40@1 40x25@1 75x25@1 75x60@0 60x60@0 75x60@0 75x40@0 85x40@0 85x15@0 60x15@1 60x25@1
396
397 ## Arrows Galore
398 #
399 # Up Arrow
400 #ButtonStyle 3 8 40x80@1 40x50@1 20x50@1 50x20@1 80x50@0 60x50@0 60x80@0 40x80@0
401 # Down Arrow
402 #ButtonStyle 3 8 40x20@1 40x50@1 20x50@1 50x80@1 80x50@0 60x50@0 60x20@0 40x20@1
403 # Left arrow  ( <- )
404 #ButtonStyle 7 8 80x40@1 50x40@1 50x20@1 20x50@1 50x80@0 50x60@0 80x60@0 80x40@0
405 # Right arrow ( -> )
406 #ButtonStyle 8 8 20x40@1 50x40@1 50x20@1 80x50@1 50x80@0 50x60@0 20x60@0 20x40@1
407 # Horizontal Line with arrowheads on left and right ( <-> )
408 #ButtonStyle * 12 10x50@1 35x25@1 35x40@1 65x40@1 65x25@1 90x50@1 65x75@0 65x60@0 35x60@0 35x75@0 10x50@0 10x50@1
409 # Vertical Line with arrowheads on top and bottom
410 #ButtonStyle * 12 50x10@1 25x35@1 40x35@1 40x60@1 25x60@1 50x85@1 75x60@0 60x60@0 60x35@0 75x35@0 50x10@0 50x10@1
411 # Diagonal Line with arrowheads on top and bottom ( / )
412 #ButtonStyle 5 11 80x15@1 45x15@1 55x25@1 25x55@1 15x45@1 15x80@1 50x80@0 40x70@0 70x40@0 80x50@0 80x15@0
413 # Diagonal Line with arrowheads on top and bottom ( \ )
414 #ButtonStyle 6 12 55x15@0 45x25@0 75x55@0 85x45@0 85x80@0 50x80@0 60x70@1 30x40@1 20x50@1 20x15@1 55x15@1 55x15@0
415 #
416 # the number "2"
417 #ButtonStyle 8 12 80x80@0 22x80@0 80x40@0 70x25@0 30x25@0 20x35@0 20x30@1 30x20@1 70x20@1 80x30@1 20x75@1 80x75@1
418
419 ############################################################################
420 # MOUSE Setup
421 #
422 # First, the root window. Button 1 brings up the Main Menu. B2 is the
423 # window operations list, and B3 is the winlist module
424 #     Button    Context Modifi  Function
425 Mouse 1         R       A       Menu RootMenu Nop
426 Mouse 2         R       A       Menu Window-Ops Nop
427 Mouse 3         R       A       WindowList
428
429 # Now, title bar buttons
430 # Left button is the Window-Ops2 menu
431 #     Button    Context Modifi  Function
432 Mouse 0         1       A       Menu Window-Ops2 Close
433 Mouse 0         3       A       Stick
434 Mouse 0         5       A       Center
435 # Right buttonsare iconify/maximize, rightmost is close
436 Mouse 0         2       A       Close
437 Mouse 0         4       A       Maximize toggle
438 Mouse 0         6       A       Iconify
439
440 # Button 1 in Frame or Sides is a resize-or-raise, in Icons is a move or
441 # de-iconify, and on Top does a move-or-raise
442 #     Button    Context Modifi  Function
443 Mouse 1         F       A       Resize-or-Raise
444 Mouse 1         S       A       Move-or-Raise
445 Mouse 1         I       A       Move-or-Iconify
446 #Mouse 1                T       A       Move-or-Raise
447 Mouse 1         T       A       Shadify
448
449 # Button 2 in an Icon is de-iconify, in Corners/Sides/Titlebar gets Ops Menu
450 #     Button    Context Modifi  Function
451 Mouse 2         I       A       Iconify
452 Mouse 2         FST     A       Menu Window-Ops2 Nop
453
454 # Button 3 does a raise-lower on anything
455 Mouse 3         TSIF    A       RaiseLower
456
457 ############################################################################
458 # KEYBOARD Setup
459
460 #
461 # press arrow + control + meta anywhere, and scroll by 1 page
462 Key Left        A       CM      Scroll -100 +0
463 Key Right       A       CM      Scroll +100 +0
464 Key Up          A       CM      Scroll +0   -100
465 Key Down        A       CM      Scroll +0   +100
466
467 # press arrow + meta key, and scroll by 1/10 of a page
468 Key Left        A       M       Scroll -10   +0
469 Key Right       A       M       Scroll +10   +0
470 Key Up          A       M       Scroll  +0  -10
471 Key Down        A       M       Scroll  +0  +10
472
473 # press shift arrow + control anywhere, and move the pointer by 1% of a page
474 Key Left        A       SC      CursorMove -1  +0
475 Key Right       A       SC      CursorMove +1  +0
476 Key Up          A       SC      CursorMove +0  -1
477 Key Down        A       SC      CursorMove +0  +1
478
479 # press shift arrow + meta key, and move the pointer by 1/10 of a page
480 Key Left        A       SM      CursorMove -10  +0
481 Key Right       A       SM      CursorMove +10  +0
482 Key Up          A       SM      CursorMove +0  -10
483 Key Down        A       SM      CursorMove +0  +10
484
485 # Switch window, mswindows style :)
486 Key Tab         A       M       Next [*] focus
487 Key Escape      A       M       Prev [*] focus
488
489 # Goto desktop/page
490 Key 1           A       CM      Desk 0 0
491 Key 2           A       CM      Desk 0 1
492 Key 3           A       CM      Desk 0 2
493 Key 4           A       CM      Desk 0 3
494 Key 5           A       CM      GotoPage 0 0
495 Key 6           A       CM      GotoPage 1 0
496 Key 7           A       CM      GotoPage 0 1
497 Key 8           A       CM      GotoPage 1 1
498
499 #############################################################################
500 # START-UP Functions
501 #
502 DestroyFunc InitFunction
503 AddToFunc InitFunction
504 +              I Module FvwmBacker
505 +              I Module FvwmButtons
506 +              I Module FvwmCommandS
507 +              I Module FvwmPager 0 2
508
509 DestroyFunc RestartFunction
510 AddToFunc RestartFunction
511 +              I Module FvwmBacker
512 +              I Module FvwmButtons
513 +              I Module FvwmCommandS
514 +              I Module FvwmPager 0 2
515 +              I Schedule 1000 Raise-All
516
517 DestroyFunc UrgencyFunc
518 AddToFunc UrgencyFunc
519 +                             I Iconify off
520 +                             I ThisWindow ("*Downloads|Skype") Break
521 +                             I FlipFocus
522 +                             I Raise
523 +                             I WarpToWindow 5p 5p
524
525 DestroyFunc StartStandardSession
526 AddToFunc StartStandardSession
527 +              I GotoDeskAndPage 0 0 0
528 +              I TERM_KOI8
529 +              I Wait TERM
530 +              I Exec exec cgmem_nice 200 pulseaudio --start
531 +              I PaVuControl
532 +              I Exec exec "$HOME"/current/projects/audio-cdr-video/audio/pa-mic-off
533 +              I XsetbgFilename
534 +              I Wait gxmessage
535 +              I GotoDeskAndPage 2 0 1
536 +              I TERM_KOI8_BIG
537 +              I Wait TERM
538 +              I FireFox
539 +              I GotoDeskAndPage 0 1 1
540
541 DestroyFunc ResumeFunction
542 AddToFunc ResumeFunction
543 +              I GotoDeskAndPage 0 0 0
544 +              I TERM_KOI8
545 +              I Wait TERM
546 +              I Exec exec cgmem_nice 200 pulseaudio --start
547 +              I None ("Volume Control") PaVuControl
548 +              I Exec sleep 10; exec "$HOME"/current/projects/audio-cdr-video/audio/pa-mic-off
549 +              I XsetbgFilename
550 +              I Wait gxmessage
551 +              I Any ("*Mozilla Firefox") GotoDeskAndPage 0 1 1
552 +              I TestRc (Match) Break
553 +              I None ("*Mozilla Firefox") FireFox
554
555 ############################################################################
556 # COMPLEX FUNCTIONS
557 #
558 DestroyFunc Center
559 AddToFunc Center                I Move 50-50w 50-50w
560 +                               I WarpToWindow 74p 18p
561
562 DestroyFunc Iconify-and-Raise
563 AddToFunc Iconify-and-Raise     I Iconify
564 +                               I Raise
565
566 DestroyFunc Maximize-Func
567 AddToFunc Maximize-Func         C Maximize     toggle
568 +                               D Maximize     100 100
569
570 DestroyFunc Move-or-Iconify
571 AddToFunc Move-or-Iconify       I Raise
572 +                               M Move
573 +                               D Iconify
574
575 DestroyFunc Move-or-Raise
576 AddToFunc Move-or-Raise         I Raise
577 +                               M Move
578 +                               D Lower
579
580 DestroyFunc Move-or-Raise2
581 AddToFunc Move-or-Raise2        M Raise
582 +                               M Move
583 +                               D Lower
584
585 DestroyFunc Resize-or-Raise
586 AddToFunc Resize-or-Raise       I Raise
587 +                               M Resize
588 +                               D Lower
589
590 DestroyFunc Resize-or-Raise2
591 AddToFunc Resize-or-Raise2      M Raise
592 +                               M Resize
593 +                               D Lower
594
595 DestroyFunc Shadify
596 AddToFunc Shadify               D WindowShade
597 +                               M Move
598 +                               C RaiseLower
599
600 DestroyFunc warp-or-run
601 AddToFunc warp-or-run           I Next [$0 CirculateHit] Iconify -1
602 +                               I Next [$0 CirculateHit] Focus
603 +                               I None [$0] $1
604
605 DestroyFunc MailFunction
606 AddToFunc MailFunction          I Next [$0] Iconify -1
607 +                               I Next [$0] focus
608 +                               I None [$0] Exec exec $0 $1
609
610 DestroyFunc PrintFunction
611 AddToFunc PrintFunction         I Raise
612 +                               I Exec exec xdpr -id $w
613
614 DestroyFunc Raise-All
615 AddToFunc Raise-All           I All Raise
616
617 ##############################################################################
618 # User-defined functions
619 #
620
621 DestroyFunc PaVuControl
622 AddToFunc PaVuControl         I GotoDeskAndPage 0 1 1
623 +                             I Exec exec pulseaudio --kill
624 +                             I Exec exec cgmem_nice 200 pulseaudio --start
625 +                             I Exec exec cgmem_nice 200 pavucontrol
626 +                             I Wait "Volume Control"
627
628 changequote([,])dnl
629 DestroyFunc Id3Info
630 AddToFunc Id3Info             I Exec "$HOME"/lib/audio/mp3/id3info.py "`audtool --current-song-filename`" | text-wrap.py | gxmessage -buttons Ok -default Ok -fn 'MESSAGE_FONT' -file -
631 changequote([`], ['])dnl
632
633 DestroyFunc Term3Hosts
634 AddToFunc Term3Hosts          I GotoDeskAndPage 1 1 2
635 +                             I TERM_KOI8_SSH_SCREEN(iskra-aviel.phdru.name, iskra)
636 +                             I Wait TERM
637 +                             I TERM_KOI8_BOTRT_SSH_SCREEN(oper.med.ru, oper)
638 +                             I Wait TERM
639 +                             I GotoDeskAndPage 1 0 1
640 +                             I TERM_KOI8_SSH_SCREEN(-D 1080 phdru.name, phdru.name)
641 +                             I Wait TERM
642 +                             I GotoDeskAndPage 1 1 2
643
644 DestroyFunc FireFox
645 AddToFunc FireFox             I Any ("*Mozilla Firefox") Break
646 +                             I GotoDeskAndPage 1 0 0
647 +                             I Exec LC_CTYPE=ru_RU.KOI8-R exec cgmem_nice 4000 start-browser firefox -P phd
648 +                             I Wait "*Mozilla Firefox"
649 +                             I Exec LC_CTYPE=ru_RU.KOI8-R exec cgmem_nice 4000 firefox --new-window
650 +                             I Wait "*Mozilla Firefox"
651 +                             I Next ("*Mozilla Firefox") Iconify true
652
653 DestroyFunc Gajim
654 AddToFunc Gajim               I GotoDeskAndPage 1 1 0
655 +                             I Exec exec cgmem_nice 300 gajim
656
657 DestroyFunc Pidgin
658 AddToFunc Pidgin              I GotoDeskAndPage 1 1 0
659 +                             I Exec exec cgmem_nice 300 pidgin
660
661 DestroyFunc Skype
662 AddToFunc Skype               I GotoDeskAndPage 0 0 1
663 +                             I Exec BROWSER=firefox exec cgmem_nice 2000 skypeforlinux
664
665 DestroyFunc XFilename
666 AddToFunc XSetbgFilename      I Exec "$HOME"/current/projects/xsetbg/print-filename.py | text-wrap.py -w TEXT_WIDTH -s | gxmessage -buttons Ok -default Ok -fn 'MESSAGE_FONT' -file -
667
668 ##############################################################################
669 # MENU Setup
670 #
671
672 # This defines the most common window operations
673 AddToMenu Window-Ops    "Window Ops"    Title
674 +                       "Center"        Center
675 +                       "Move"          Move-or-Raise2
676 +                       "Resize"        Resize-or-Raise2
677 +                       "Raise"         Raise
678 +                       "Lower"         Lower
679 +                       "(De)Iconify"   Iconify
680 +                       "(Un)Stick"     Stick
681 +                       "(Un)Maximize"  maximize_func
682 +                       ""              Nop
683 +                       "Delete"        Delete
684 +                       "Close"         Close
685 +                       "Destroy"       Destroy
686 +                       ""              Nop
687 +                       "Refresh Screen" Refresh
688
689 # A trimmed down version of "Window Ops", good for binding to decorations
690 DestroyMenu Window-Ops2
691 AddToMenu Window-Ops2   "Center"        Center
692 +                       "Move"          Move-or-Raise
693 +                       "Iconify"       Iconify
694 +                       "(Un)Stick"     Stick
695 +                       "Refresh"       RefreshWindow
696 +                       ""              Nop
697 +                       "Close"         Close
698 +                       "Delete"        Delete
699 +                       "Destroy"       Destroy
700 +                       ""              Nop
701 +                       "Resize"        Resize-or-Raise
702 +                       "Shade"         WindowShade
703 +                       "Raise/Lower"   RaiseLower
704 +                       ""              Nop
705 +                       "ScrollBar"     Module FvwmScroll 2 2
706 +                       "Print"         PrintFunction
707
708 AddToMenu Terminals     "Terminals" Title
709 +               "Grey term (koi8)" TERM_KOI8
710 +               "Grey term (utf8)" TERM_RU_UTF8
711 +               "Grey term (heb-utf8)" TERM_HEB_UTF8
712 +               "Grey term (btlt,koi8)" TERM_KOI8_BOTLT
713 +               "Grey term (btrt,koi8)" TERM_KOI8_BOTRT
714 +               "Grey term (btlt,utf8)" TERM_RU_UTF8_BOTLT
715 +               "Grey term (btrt,utf8)" TERM_RU_UTF8_BOTRT
716 +               "Big grey term (koi8)" TERM_KOI8_BIG
717 +               "Big grey term (utf8)" TERM_UTF8_BIG
718 +                       ""      Nop
719 +               "White/black term (koi8)" TERM_KOI8 -fg white -cr white -bg black
720 +               "White/black term (utf8)" TERM_RU_UTF8 -fg white -bg black
721
722 AddToMenu TermColors    "Term Colors" Title
723 +                       "Term: black/mediumturquoise" TERM_KOI8 -fg black -cr black -bg mediumturquoise
724 +                       "Term: black/lightseagreen" TERM_KOI8 -fg black -cr black -bg lightseagreen
725 +                       ""      Nop
726 +                       "Term: black/lightsteelblue" TERM_KOI8 -fg black -cr black -bg lightsteelblue
727 +                       "Term: black/lightblue3" TERM_KOI8 -fg black -cr black -bg lightblue3
728 +                       ""      Nop
729 +                       "Term: black/lightgoldenrod" TERM_KOI8 -fg black -cr black -bg lightgoldenrod
730 +                       "Term: black/rosybrown1" TERM_KOI8 -fg black -cr black -bg rosybrown1
731 +                       "Term: black/pink1" TERM_KOI8 -fg black -cr black -bg pink1
732 +                       ""      Nop
733 +                       "Term: white/orchid4" TERM_KOI8 -fg white -cr white -bg orchid4
734 +                       "Term: white/purple3" TERM_KOI8 -fg white -cr white -bg purple3
735 +                       "Term: white/purple4" TERM_KOI8 -fg white -cr white -bg purple4
736 +                       ""      Nop
737 +                       "Term: white/lightslategrey" TERM_KOI8 -fg white -cr white -bg lightslategrey
738 +                       "Term: white/navyblue" TERM_KOI8 -fg white -cr white -bg navyblue
739 +                       "Term: white/mediumblue" TERM_KOI8 -fg white -cr white -bg mediumblue
740 +                       "Term: white/steelblue" TERM_KOI8 -fg white -cr white -bg steelblue
741 +                       ""      Nop
742 +                       "Term: white/forestgreen" TERM_KOI8 -fg white -cr white -bg forestgreen
743 +                       "Term: white/rosybrown" TERM_KOI8 -fg white -cr white -bg rosybrown
744 +                       "Term: white/deeppink" TERM_KOI8 -fg white -cr white -bg deeppink
745 +                       "Term: white/black" TERM_KOI8 -fg white -cr white -bg black
746
747 AddToMenu Systems       "Systems" Title
748 +                       "Iskra+Oper+Phdru" Term3Hosts
749 +                       ""        Nop
750 pushdef(`TERM_KOI8', `Exec LC_CTYPE=ru_RU.KOI8-R exec TERM -xrm "*Page: 1 1 1"')dnl
751 pushdef(`TERM_RU_UTF8', `Exec LC_CTYPE=ru_RU.UTF-8 exec TERM -name URxvt -xrm "*Page: 1 1 1"')dnl
752 +                       MENU_TERM_KOI8_SSH_SCREEN(iskra-aviel.phdru.name, iskra)
753 +                       MENU_TERM_UTF8_BOTLT_SSH(iskra-aviel.phdru.name, iskra)
754 +                       MENU_TERM_KOI8_BIG_SSH(iskra-aviel.phdru.name, ISKRA)
755 +                       ""        Nop
756 +                       MENU_TERM_KOI8_BOTRT_SSH_SCREEN(oper.med.ru, oper)
757 +                       MENU_TERM_UTF8_BOTRT_SSH(oper.med.ru, oper)
758 +                       MENU_TERM_KOI8_BIG_SSH(oper.med.ru, OPER)
759 popdef(`TERM_KOI8', `TERM_RU_UTF8')dnl
760 +                       ""        Nop
761 pushdef(`TERM_KOI8', `Exec LC_CTYPE=ru_RU.KOI8-R exec TERM -xrm "*Page: 1 0 1"')dnl
762 pushdef(`TERM_RU_UTF8', `Exec LC_CTYPE=ru_RU.UTF-8 exec TERM -name URxvt -xrm "*Page: 1 0 1"')dnl
763 +                       MENU_TERM_KOI8_SSH_SCREEN(phdru.name, phdru)
764 +                       MENU_TERM_KOI8_SSH_SCREEN(-D 1080 phdru.name, phdru SOCKS5)
765 +                       MENU_TERM_UTF8_BOTLT_SSH(phdru.name, phdru)
766 +                       MENU_TERM_KOI8_BIG_SSH(phdru.name, PHDRU)
767 popdef(`TERM_KOI8', `TERM_RU_UTF8')dnl
768
769 AddToMenu FvwmCommands  "Fvwm Commands" Title
770 +                       "Restart" Restart
771 +                       "Raise all" Raise-All
772 #+                       "Restart Fvwm2" Restart fvwm2
773 #+                       "Start Fvwm"    Restart fvwm
774 +                       "Fvwm Setup"    Popup FvwmSetup
775 +                       "Fvwm Modules"  Popup FvwmModules
776 +                       "" Nop
777 +                       "Exit Fvwm"     Quit
778
779 AddToMenu FvwmSetup     "Fvwm Setup" Title
780 +                       "Start standard session" StartStandardSession
781 +                       "Change Scrolling"      Popup FvwmScroll
782
783 AddToMenu FvwmScroll    "Change Scroll Behavior" Title
784 +                       "OFF"   EdgeScroll 0 0
785 +                       "ON"    EdgeScroll 100 100
786 +                       "Horizontal Only"       EdgeScroll 100 0
787 +                       "Vertical Only"         EdgeScroll 0 100
788 +                       "Partial"               EdgeScroll 50 50
789
790 AddToMenu FvwmModules   "Fvwm Modules" Title
791 +                       "Animate"      Module FvwmAnimate
792 +                       "Auto"         Module FvwmAuto
793 +                       "Backer"       Module FvwmBacker
794 +                       "Banner"       Module FvwmBanner
795 +                       "Buttons"      Module FvwmButtons
796 +                       "Cascade"      Module FvwmCascade
797 +                       "CommandS"     Module FvwmCommandS
798 +                       "Console"      Module FvwmConsole
799 +                       "ConsoleC"     Module FvwmConsoleC -e FvwmConsoleC.pl
800 +                       "Cpp"          Module FvwmCpp
801 +                       "Debug"        Module FvwmDebug
802 +                       "DragWell"     Module FvwmDragWell
803 +                       "Event"        Module FvwmEvent
804 +                       "Form"         Module FvwmForm
805 +                       "Gtk"          Module FvwmGtk
806 +                       "IconBox"      Module FvwmIconBox
807 +                       "IconMan"      Module FvwmIconMan
808 +                       "Ident"        Module FvwmIdent
809 +                       "M4"           Module FvwmM4
810 +                       "Pager"        Module FvwmPager 0 2
811 +                       "Rearrange"    Module FvwmRearrange
812 +                       "Save"         Module FvwmSave
813 +                       "SaveDesk"     Module FvwmSaveDesk
814 +                       "Script"       Module FvwmScript
815 +                       "Scroll"       Module FvwmScroll
816 +                       "TaskBar"      Module FvwmTaskBar
817 +                       "Theme"        Module FvwmTheme
818 +                       "Tile"         Module FvwmTile
819 +                       "Wharf"        Module FvwmWharf
820 +                       "WinList"      Module FvwmWinList
821
822 # This is the root menu
823 AddToMenu RootMenu "Root Menu"  Title
824 +               "Terminals"     Popup Terminals
825 #+               "Color term"    Popup TermColors
826 +               "Systems"       Popup Systems
827 +               ""              Nop
828 +               "Browsers"      Popup Browsers
829 +               "Utilities"     Popup Utilities
830 #+               ""              Nop
831 #+               "Lock Screen"   Popup XlockMenu
832 +               "XScreenSaver"  Popup XScreenSaverMenu
833 #+               "Tv-tuner"      Popup Tv-tuner
834 +               ""              Nop
835 +               "XSetBg"        Popup XSetBgMenu
836 +               "Fvwm Commands" Popup FvwmCommands
837
838 DestroyMenu OSMenu
839 AddToMenu OSMenu        "OS commands:" Title
840 +                       "Suspend to both" Exec exec s2b
841 +                       "Suspend to disk" Exec exec s2d
842 +                       "Suspend to ram"  Exec exec s2r
843
844 # This menu will fire up some often used programs
845 DestroyMenu Utilities
846 AddToMenu Utilities     "Choose one:" Title
847 +                       "OS"     Popup OSMenu
848 +                       ""       Nop
849 +                       "GVim (koi8)" Exec LC_CTYPE=ru_RU.KOI8-R exec gvim
850 +                       "GVim (utf8)" Exec LC_CTYPE=ru_RU.UTF-8  exec gvim
851 +                       ""       Nop
852 +                       "Refresh Screen" Refresh
853 +                       "xrefresh" Exec exec xrefresh
854 +                       ""       Nop
855 +                       "Skype" Skype
856 +                       "pavucontrol" PaVuControl
857
858 DestroyMenu  Browsers
859 AddToMenu Browsers      "Choose one:" Title
860 +                       "FireFox" FireFox
861 +                       "Chromium" None ("*Chromium") Exec LC_CTYPE=ru_RU.KOI8-R exec cgmem_nice 2000 start-browser chromium
862 +                       "Opera" None ("*Opera") Exec LC_CTYPE=ru_RU.KOI8-R exec cgmem_nice 2000 start-browser opera
863
864 # A wide variety of screenlocking options...
865 #AddToMenu XlockMenu     "Choose one:" Title
866 #+                       "Hop" Exec exec xlock -mode hop
867 #+                       "Image" Exec exec xlock -mode image
868 #+                       "Life" Exec exec xlock -mode life
869 #+                       "Flame" Exec exec xlock -mode flame
870 #+                       "Pyro" Exec exec xlock -mode pyro
871 #+                       "Qix" Exec exec xlock -mode qix
872 #+                       "Rotor" Exec exec xlock -mode rotor
873 #+                       "Swarm" Exec exec xlock -mode swarm
874 #+                       "" Nop
875 #+                       "Random" Exec exec xlock -mode random
876 #+                       "Blank" Exec exec xlock -mode blank
877
878 AddToMenu XScreenSaverMenu     "Choose mode:" Title
879 +                       "Blank Screen Now" Exec exec xscreensaver-command -activate
880 +                       "Lock Screen Now"  Exec exec xscreensaver-command -lock
881 +                       "Screen Saver Demo" Exec exec xscreensaver-command -demo
882 +                       "Screen Saver Preferences"  Exec exec xscreensaver-command -prefs
883 +                       "Reinitialize Screen Saver" Exec exec xscreensaver-command -restart
884 +                       "" Nop
885 +                       "Kill Screen Saver"         Exec exec xscreensaver-command -exit
886 +                       "Launch Screen Saver"       Exec exec xscreensaver
887
888 AddToMenu XSetBgMenu    "XSetBg" Title
889 +                       "Change wallpaper" Exec exec "$HOME"/current/projects/xsetbg/xsetbg-force
890 +                       "Start" Exec exec cgmem_nice 100 "$HOME"/current/projects/xsetbg/xsetbg-http-start
891 +                       "Stop" Exec exec "$HOME"/current/projects/xsetbg/xsetbg-http-stop
892 +                       "Restart" Exec exec "$HOME"/current/projects/xsetbg/xsetbg-http-restart
893 +                       ""       Nop
894 changequote([,])
895 +                       "Xli" Exec fn="`$HOME/current/projects/xsetbg/print-filename.py -e koi8-r`" && exec xli -title "`echo $fn | sed 's/ /_/g'`" "$fn"
896 +                       "Xli (scaled)" Exec fn="`$HOME/current/projects/xsetbg/print-filename.py -e koi8-r`" && exec xli -title "`echo $fn | sed 's/ /_/g'`" -zoom auto "$fn"
897 +                       "Open in browser" Exec exec webbrowserX -n "`$HOME/current/projects/xsetbg/print-filename.py -e koi8-r`"
898 +                       "Filename" Exec exec "$HOME"/current/projects/xsetbg/print-filename.py -e koi8-r
899 +                       "XFilename" Exec "$HOME"/current/projects/xsetbg/print-filename.py | text-wrap.py | gxmessage -buttons Ok -default Ok -fn 'MESSAGE_FONT' -file -
900 +                       "XFilename (wrapped)" XSetbgFilename
901 +                       ""       Nop
902 +                       "Xli (prev.)" Exec fn="`$HOME/current/projects/xsetbg/print-filename.py -e koi8-r 1`" && exec xli -title "`echo $fn | sed 's/ /_/g'`" "$fn"
903 +                       "Xli (prev., scaled)" Exec fn="`$HOME/current/projects/xsetbg/print-filename.py -e koi8-r 1`" && exec xli -title "`echo $fn | sed 's/ /_/g'`" -zoom auto "$fn"
904 +                       "Open in browser (prev.)" Exec exec webbrowserX -n "`$HOME/current/projects/xsetbg/print-filename.py -e koi8-r 1`"
905 changequote([`], ['])
906 +                       "Filename (prev.)" Exec exec "$HOME"/current/projects/xsetbg/print-filename.py -e koi8-r 1
907 +                       "XFilename (prev.)" Exec "$HOME"/current/projects/xsetbg/print-filename.py 1 | text-wrap.py | gxmessage -buttons Ok -default Ok -fn 'MESSAGE_FONT' -file -
908 +                       "XFilename (prev., wrapped)" Exec "$HOME"/current/projects/xsetbg/print-filename.py 1 | text-wrap.py -w TEXT_WIDTH -s | gxmessage -buttons Ok -default Ok -fn 'MESSAGE_FONT' -file -
909
910 ############################################################################
911 # FvwmBacker
912 #
913 #*FvwmBacker: Command (Desk 0, Page * *) -solid DarkCyan
914 #*FvwmBacker: Command (Desk 1, Page * *) -solid steelblue
915 #*FvwmBacker: Command (Desk 2, Page * *) -solid midnightblue
916 *FvwmBacker: Command (Desk *, Page * *) Exec exec "$HOME"/current/projects/xsetbg/xsetbg-http-change
917
918 ############################################################################
919 # FvwmButtons
920 #
921 # Colors
922 *FvwmButtons: Fore Black
923 *FvwmButtons: Back rgb:90/80/90
924
925 # Font
926 *FvwmButtons: Font BUTTONS_FONT
927
928 # Geometry-- really likes to pick its own size, but giving a position is OK
929 *FvwmButtons: Geometry -1+1
930
931 # Layout: specify rows or columns, not both
932 *FvwmButtons: Rows 2 #, Columns 5
933
934 # Transparent background
935 #*FvwmButtons: Pixmap none
936 # Background
937 #*FvwmButtons: Pixmap fvwm.xpm
938
939 # Define the buttons to use.....
940 #*FvwmButtons: Move              arrows2.xpm     Move
941 #*FvwmButtons: Kill              skull.xpm       Destroy
942 #*FvwmButtons: Quit              nuke.xpm        Popup "Quit-Verify"
943
944 #*FvwmButtons: (Swallow XClock 'Exec exec xclock -update 1 -geometry -3000-3000')
945
946 # Buttons
947 pushdef(`TERM_KOI8', `Exec "TERM" LC_CTYPE=ru_RU.KOI8-R exec TERM')dnl
948 pushdef(`TERM_RU_UTF8', `Exec "URxvt" LC_CTYPE=ru_RU.UTF-8 exec TERM -name URxvt')dnl
949 *FvwmButtons: (Title Term,     Icon rterm2.xpm,      Action TERM_KOI8)
950 *FvwmButtons: (Title UTF-8,    Icon rterm2.xpm,      Action TERM_RU_UTF8)
951 popdef(`TERM_KOI8', `TERM_RU_UTF8')dnl
952 pushdef(`TERM_KOI8', `Exec "TERM" LC_CTYPE=ru_RU.KOI8-R exec TERM -xrm "*Page: 1 0 1"')dnl
953 *FvwmButtons: (Title "phdru (k8,s)",    Icon xterm-sgi.xpm,   Action TERM_KOI8_SSH_SCREEN(phdru.name, phdru.name))
954 popdef(`TERM_KOI8')dnl
955 pushdef(`TERM_KOI8', `Exec "TERM" LC_CTYPE=ru_RU.KOI8-R exec TERM -xrm "*Page: 1 1 1"')dnl
956 *FvwmButtons: (Title "iskra (k8,s)",    Icon xterm-sgi.xpm,   Action TERM_KOI8_SSH_SCREEN(iskra-aviel.phdru.name, iskra))
957 *FvwmButtons: (Title "oper (k8,s)",     Icon xterm-linux.xpm, Action TERM_KOI8_BOTRT_SSH_SCREEN(oper.med.ru, oper))
958 popdef(`TERM_KOI8')dnl
959
960 *FvwmButtons: (Title Wallpaper, Icon find1.xpm,        Action Exec "gxmessage" "$HOME"/current/projects/xsetbg/print-filename.py | text-wrap.py -w TEXT_WIDTH -s | gxmessage -buttons Ok -default Ok -fn 'MESSAGE_FONT' -file -)
961 *FvwmButtons: (Title "-1",      Icon find1.xpm,        Action Exec "gxmessage" "$HOME"/current/projects/xsetbg/print-filename.py 1 | text-wrap.py -w TEXT_WIDTH -s | gxmessage -buttons Ok -default Ok -fn 'MESSAGE_FONT' -file -)
962 *FvwmButtons: (Title Next,      Icon Jrecycle.xpm,     Action Exec exec "$HOME"/current/projects/xsetbg/xsetbg-http-force)
963 #*FvwmButtons: (Title pavucontrol, Icon mini.sound.xpm, Action Exec "Volume Control" exec cgmem_nice 200 pavucontrol)
964 #*FvwmButtons: (Title Id3Info,  Icon bell.xpm,         Action Id3Info)
965 *FvwmButtons: (Title Skype,    Icon skypeforlinux.png, Action Exec "Skype" FvwmCommand "GotoDeskAndPage 0 0 1" && BROWSER=firefox exec cgmem_nice 2000 skypeforlinux)
966 *FvwmButtons: (Title AudioPlayer,  Icon bell.xpm,      Action Exec "deadbeef" LC_CTYPE=ru_RU.KOI8-R FvwmCommand "GotoDeskAndPage 0 1 1" && exec cgmem_nice 400 deadbeef)
967 #*FvwmButtons: (Title XLock,     Icon Jxlock.xpm,      Action Exec exec xscreensaver-command -lock)
968
969 ############################################################################
970 # FvwmForm
971 #
972 # FvwmForm alias - rlogin to host via term
973 #FvwmForm Rlogin
974 #*Rlogin: WarpPointer
975 #*Rlogin: Font         *helvetica*m*r*n*14*
976 #*Rlogin: ButtonFont   *helvetica*m*o*n*14*
977 #*Rlogin: InputFont    *cour*m*r*n*14*
978 #*Rlogin: Fore         Black
979 #*Rlogin: Back         Light Gray
980 #*Rlogin: ItemFore          Wheat
981 #*Rlogin: ItemBack          Gray50
982 ## begin items
983 #*Rlogin: Line         center
984 #*Rlogin: Text         "Login to Remote Host"
985 #*Rlogin: Line         center
986 #*Rlogin: Text         "Host:"
987 #*Rlogin: Input        HostName  20   ""
988 #*Rlogin: Line         center
989 #*Rlogin: Selection    UserSel   single
990 #*Rlogin: Choice       Default   Default   on   "same user"
991 #*Rlogin: Choice       Custom    Custom    off  "user:"
992 #*Rlogin: Input        UserName  10   ""
993 #*Rlogin: Line         expand
994 #*Rlogin: Button       quit "Login" ^M
995 `#'*Rlogin: Command      TERM_KOI8 -T term@$(HostName) -e rlogin $(HostName) $(Custom?-l $(UserName))
996 #*Rlogin: Button       restart   "Clear"
997 #*Rlogin: Command Beep
998 #*Rlogin: Button       quit "Cancel"
999 #*Rlogin: Command Nop
1000 ##
1001 ## FvwmForm alias - query exit ala mwm
1002 #FvwmForm QuitVerify
1003 #*QuitVerify: GrabServer
1004 #*QuitVerify: WarpPointer
1005 #*QuitVerify: Font          *helvetica*m*r*n*14*
1006 ##*QuitVerify: ButtonFont    *helvetica*m*o*n*14*
1007 #*QuitVerify: ButtonFont    7x13bold
1008 #*QuitVerify: Fore          Black
1009 #*QuitVerify: Back          Light Gray
1010 #*QuitVerify: ItemFore Wheat
1011 #*QuitVerify: ItemBack Gray50
1012 ## begin items
1013 #*QuitVerify: Line          center
1014 #*QuitVerify: Text          "Do you really want to exit FVWM?"
1015 #*QuitVerify: Line          expand
1016 #*QuitVerify: Button   quit      " Exit "
1017 #*QuitVerify: Command  Quit
1018 #*QuitVerify: Button   quit      "Cancel"
1019 #*QuitVerify: Command  Nop
1020 #
1021 ##
1022 ## MyTalk & MyFvwmTalk from Dave Goldberg
1023 ## MyTalk Form - dissappears after use
1024 #FvwmForm MyTalk
1025 #*MyTalk: WarpPointer
1026 #*MyTalk: Font *helvetica*m*r*n*14*
1027 #*MyTalk: ButtonFont *helvetica*m*o*n*14*
1028 #*MyTalk: InputFont *cour*m*r*n*14*
1029 #*MyTalk: Fore Red
1030 #*MyTalk: Back Gray
1031 #*MyTalk: ItemFore Blue
1032 #*MyTalk: ItemBack Gray
1033 #*MyTalk: Line center
1034 #*MyTalk: Text "Fvwm Function"
1035 #*MyTalk: Input Func 40 ""
1036 #*MyTalk: Line expand
1037 #*MyTalk: Button quit "Run" ^M
1038 #*MyTalk: Command $(Func)
1039 #*MyTalk: Button restart "Clear" ^R
1040 #*MyTalk: Button quit "Cancel" ^C
1041 #*MyTalk: Command Nop
1042 ##
1043 ## MyFvwmTalk Form - sticks around
1044 #FvwmForm MyFvwmTalk
1045 #*MyFvwmTalk: WarpPointer
1046 #*MyFvwmTalk: Font *helvetica*m*r*n*14*
1047 #*MyFvwmTalk: ButtonFont *helvetica*m*o*n*14*
1048 #*MyFvwmTalk: InputFont *cour*m*r*n*14*
1049 #*MyFvwmTalk: Fore Red
1050 #*MyFvwmTalk: Back Gray
1051 #*MyFvwmTalk: ItemFore Blue
1052 #*MyFvwmTalk: ItemBack Gray
1053 #*MyFvwmTalk: Line center
1054 #*MyFvwmTalk: Text "Fvwm Function"
1055 #*MyFvwmTalk: Input Func 40 ""
1056 #*MyFvwmTalk: Line expand
1057 #*MyFvwmTalk: Button restart "Run" ^M
1058 #*MyFvwmTalk: Command $(Func)
1059 #*MyFvwmTalk: Button restart "Clear" ^R
1060 #*MyFvwmTalk: Command Nop
1061 #*MyFvwmTalk: Button restart "Iconify" ^Z
1062 #*MyFvwmTalk: Command Next [MyFvwmTalk] Iconify
1063 #*MyFvwmTalk: Button quit "Quit" ^C
1064 #*MyFvwmTalk: Command Nop
1065
1066 ############################################################################
1067 # FvwmIconBox
1068 #
1069 # NOTE: Icons will only be shown in module if "Style * !Icon" is set
1070 *FvwmIconBox: IconBack    #cfcfcf
1071 *FvwmIconBox: IconHiFore  black
1072 *FvwmIconBox: IconHiBack  LightSkyBlue
1073 *FvwmIconBox: Back        #5f9ea0
1074 #*FvwmIconBox: Fore       blue
1075 *FvwmIconBox: Geometry    5x1+0+0
1076 *FvwmIconBox: MaxIconSize 64x38
1077 *FvwmIconBox: Font        ICON_BOX_FONT
1078 *FvwmIconBox: SortIcons   IconName
1079 *FvwmIconBox: Padding     4
1080 *FvwmIconBox: Lines       10
1081 *FvwmIconBox: SBWidth     11
1082 *FvwmIconBox: Placement   Left Top
1083 *FvwmIconBox: Pixmap      fvwm.xpm
1084 #*FvwmIconBox: HideSC Horizontal
1085 *FvwmIconBox: SetWMIconSize
1086 *FvwmIconBox: HilightFocusWin
1087 #*FvwmIconBox: Resolution          Desk
1088 *FvwmIconBox: Mouse       1       Click           RaiseLower
1089 *FvwmIconBox: Mouse       1       DoubleClick     Iconify
1090 *FvwmIconBox: Mouse       2       Click           Iconify -1, Focus
1091 *FvwmIconBox: Mouse       3       Click           Module FvwmIdent
1092 *FvwmIconBox: Key         r       RaiseLower
1093 *FvwmIconBox: Key         space   Iconify
1094 *FvwmIconBox: Key         d       Close
1095 *FvwmIconBox: Key         n       Next
1096 *FvwmIconBox: Key         p       Prev
1097 *FvwmIconBox: Key         h       Left
1098 *FvwmIconBox: Key         j       Down
1099 *FvwmIconBox: Key         k       Up
1100 *FvwmIconBox: Key         l       Right
1101
1102 ############################################################################
1103 # FvwmIdent
1104 #
1105 # Give us colors and a fonts
1106 *FvwmIdent: Back MidnightBlue
1107 *FvwmIdent: Fore Yellow
1108 *FvwmIdent: Font IDENT_FONT
1109
1110 ############################################################################
1111 # FvwmPager
1112 #
1113 *FvwmPager: Back #908090
1114 *FvwmPager: Fore #484048
1115 *FvwmPager: Font TITLE_FONT
1116 *FvwmPager: Hilight #cab3ca
1117 *FvwmPager: Geometry PAGER_GEOM
1118 *FvwmPager: Label 0 System
1119 *FvwmPager: Label 1 Net
1120 *FvwmPager: Label 2 Work
1121 *FvwmPager: SmallFont SMALL_PAGER_FONT
1122
1123 *FvwmPager: Balloons All
1124 *FvwmPager: BalloonBack #efe3b5
1125 *FvwmPager: BalloonFore Black
1126 *FvwmPager: BalloonFont ICON_FONT
1127 *FvwmPager: BalloonYOffset +2
1128 *FvwmPager: BalloonBorderWidth 1
1129 *FvwmPager: BalloonBorderColor Black
1130
1131 ############################################################################
1132 # FvwmScroll
1133 #
1134 *FvwmScroll: Back grey40
1135 *FvwmScroll: Fore green
1136
1137 ############################################################################
1138 # FvwmWinList
1139 #
1140 *FvwmWinList: Back #908090
1141 *FvwmWinList: Fore Black
1142 *FvwmWinList: Font WIN_LIST_FONT
1143 *FvwmWinList: Action Click1 Iconify -1, Focus
1144 *FvwmWinList: Action Click2 Iconify
1145 *FvwmWinList: Action Click3 Module "FvwmIdent: " FvwmIdent
1146 *FvwmWinList: UseSkipList
1147 *FvwmWinList: Geometry +10-10