File: Preferences-Menu

package info (click to toggle)
fvwm-crystal 3.0.5.dfsg-5
  • links: PTS, VCS
  • area: main
  • in suites: squeeze, wheezy
  • size: 16,268 kB
  • ctags: 607
  • sloc: sh: 2,065; python: 875; cs: 648; makefile: 218
file content (318 lines) | stat: -rw-r--r-- 15,506 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
# Menu with preferences
#
DestroyMenu /Preferences
AddToMenu /Preferences
+ '%22x22/fvwm-crystal/user-desktop.png%$[gt.Used recipe]'		Popup /Preferences/Recipes
+ '%22x22/fvwm-crystal/audio-x-generic.png%$[gt.Music player]'		Popup /Preferences/MusicPlayer
+ '%22x22/fvwm-crystal/multimedia-volume-control.png%$[gt.Audio mixer]'		Popup /Preferences/Mixer
+ '%22x22/fvwm-crystal/utilities-terminal.png%$[gt.Default terminal]'	Popup /Preferences/DefaultTerminal
+ '%22x22/fvwm-crystal/utilities-terminal.png%$[gt.QuakeConsole terminal]'	Popup /Preferences/QuakeConsoleTerminal
+ '%22x22/fvwm-crystal/system-file-manager.png%$[gt.Desktop manager]'	Popup /Preferences/DesktopManager
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.Notification area manager]'		Popup /preferences/NotificationAreaManager
+ "" Nop
+ '$[gt.Window focus policy]'	Popup /Preferences/FocusPolicy
+ '$[gt.Privileged terminals]'	Popup /Preferences/PrivilegedTerminals

#
# Default terminal
#
DestroyMenu /Preferences/DefaultTerminal
AddToMenu /Preferences/DefaultTerminal
Test (x gnome-terminal) + '%22x22/apps/gnome-terminal.png%GNOME Terminal' SelectDefaultTerminal gnome-terminal
Test (x multi-gnome-terminal) + '%22x22/apps/multi-gnome-terminal.png%Multi GNOME Terminal' SelectDefaultTerminal multi-gnome-terminal
Test (x xfce4-terminal) + '%22x22/apps/xfce4-terminal.png%XFCE4 Terminal'	SelectDefaultTerminal xfce4-terminal
Test (x konsole) + '%22x22/apps/konsole.png%Konsole'	SelectDefaultTerminal konsole
Test (x Eterm) + '%22x22/apps/Eterm.png%Eterm'	SelectDefaultTerminal Eterm
Test (x mrxvt) + '%22x22/apps/mrxvt.png%MRxvt'	SelectDefaultTerminal mrxvt
Test (x urxvt) + '%22x22/apps/urxvt.png%URxvt'	SelectDefaultTerminal urxvt
Test (x aterm) + '%22x22/apps/aterm.png%Aterm'	SelectDefaultTerminal aterm
Test (x xterm) + '%22x22/apps/xterm.png%XTerm'	SelectDefaultTerminal xterm
Test (x x-terminal-emulator) + '%22x22/apps/xterm.png%Debian Default Terminal' SelectDefaultTerminal x-terminal-emulator

DestroyFunc SelectDefaultTerminal
AddToFunc SelectDefaultTerminal
+ I FindCommand DefaultTerminal $0 urxvt Eterm aterm mrxvt xterm gnome-terminal konsole xfce4-terminal x-terminal-emulator
+ I SavePreferences DefaultTerminal "FindCommand DefaultTerminal $0 urxvt Eterm aterm mrxvt xterm gnome-terminal konsole xfce4-terminal x-terminal-emulator"

#
# QuakeConsole terminal
#
DestroyMenu /Preferences/QuakeConsoleTerminal
AddToMenu /Preferences/QuakeConsoleTerminal
Test (x mrxvt) + '%22x22/apps/mrxvt.png%MRxvt'	SelectQuakeConsoleTerminal mrxvt
Test (x urxvt) + '%22x22/apps/urxvt.png%URxvt'	SelectQuakeConsoleTerminal urxvt
Test (x aterm) + '%22x22/apps/aterm.png%Aterm'	SelectQuakeConsoleTerminal aterm
Test (x xterm) + '%22x22/apps/xterm.png%XTerm'	SelectQuakeConsoleTerminal xterm

