OpenBSD 桌面


靓丽OpenBSD桌面作者: rainren
本文环境: OpenBSD 3.5
OpenBSD的强项是网络安全, 主要是使用PF构建防火墙. 但OpenBSD也有简单这个特性, 在它的系统里, 简单是一个特点; 也就是说让你的系统管理很简单.
今天, 我在这里show 一下我的桌面配置过程, 当然也请使用过fvwm的高手们指点一下我配置过程中的错误.
一. 配置fvwm桌面
OpenBSD3.5使用fvwm2.2.5作为默认的桌面, 当然, 如果你在安装系统时没有安装xserver.tgz等几个包, 现在也可以将那些包下载到硬盘上, 然后再:
Tar xvzfp *.tgz
安装这些软件包来使用桌面环境.
配置好XF86Config, startx出现的桌面是系统的缺省配置桌面, 这个配置文件.fvwmrc在/usr/X11R6/lib/X11/fvwm下, 在这个目录下还有关于fvwm使用的模块列表及另外一些桌面的配置文件. 介绍一下桌面位置: 左上角:0 0, 左下角:0-0, 右上角: -0 0, 右下角: -0-0!
如果你想深入了解fvwm的配置情况, 可以参考网上各种fvwm的学习教程, 下面我只是说一下我的改动情况!
Fvwm使用的图片格式是xpm, png, 你可以使用gimp将你使用的图片转换成xpm格式. 在配置文件中的颜色值可以是一个英文名或一个十六进制值 。
首先, 我们在根目录下建立.fvwm文件夹, 然后
cp /usr/X11R6/lib/X11/fvwm/.fvwmrc ~/.fvwm/.fvwm2rc
下面, 将以我对~/.fvwm/.fvwm2rc文件所做的改动为例, 说说如何配置桌面:

# be sure to customize these paths for your installation:
ModulePath /usr/X11R6/lib/X11/fvwm[color=red:8fa26d1069]模块的路径名[/color:8fa26d1069]
PixmapPath /usr/X11R6/include/X11/pixmaps[color=red:8fa26d1069]fvwm使用图片的路径, 桌面背景图片就是放在这里, 我使用的桌面背景图片是:openbsddesktop.xpm[/color:8fa26d1069]
IconPath /usr/X11R6/include/X11/bitmaps
EdgeResistance 250 100
EdgeScroll 50 50[color=red:8fa26d1069]当mouse移到桌面边缘时, 桌面的移动情况[/color:8fa26d1069]
ClickTime 750
# make sure these fonts exist on your system:
WindowFont -adobe-times-bold-r-*-*-14-*-*-*-*-*-*-*[color=red:8fa26d1069]窗口使用的字体[/color:8fa26d1069]
IconFont -adobe-helvetica-bold-r-*-*-10-*-*-*-*-*-*-*
HilightColor blue #898e84 [color=red:8fa26d1069]窗口的高亮显示时的颜色[/color:8fa26d1069]
MenuStyle #b0d5fc gray40 #49c671 -adobe-times-bold-r-*-*-12-*-*-*-*-*-*-* fvwm[color=red:8fa26d1069]菜单使用的前景色, 背景色,阴影色, 字体类型[/color:8fa26d1069]
DeskTopSize 2x2 [color=red:8fa26d1069] 每一个虚拟桌面的大小[/color:8fa26d1069]
ColormapFocus FollowsMouse
# default Styles:
Style "*" BorderWidth 5, HandleWidth 5, NoHandles [color=red:8fa26d1069]在这里我加了一个NoHandles, 也就是窗口不要柄 [/color:8fa26d1069]
Style "*" Icon unknown1.xpm, Color green/#698593[color=red:8fa26d1069] 定义窗口颜色 [/color:8fa26d1069]
Style "*" MWMFunctions, MWMDecor, HintOverride
Style "*" DecorateTransIEnt, NoPPosition
Style "*" IconBox -0 -11 -1
Style "*" SloppyFocus, FocusFollowsMouse
Style "*" RandomPlacement, SmartPlacement
# Styles for various Fvwm modules:
Style "Fvwm*" NoTitle, Sticky, WindowListSkip
Style "Fvwm*" BorderWidth 2, CirculateSkipIcon, CirculateSkip
Style "FvwmPager" StaysOnTop
Style "FvwmBanner" StaysOnTop
Style "FvwmButtons" Icon toolbox.xpm, ClickToFocus
# Styles for your common terminal emulator programs:
AddToDecor terms
ButtonStyle 1 Pixmap mini.xterm.xpm
HilightColor blue #898e84
Style "XTerm" UseDecor terms
Style "XTerm" Icon xterm.xpm, SloppyFocus, IconBox -70 1 -1 -140
Style "rxvt" UseDecor terms
Style "rxvt" Icon term.xpm, SloppyFocus, IconBox -70 1 -1 -140
Style "rxvt" MWMBorder, MWMButtons
# Styles for various common programs:
Style "xcalc" Icon xcalc.xpm, NoButton 2,RandomPlacement,ClickToFocus

推荐阅读