|
楼主 |
发表于 2005-10-7 22:26:35
|
显示全部楼层
我的fvwm2rc
我也不知道哪部分是管这个事情的,发上来大家各取所需吧。
- #Style "Qterm*" Icon /usr/share/qterm/pic/qterm_48x48.png, IconOverride
- #Style "SWT*" IconOverride,Icon /usr/share/pixmaps/QQ.png
- ClickTime 750
- DeskTopSize 2x1
- #设置桌面大小
- EdgeScroll 0 0
- #鼠标在桌面边上移动时不跳到其它桌面
- OpaqueMoveSize -1
- ## 移动窗口时显示窗口内容
- IgnoreModifiers L25
- ## 忽略 CapsLock, NumLock, ScrollLuck 以避免快捷键失效
- ########################menu color###############################
- Colorset 110 fg #000000, fgsh #000000, bg #9aa6ab, sh #6e90b3, hi #91b6db, Translucent, Tint #ffffff 60
- Colorset 111 fg #000000, fgsh #b5b7b8, bg #ffffff, hi #b3b3b2, sh #9a9a9a, Translucent, Tint #dce0e7 50
- #################################################################
- MenuStyle * win
- MenuStyle * PopupDelayed, PopupDelay 200, Animation, TitleWarp
- #MenuStyle * Font "-*-bitstream vera sans-medium-r-normal-*-14-0-0-0-p-0-iso8859-1, -*-ar pl new sung-medium-r-normal-*-14-*-*-*-c-*-iso10646-1"
- MenuStyle * Font "StringEncoding=gbk-0:xft:WenQuanYi Bitmap Song:pixelsize=15:encoding=iso10646-1"
- #MenuStyle * Font "-wqy-*-medium-r-normal-*-16-*-*-*-*-*-iso10646-1"
- MenuStyle * Hilight3DThin, PopupOffset +0 100
- MenuStyle * MenuColorset 110, HilightBack, ActiveColorset 111
- MenuStyle * BorderWidth 2, TitleUnderlines1, SeparatorsLong, TrianglesSolid
- MenuStyle "WindowList" VerticalItemSpacing 5 5
- MenuStyle "WindowList" MenuColorset 110, HilightBack, ActiveColorset 111
- #MenuStyle "WindowList" Font "-*-bitstream vera sans-medium-r-normal-*-14-0-0-0-p-0-iso8859-1, -*-ar pl new sung-medium-r-normal-*-14-*-*-*-c-*-iso10646-1"
- MenyStyle "WindowList" Font "StringEncoding=gbk-0:xft:WenQuanYi Bitmap Song:pixelsize=15:encoding=iso10646-1"
- #MenuStyle "WindowList" VerticalTitleSpacing 10 10
- #DestroyMenuStyle WindowList
- DesktopName 0 Windows List
- ImagePath /home/liangzi/.fvwm/icons/default/32x32/apps:+
- ImagePath /home/liangzi/.fvwm/decors/images:+
- ImagePath /usr/share/icons/wm-icons/16x16-general:+
- ImagePath /home/liangzi/.fvwm/icons/default/32x32/actions:+
- #ColormapFocus FollowsMouse
- #--------------------------------------------
- #-----------Add by liangzi-------------------
- CursorStyle ROOT left_ptr
- CursorStyle RIGHT_EDGE right_ptr black white
- CursorStyle MENU left_ptr black white
- CursorStyle TITLE left_ptr black white
- CursorStyle DEFAULT left_ptr black white
- CursorStyle SYS left_ptr black white
- CursorStyle WAIT watch black white
- CursorStyle RESIZE sizing black "#5477A0"
- CursorStyle MOVE fleur yellow black
- CursorStyle SELECT left_ptr black white
- CursorStyle POSITION left_ptr black white
- CursorStyle TOP top_side red black
- CursorStyle RIGHT right_side red black
- CursorStyle BOTTOM bottom_side red black
- CursorStyle LEFT left_side red black
- CursorStyle TOP_LEFT top_left_corner red black
- CursorStyle TOP_RIGHT top_right_corner red black
- CursorStyle BOTTOM_LEFT bottom_left_corner red black
- CursorStyle BOTTOM_RIGHT bottom_right_corner red black
- #---------------end of added by liangzi---------------
- #Style * StippledTitle
- #--------------------呵呵,看标题栏
- Style * IconOverride, Icon $[FVWM_USERDIR]/icon.tmp.$[w.id].png
- #Style * Font "-*-bitstream vera sans-medium-r-*-*-14-*,-misc-ar pl new sung-medium-r-normal-*-14-*-*-*-*-*-iso10646-1"
- #Style * IconFont "-*-bitstream vera sans-medium-r-*-*-14-*,-misc-ar pl new sung-medium-r-normal-*-14-*-*-*-*-*-iso10646-1"
- Style * Font "StringEncoding=gbk-0:xft:WenQuanYi Bitmap Song:pixelsize=15:bold:encoding=iso10646-1"
- Style * IconFont "StringEncoding=gbk-0:xft:WenQuanYi Bitmap Song:pixelsize=15:encoding=iso10646-1"
- Style * HilightFore black, HilightBack white
- Style * BorderWidth 2, HandleWidth 2
- Style * Icon unknown1.xpm, Color black/black
- Style * MWMFunctions, MWMDecor, HintOverride
- Style * DecorateTransient, NoPPosition
- Style * IconBox 0 -10 -280 -1
- Style * FocusFollowsMouse
- Style * CascadePlacement
- #Style * NoIcon, NoIconTitle
- #最小化不显示图标和图标下面的字
- #Style "XMMS_Playlist" WindowListSkip
- #Style "Torsmo*" WindowListSkip, StaysOnBottom, NeverFocus
- Style "Gdeskcal" WindowListSkip, StaysOnbottom
- Style "fbpanel*" StaysOnTop
- # some simple default key bindings:
- Key F1 A M GotoPage 0 0
- Key F2 A M GotoPage 1 0
- #Key F3 A M GotoPage 0 1
- #Key F4 A M GotoPage 1 1
- Key F12 A A Module FvwmConsole
- Key L A 4 Exec exec xscreensaver-command -lock
- Key D A 4 All (AcceptsFocus CurrentPage !Iconic !Shaded, !"gDesklets*", !"Gdeskcal*") Thumbnail
- Key C A 4 Exec exec mrxvt
- Key R A 4 Exec exec grun
- Key Q A 4 Exec exec qterm
- Key Tab A M WindowList Root c c CurrentDesk, NoGeometry, NoCurrentDeskTitle, CurrentAtEnd, IconifiedAtEnd
- Key Space A M Menu Window-Ops2 rectangle $[w.x]x$[w.y]+10+10 +100 +100
- Key equal A M Exec exec amixer set PCM 2%+
- Key minus A M Exec exec amixer set PCM 2%-
- Key Z A 4 All ("15092486*", !Focused) showqq
- # some simple default mouse bindings:
- # for the root window:
- Mouse 3 R A Menu RootMenu Nop
- Mouse 1 R A -
- # for the title bar buttons:
- Mouse 0 1 A Menu Window-Ops2 Close
- Mouse 1 2 A Close
- Mouse 1 6 A Thumbnail
- Mouse 1 4 A Maximize
- # for other parts of the window/borders/icons:
- Mouse 1 F A Resize-or-Raise
- Mouse 1 S A Resize-or-Raise
- Mouse 1 T A Move-or-Raise
- Mouse 1 I A Move-or-Iconify
- Mouse 2 I A Thumbnail
- Mouse 2 FST A Menu Window-Ops2 Nop
- Mouse 3 TSIF A RaiseLower
- Stroke N5456 0 A C Exec exec xkill
- Stroke N65456 0 A C Exec exec xkill
- ## 读入窗口样式
- #Read ./decorations/Clear/Violet.theme
- #Read ./decorations/Clear/Red.theme
- #Read ./decorations/Clear/Orange.theme
- #Read ./decorations/Clear/Navy.theme
- #Read ./decorations/Clear/Mono.theme
- #Read ./decorations/Clear/Green.theme
- #Read ./decorations/Clear/Blue.theme
- #Read ./decorations/Crystal/WhiteDesktop.theme
- #Read ./decorations/Crystal/RedDesktop.theme
- #Read ./decorations/Crystal/Red - Cyan.theme
- #Read ./decorations/Crystal/IrishDesktop.theme
- #Read ./decorations/Crystal/DarkGreen.theme
- #Read ./decorations/Crystal/DarkDesktop.theme
- #Read ./decorations/Crystal/CrystalZono.theme
- #Read ./decorations/Crystal/CIOS.theme
- #Read ./decorations/Crystal-Aqua/Default.theme
- #Read ./decorations/Dawn of a Terminal/Red.theme
- #Read ./decorations/Dawn of a Terminal/Purple.theme
- #Read ./decorations/Dawn\ of\ a\ Terminal/Green.theme
- #Read ./decorations/Dawn of a Terminal/Blue.theme
- #Read ./decorations/Elberg/Elberg.theme
- #Read ./decorations/Fear/Original.theme
- Read ./decorations/Fear/Original\ (crystalized).theme
- #Read ./decorations/Gentoo/Gentoo.theme
- #Read ./decorations/Gentoo/Gentoo Gray.theme
- #Read ./decorations/Gentoo/Gentoo Alternative.theme
- #Read ./decorations/Industrial/Industrial\ (Metacity\ version).theme
- #Read ./decorations/Industrial/Industrial (Crystal version).theme
- #Read ./decorations/Metabox/Metabox (Metacity version).theme
- #Read ./decorations/Metabox/Metabox (Crystal version).theme
- #Read ./decorations/Winter/Winter.theme
- #Read ./decorations/Winter/Winter (no icon).theme
- ## 用快捷键叫 qq 时要做的事情
- AddtoFunc showqq
- + I MoveToPage
- + I Iconify off
- + I Raise
- + I Focus
- + I WarpToWindow 50 2
- ## 以下三个函数是控制 fbpanel 自动隐藏的
- AddtoFunc autohide
- + I ThisWindow ($0) Deschedule $[w.id]
- + I ThisWindow ($0) KeepRc ThisWindow (shaded) WindowShade off
- + I TestRc (!Match) All ($0, !shaded) autohide_hide $1 $2
- AddtoFunc autohide_hide
- + I Schedule $0 $[w.id] WindowShade $1
- + I Schedule $0 $[w.id] Deschedule $[w.id]
- AddToFunc enter_handler
- + I autohide fbpanel 100 N
- ## 启动fvwm时要做的事情
- AddToFunc StartFunction
- + I Exec exec habak ~/pics/puma.jpg
- + I Exec exec fbpanel
- + I Module FvwmAuto FvwmAutohide -menter enter_handler
- + I Exec exec env LC_ALL=C torsmo
- + I Test (Restart) All (Iconic) Test (f $[FVWM_USERDIR]/icon.tmp.$[w.id].png) WindowStyle IconOverride, Icon $[FVWM_USERDIR]/icon.tmp.$[w.id].png
- AddToFunc InitFunction
- + I Nop
-
- AddToFunc SessionInitFunction
- + I Nop
- ## 退出 fvwm 时要做的事情
- AddToFunc ExitFunction
- + I Exec killall fbpanel
- + I Exec killall gdeskcal
- + I Exec killall python
- + I Exec killall torsmo
- + I Test (!ToRestart) Exec rm -f $[FVWM_USERDIR]/icon.tmp.*
- #WindowStyle IconOverride, Icon $[FVWM_USERDIR]/icon.tmp.$[w.id].png
- ## 通过 alt-tab 使窗口得到焦点时,鼠标的位置 50%x, 2%y
- AddToFunc WindowListFunc I WarpToWindow 50 2
- ## menu 包在维护这个菜单,详见 man menu
- Read /home/liangzi/.fvwm/menudefs.hook
- ## 根菜单
- DestroyMenu RootMenu
- AddToMenu RootMenu
- + "Debian%deb.png%" Popup "/Debian"
- + "" Nop
- + "rxvt%terminal.png%" Exec exec mrxvt
- + "Firefox%firefox.png%" Exec exec /home/liangzi/tmp/firefox/firefox
- + "QQ%QQ.png%" Exec exec lumaqq
- + "QTerm%x.png%" Exec exec qterm
- + "" Nop
- + "Restart Fvwm%reload.png%" Restart
- + "Yes, Really Quit%error.png%" Quit
- ## 窗口菜单
- AddToMenu Window-Ops2 "Move (&M)%window-move.xpm%" Move
- #+ "&Resize%window-resize.xpm%" Resize
- #+ "R&aise%window-raise.xpm%" Raise
- #+ "&Lower%window-lower.xpm%" Lower
- + "Minimize (&I)%window-iconify.xpm%" Thumbnail
- #+ "(Un)&Stick%window-stick.xpm%" Stick
- + "Maxmize (&X)%window-maximize.xpm%" Maximize
- + "" Nop
- + "&Delete%window-delete.xpm%" Delete
- + "Destroy%window-destroy.xpm%" Destroy
- + "&Close%window-close.xpm%" Close
- + "" Nop
- + "Refresh Window" RefreshWindow
- ## 一些窗口操作的函数
- AddToFunc Move-or-Raise I Raise
- + M Move
- + D Maximize
- AddToFunc Move-or-Iconify I Raise
- + M Move
- + D Thumbnail
- AddToFunc Resize-or-Raise I Raise
- + M Resize
- + D Lower
- DestroyFunc Thumbnail
- AddToFunc Thumbnail
- + I Raise
- + I SetEnv Icon-$[w.id] $[w.iconfile]
- + I ThisWindow (!Shaded Iconifiable !Iconic) PipeRead \
- "xwd -silent -id $[w.id] | convert -scale 64 -frame 1x1 \
- -mattecolor black -quality 0 xwd:- \
- png:$[FVWM_USERDIR]/icon.tmp.$[w.id].png \
- && echo WindowStyle IconOverride, \
- Icon $[FVWM_USERDIR]/icon.tmp.$[w.id].png \
- || echo Nop"
- + I Iconify
- #DeThumbnail函数用来恢复存的图标:
- DestroyFunc DeThumbnail
- AddToFunc DeThumbnail
- + I PipeRead "echo WindowStyle Icon \\$\\[Icon-$[w.id]\\]"
- + I UnsetEnv Icon-$[w.id]
- + I Exec rm -f $[FVWM_USERDIR]/icon.tmp.$[w.id].png
- #要想在重启fvwm后还能使用这些缩略图标,可以在StartFunction里加入下面的几行
- #AddToFunc StartFunction I Test (Restart) All (Iconic) \
- #Test (f $[FVWM_USERDIR]/icon.tmp.$[w.id].png) WindowStyle IconOverride, Icon $[FVWM_USERDIR]/icon.tmp.$[w.id].png
- #你也可以检查一下忘了删除的缩略图,并在ExitFunction函数里删除它们。
- #AddToFunc ExitFunction I Test (!ToRestart) \
- #Exec rm -f $[FVWM_USERDIR]/icon.tmp.*
复制代码
Post by Yei
又看了一遍,似乎只讲了如何设置透明的模块、菜单、窗口装饰,也介绍了Thumbnail。
但我仍然不知道怎么让一个Thumbnail产生的图标成半透明的。 |
|