DestroyFunc SelectQuakeConsoleTerminal
AddToFunc SelectQuakeConsoleTerminal
+ I FindCommand QuakeConsoleTerminal $0 mrxvt urxvt aterm xterm
+ I SavePreferences QuakeConsoleTerminal "FindCommand QuakeConsoleTerminal $0 mrxvt urxvt aterm xterm"

#
# Notification Area Application
#
DestroyMenu /Preferences/NotificationAreaManager
AddToMenu /Preferences/NotificationAreaManager
Test (x trayer)		+ '%22x22/apps/trayer.png%Trayer' SelectNotificationAreaManager trayer
Test (x stalonetray)	+ '%22x22/apps/stalonetray.png%StaloneTray' SelectNotificationAreaManager stalonetray
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.No notification area]' NotificationAreaWidth 0
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.1 icon width]' NotificationAreaWidth 1
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.2 icons width]' NotificationAreaWidth 2
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.3 icons width]' NotificationAreaWidth 3
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.4 icons width]' NotificationAreaWidth 4
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.5 icons width]' NotificationAreaWidth 5
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.6 icons width]' NotificationAreaWidth 6
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.7 icons width]' NotificationAreaWidth 7
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.8 icons width]' NotificationAreaWidth 8
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.9 icons width]' NotificationAreaWidth 9
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.12 icons width]' NotificationAreaWidth 12
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.15 icons width]' NotificationAreaWidth 15
+ '%22x22/fvwm-crystal/trayer-app.png%$[gt.20 icons width]' NotificationAreaWidth 20


DestroyFunc SelectNotificationAreaManager
AddToFunc SelectNotificationAreaManager
+ I FindCommand NotificationAreaManager $0 trayer stalonetray
+ I SavePreferences NotificationAreaManager "FindCommand NotificationAreaManager $0 trayer stalonetray"
Test (!EnvIsSet SESSION_MANAGER) + I Module FvwmForm NotificationAreaManager-Dialog
Test (EnvIsSet SESSION_MANAGER) + I Module FvwmForm NotificationAreaManager-SM-Dialog

All (NotificationAreaManager-Dialog) Close
DestroyModuleConfig NotificationAreaManager-Dialog: *
*NotificationAreaManager-Dialog: Title "$[gt.Changed notification area manager]"
*NotificationAreaManager-Dialog: Text "$[gt.Selected notification area manager will be used]"
*NotificationAreaManager-Dialog: Line center
*NotificationAreaManager-Dialog: Text "$[gt.at the next start of your X session]"
*NotificationAreaManager-Dialog: Line center
*NotificationAreaManager-Dialog: Line center
*NotificationAreaManager-Dialog: Button quit " $[gt.Logout] " ^M
*NotificationAreaManager-Dialog: Command Quit
*NotificationAreaManager-Dialog: Button quit " $[gt.Not now] " ^[
*NotificationAreaManager-Dialog: Command Nop
*NotificationAreaManager-Dialog: Line center

All (NotificationAreaManager-SM-Dialog) Close
DestroyModuleConfig NotificationAreaManager-SM-Dialog: *
*NotificationAreaManager-SM-Dialog: Title "$[gt.Changed notification area manager]"
*NotificationAreaManager-SM-Dialog: Text "$[gt.Selected notification area manager will be used]"
*NotificationAreaManager-SM-Dialog: Line center
*NotificationAreaManager-SM-Dialog: Text "$[gt.at the next start of your X session]"
*NotificationAreaManager-SM-Dialog: Line center
*NotificationAreaManager-SM-Dialog: Line center
*NotificationAreaManager-SM-Dialog: Button quit " $[gt.Logout] " ^M
*NotificationAreaManager-SM-Dialog: Command QuitSession
*NotificationAreaManager-SM-Dialog: Button quit " $[gt.Not now] " ^[
*NotificationAreaManager-SM-Dialog: Command Nop
*NotificationAreaManager-SM-Dialog: Line center

DestroyFunc NotificationAreaWidth
AddToFunc NotificationAreaWidth
+ I FindCommand NotificationArea-Width $0 2 3 4 5 6 7 8 9
+ I Piperead `echo SetEnv trayer_width $(($0*24))`
+ I SavePreferences NotificationArea-Width "SetEnv trayer_width $[trayer_width]"
+ I Module FvwmForm NotificationArea-Restart-Dialog

All (NotificationArea-Restart-Dialog) Close
DestroyModuleConfig NotificationArea-Restart-Dialog: *
*NotificationArea-Restart-Dialog: Title "$[gt.Restart FVWM-Crystal]"
*NotificationArea-Restart-Dialog: Text "$[gt.New notification area width will be used after next startup]"
*NotificationArea-Restart-Dialog: Line center
*NotificationArea-Restart-Dialog: Line center
*NotificationArea-Restart-Dialog: Button quit " $[gt.Restart] " ^M
*NotificationArea-Restart-Dialog: Command Restart
*NotificationArea-Restart-Dialog: Button quit " $[gt.Not now] " ^[
*NotificationArea-Restart-Dialog: Command Nop
*NotificationArea-Restart-Dialog: Line center

#
# Music player
#
DestroyMenu /Preferences/MusicPlayer
AddToMenu /Preferences/MusicPlayer
Test (x alsaplayer)	+ '%22x22/apps/alsaplayer.png%Alsaplayer'	SelectMusicPlayer alsaplayer
Test (x mpc)		+ '%22x22/apps/gmpc.png%MPD'		SelectMusicPlayer mpd
Test (x quodlibet)	+ '%22x22/apps/quodlibet.png%Quod Libet'	SelectMusicPlayer quodlibet
Test (x xmms-shell) 	+ '%22x22/apps/xmms.png%XMMS'	SelectMusicPlayer xmms
Test (x xmms2) 		+ '%22x22/apps/xmms2.png%XMMS2'	SelectMusicPlayer xmms2
Test (x cmus-remote)	+ '%22x22/apps/cmus.png%C Music Player' SelectMusicPlayer cmus
Test (x cdcd) 		+ '%22x22/apps/goobox.png%cdcd'	SelectMusicPlayer cdcd
Test (x mocp) 		+ '%22x22/apps/mocp.png%Music On Console' SelectMusicPlayer mocp
Test (x audacious) 	+ '%22x22/apps/audacious.png%Audacious' SelectMusicPlayer audacious
Test (x mplayer) 	+ '%22x22/apps/mplayer.png%MPlayer' SelectMusicPlayer mplayer

DestroyFunc SelectMusicPlayer
AddToFunc SelectMusicPlayer
+ I FindCommand MusicPlayer $0 alsaplayer mpd quodlibet audacious xmms xmm2 cmus mocp cdcd mplayer
+ I Include components/functions/Music-$[MusicPlayer]
+ I SavePreferences DefaultMusicPlayer "SetEnv MusicPlayer $[MusicPlayer]"

#
# Audio mixer
#
DestroyMenu /Preferences/Mixer
AddToMenu /Preferences/Mixer
Test (x amixer)		+ '%22x22/apps/alsamixer.png%ALSA Mixer' SelectMixer amixer
Test (x aumix) 		+ '%22x22/apps/aumix.png%Aumix'	SelectMixer aumix
			+ "" Nop
Test (x mpc)		+ '%22x22/apps/gmpc.png%MPD'		SelectMixer mpd
Test (x quodlibet)	+ '%22x22/apps/quodlibet.png%Quod Libet'	SelectMixer quodlibet
Test (x xmms-shell) 	+ '%22x22/apps/xmms.png%XMMS'	SelectMixer xmms
Test (x xmms2) 		+ '%22x22/apps/xmms2.png%XMMS2'	SelectMixer xmms2
Test (x cmus-remote)	+ '%22x22/apps/cmus.png%C Music Player' SelectMixer cmus
Test (x cdcd) 		+ '%22x22/apps/goobox.png%cdcd'	SelectMixer cdcd
Test (x audacious) 	+ '%22x22/apps/audacious.png%Audacious'	SelectMixer audacious

DestroyFunc SelectMixer
AddToFunc SelectMixer
+ I FindCommand DefaultMixer $0 amixer aumix mpd quodlibet audacious xmms xmms2 cmus cdcd
+ I Include components/functions/Mixer-$[DefaultMixer]
+ I SavePreferences DefaultMixer "Include components/functions/Mixer-$[DefaultMixer]"

#
# Desktop manager
#
DestroyMenu /Preferences/DesktopManager
AddToMenu /Preferences/DesktopManager
+ '$[gt.None]' ActivateDesktopManager-None
+ "" Nop
Test (x rox) + '%22x22/apps/rox.png%ROX-Filer' ActivateDesktopManager-ROX
Test (x nautilus) + '%22x22/apps/nautilus.png%Nautilus' ActivateDesktopManager-Nautilus

DestroyFunc ActivateDesktopManager-None
AddToFunc ActivateDesktopManager-None
+ I SavePreferences DefaultDesktopManager "LoadPreferences LastChoosenWallpaper"
Test (!EnvIsSet SESSION_MANAGER) + I Module FvwmForm DesktopManager-Dialog
Test (EnvIsSet SESSION_MANAGER) + I Module FvwmForm DesktopManager-SM-Dialog

DestroyFunc ActivateDesktopManager-ROX
AddToFunc ActivateDesktopManager-ROX
+ I SavePreferences DefaultDesktopManager "Include components/apps/ROX-Filer"
Test (!EnvIsSet SESSION_MANAGER) + I Module FvwmForm DesktopManager-Dialog
Test (EnvIsSet SESSION_MANAGER) + I Module FvwmForm DesktopManager-SM-Dialog

DestroyFunc ActivateDesktopManager-Nautilus
AddToFunc ActivateDesktopManager-Nautilus
+ I SavePreferences DefaultDesktopManager "Include components/apps/Nautilus"
Test (!EnvIsSet SESSION_MANAGER) + I Module FvwmForm DesktopManager-Dialog
Test (EnvIsSet SESSION_MANAGER) + I Module FvwmForm DesktopManager-SM-Dialog

All (DesktopManager-Dialog) Close
DestroyModuleConfig DesktopManager-Dialog: *
*DesktopManager-Dialog: Title "$[gt.Changed desktop manager]"
*DesktopManager-Dialog: Text "$[gt.Selected desktop manager will be used]"
*DesktopManager-Dialog: Line center
*DesktopManager-Dialog: Text "$[gt.at the next start of your X session]"
*DesktopManager-Dialog: Line center
*DesktopManager-Dialog: Line center
*DesktopManager-Dialog: Button quit " $[gt.Logout] " ^M
*DesktopManager-Dialog: Command Quit
*DesktopManager-Dialog: Button quit " $[gt.Not now] " ^[
*DesktopManager-Dialog: Command Nop
*DesktopManager-Dialog: Line center

All (DesktopManager-SM-Dialog) Close
DestroyModuleConfig DesktopManager-SM-Dialog: *
*DesktopManager-SM-Dialog: Title "$[gt.Changed desktop manager]"
*DesktopManager-SM-Dialog: Text "$[gt.Selected desktop manager will be used]"
*DesktopManager-SM-Dialog: Line center
*DesktopManager-SM-Dialog: Text "$[gt.at the next start of your X session]"
*DesktopManager-SM-Dialog: Line center
*DesktopManager-SM-Dialog: Line center
*DesktopManager-SM-Dialog: Button quit " $[gt.Logout] " ^M
*DesktopManager-SM-Dialog: Command QuitSession
*DesktopManager-SM-Dialog: Button quit " $[gt.Not now] " ^[
*DesktopManager-SM-Dialog: Command Nop
*DesktopManager-SM-Dialog: Line center

#
# Window focus policy
#
DestroyMenu /Preferences/FocusPolicy
AddToMenu /Preferences/FocusPolicy
+ 'FVWM-Crystal'	ActivateFocusPolicy-FVWM-Crystal
+ 'FVWM-Crystal with raise'	ActivateFocusPolicy-FVWM-Crystal-Raise
+ 'MS Windows'		ActivateFocusPolicy-MSWindows

DestroyFunc ActivateFocusPolicy-FVWM-Crystal
AddToFunc ActivateFocusPolicy-FVWM-Crystal
+ I Include components/styles/FocusPolicy-FVWM-Crystal
+ I Include components/styles/FVWM
+ I Include components/styles/QuakeConsole
+ I Append components/styles/Applications
+ I SavePreferences DefaultFocusPolicy "Include components/styles/FocusPolicy-FVWM-Crystal"

DestroyFunc ActivateFocusPolicy-FVWM-Crystal-Raise
AddToFunc ActivateFocusPolicy-FVWM-Crystal-Raise
+ I Include components/styles/FocusPolicy-FVWM-Crystal-Raise
+ I Include components/styles/FVWM
+ I Include components/styles/QuakeConsole
+ I Append components/styles/Applications
+ I SavePreferences DefaultFocusPolicy "Include components/styles/FocusPolicy-FVWM-Crystal-Raise"

DestroyFunc ActivateFocusPolicy-MSWindows
AddToFunc ActivateFocusPolicy-MSWindows
+ I Include components/styles/FocusPolicy-MSWindows
+ I Include components/styles/FVWM
+ I Include components/styles/QuakeConsole
+ I Append components/styles/Applications
+ I SavePreferences DefaultFocusPolicy "Include components/styles/FocusPolicy-MSWindows"

#
# Privileged terminals
#
DestroyMenu /Preferences/PrivilegedTerminals
AddToMenu /Preferences/PrivilegedTerminals
+ '$[gt.On]'	SetPrivilegedTerminals
+ '$[gt.Off]'	UnsetPrivilegedTerminals

DestroyFunc SetPrivilegedTerminals
AddToFunc SetPrivilegedTerminals
+ I SavePreferences PrivilegedTerminals "Style XTerm FPOverrideGrabFocus"
+ I AppendPreferences PrivilegedTerminals "Style URxvt FPOverrideGrabFocus"
+ I AppendPreferences PrivilegedTerminals "Style Eterm FPOverrideGrabFocus"
+ I LoadPreferences PrivilegedTerminals

DestroyFunc UnsetPrivilegedTerminals
AddToFunc UnsetPrivilegedTerminals
+ I SavePreferences PrivilegedTerminals "Style XTerm !FPOverrideGrabFocus"
+ I AppendPreferences PrivilegedTerminals "Style URxvt !FPOverrideGrabFocus"
+ I AppendPreferences PrivilegedTerminals "Style Eterm !FPOverrideGrabFocus"
+ I LoadPreferences PrivilegedTerminals


#
# Recipes
#
DestroyMenu /Preferences/Recipes
AddToMenu /Preferences/Recipes
+ MissingSubmenuFunction Recipes-generator
+ '%22x22/categories/directory.png%$[gt.System]' Popup $[FVWM_SYSTEMDIR]/recipes
Test (f $[FVWM_USERDIR]/recipes) + '%22x22/categories/directory.png%$[gt.User]' Popup $[FVWM_USERDIR]/recipes

DestroyFunc Recipes-generator
AddToFunc Recipes-generator
+ I DestroyMenu recreate $0
+ I AddToMenu $0
+ I PipeRead 'for i in $0/*; do \
  name=$(basename "${i}"); \
  echo \"AddToMenu $0 \'${name}\' Recipe-Set \'${i}\'\"; done'

DestroyFunc Recipe-Set
AddToFunc Recipe-Set
+ I SavePreferences LastChoosenRecipe "Read \"$*\""
+ I Module FvwmForm Recipe-Restart-Dialog

All (Recipe-Restart-Dialog) Close
DestroyModuleConfig Recipe-Restart-Dialog: *
*Recipe-Restart-Dialog: Title "$[gt.Restart FVWM-Crystal]"
*Recipe-Restart-Dialog: Text "$[gt.New recipe will be used after next startup]"
*Recipe-Restart-Dialog: Line center
*Recipe-Restart-Dialog: Line center
*Recipe-Restart-Dialog: Button quit " $[gt.Restart] " ^M
*Recipe-Restart-Dialog: Command Restart
*Recipe-Restart-Dialog: Button quit " $[gt.Not now] " ^[
*Recipe-Restart-Dialog: Command Nop
*Recipe-Restart-Dialog: Line center

# vim:ft=fvwm