Chinaunix首页 | 论坛 | 博客
  • 博客访问: 280374
  • 博文数量: 55
  • 博客积分: 2535
  • 博客等级: 少校
  • 技术积分: 585
  • 用 户 组: 普通用户
  • 注册时间: 2008-07-25 16:41
个人简介

Je pense donc je suis.

文章分类

全部博文(55)

文章存档

2014年(11)

2011年(3)

2010年(40)

2009年(1)

我的朋友

分类: LINUX

2010-03-30 22:21:50

Install LXDE (可选)
$ sudo apt-get install gdm lxde

Install fvwm (可选)
$ sudo apt-get install fvwm-crystal



Uninstall Gnome
$ sudo apt-get --purge remove liborbit2

Uninstall twm
$ sudo apt-get remove twm





Install Window manager
$ sudo apt-get install nautilus rox-filer





################ LXDE下使用thunar作为文件管理器 #################################
由于LXDE自带的pcmanfm的搜索功能比较差,而且不好用,换用xfce4的Thunar配合gnome-search-tool来代替,一者利用 Thunar的快速特点,二者利用Gnome-search-tool的快速搜索功能,以弥补Nautilus速度慢的缺点。

配置方法:

$ sudo apt-get install thunar

In Thunar, choose 'Edit'->'Configure Custom Actions' and add a new custom action with the name 'Search for Files' and the command 'gnome-search-tool --path=%f'. Under the 'Appearance Conditions' tab, tick 'Directories' - this is important.

You will now be able to tick on any directory in the right pane, and choose 'Search for Files'. This file-searcher has many different options for doing advanced searches.

另外,如果要添加到panel的application launcher bar,那么可以修改/usr/share/applications/Thunar.desktop中的Icon项为
#Icon=Thunar
Icon=/usr/share/icons/hicolor/32x32/apps/nautilus.png
因为觉得那么图标比较难看哦!

################            LXDE添加快捷键(keyboard shortcut)    ######################
使用
$ sudo apt-get install lxde
就可以安装LXDE桌面了。

前段时间希望从网上找到配置快捷键的方法,但是苦于最近无法访问lxde的相关网页,所以一直没有成功,今天在前段时间的尝试基础上终于成功了。现记录如下:

1. 首先编辑(以下为了便于说明,用红色的字体指名添加位置)
$ sudo gedit /usr/share/lxde/openbox/rc.xml
在如下位置
 
 
   
     
        true
        PCManFM
     

      pcmanfm
   

 

 
在这个地方添加你需要设置的快捷键启动方式

 

添加快捷键启动方式(这里我添加了shell和截屏的两组快捷键)

使之变为如下形式:
 
 
   
     
        true
        PCManFM
     

      pcmanfm
   

 


 
   
     
        true
        x-terminal-emulator
     

      x-terminal-emulator
   

 


 
   
     
        true
        Gnome-Screenshot
     

      gnome-screenshot
   

 


 
   
     
        true
        Force Quit
     

      xkill
   

 


 

2. 然后检查$HOME/.config/是否含有openbox目录(刚刚在gnome下安装LXDE后是没有的,此时只要重启X,然后选择进入到lxde就可以使用快捷键了),如果有,那么就编辑
$ gedit ~/.config/openbox/lxde-rc.xml
重复上面的编辑/usr/share/lxde/openbox/rc.xml的工作即可,完成后保存,重启X,便可以了!

注:以后如果要加入新的快捷键,那么其实只要进行第二步就可以了,第一步可以不再进行。比如现在希望加入Ctrl+Alt+l实现锁定屏幕,那么可以在前面提到的适当位置添加如下内容:
    
   
     
        true
        Lock Screen
     

      xscreensaver-command -l      
   

 

然后重启X即可。
注意:这里如果用的gnome-screensaver,就把xscreensaver-command -l改为:
gnome-screensaver-command -l


如果要在openbox里面添加关机菜单那么可以在~/.config/openbox/menu.xml里面添加


gdm-control --shutdown


openbox --exit




######################## LXDE配置 ######################################################
以前很不习惯LXDE的panel的定制方式,有几次不小心删掉了,却找不到恢复的方法,这次有了一点启发:

右键点击一个panel,选择“Panel Settings“-> Panel Applets,然后就可以看到目前的panel上的内容了,目前我的Panel为(按照从上到下的顺序):
Menu, Separator, Application Launch Bar, Separator, Minimize All Windows, Separator, Desktop Pager, Separator, Task Bar (Window List), Separator, CPU Usage Monitor, Volume Control, System Tray, Digital Clock。 其中只有Task Bar(Window List) 勾选了Stretch选项。

如果没有上面的某个applet,可点击"Add"按钮,然后就可以进行添加了,还可以调整顺序呢!

如果要添加某个启动项(指应用程序快捷方式),那么只要先用左键单击选定"Application Launch Bar",再点击“EDit”按钮,旋即看到的就是已经有的启动项了,选择"Add",就可以在/usr/share/applications里面找你希望的快捷方式了——注意,是以.desktop为扩展名的。如果没有,那么需要使用如下的方法进行添加,这里以添加Maple, mathematica为例说明,假设均安装在$HOME:

1. 添加maple13快捷方式
 $ cd /usr/share/applications/
 $ sudo ln -sf $HOME/maple13/bin/maple13.desktop maple13.desktop
 右键点击面板(Panal)上 "Application Launch Bar" Settings,选择Add
 然后选择maple13.desktop就可以了。

2. 添加mathematica快捷方式
 再比如,现在要添加Mathematica-7.0.1的启动项,该软件安装在$HOME/Mathematica/,那么步骤为:
 $ cd /usr/share/applications
 $ sudo ln -sf $HOME/Mathematica/7.0/SystemFiles/Installation/wolfram-mathematica.desktop Mathematica-7.0.1.desktop
 然后右键点击面板(Panal)上 "Application Launch Bar" Settings,选择Add
 然后选择Mathematica-7.0.1.desktop就可以了。

注意:如果按照上述方法添加了启动项后,图标可能没有,只有黑色的一个所谓“图标”,那么可以修改一下,比如对于Mathematica-7.0.1,
可以按照下面内容作更改:
[10:27:18@~$] cat /usr/share/applications/wolfram-mathematica.desktop
[Desktop Entry]
Version=1.0
Type=Application
Name=Mathematica 7
Comment=Technical Computing System
TryExec=$HOME/Mathematica/start/Mathematica
Exec=$HOME/Mathematica/start/Mathematica %F
Icon=$HOME/Mathematica/7.0/SystemFiles/FrontEnd/SystemResources/X/Mathematica-128.png
MimeType=application/mathematica


另外,如果要更改字号,那么
Main Menu->Preferences->Appearances->Window,在左下方的Font栏选择即可,目前我选为
Sans 12就行。

如果要不让桌面显示一些东东,那么打开PCM File Manager(可从Main Menu->System Tools打开),
从Edit->Preferences->Desktop,去掉“Manage the desktop and show file icons“选项即可,
也是在这个地方,你可以设置自己喜欢的桌面。当然,如果你需要显示一些桌面项,那么就勾选该项即可。

恢复显示墙纸:
有时会在桌面上点右键,选择"Desktop settings",在里面把"Manage desktop and show file icons"前
面的钩去掉了。本来是想试一下,可这么一试,桌面上的图标没了,重启后干脆桌面背景也没了,
只有刚启动X时黑白相间的灰色背景。点右键已没有了原来的设置选项。原来桌面显示是由LXDE自带的
文件管理器pcmanfm设置的,将~/.config/pcmanfm/main.lxde里的show_desktop=0改为1,
重启lxde就好了。

###########  LXDE 下设置Mathematica, maple的Launch bar ######################
以下假设上述软件均安装在$HOME,且下面凡遇到$HOME,均需换为该环境变量的值

cd /usr/share/applications/
sudo ln -s $HOME/maple13/bin/maple13.desktop  maple13.desktop
sudo ln -s $HOME/Mathematica/7.0/SystemFiles/Installation/wolfram-mathematica.desktop mathematica-7.0.1.desktop

由于此时添加Launch Bar后可能发现mathematica的图标是黑色的,那么需要修改:
sudo gedit $HOME/Mathematica/7.0/SystemFiles/Installation/mathematica-7.0.1.desktop
然后把Icon一行改为:
Icon=$HOME/Mathematica/7.0/SystemFiles/FrontEnd/SystemResources/X/Mathematica-128.png


################## install desktops #########################
########## Openbox Installation ################3
$ sudo apt-get install openbox  gtk-theme-switch  lxpanel obconf   menu

$ sudo apt-get install gdm

$ sudo apt-get install fbpanel  (Optional)

$ sudo apt-get install conky mpd (Optional)

$ sudo apt-get install nitrogen   #用来设置桌面墙纸!
然后到 下载最新版后编译安装。

configuration
$ sudo cp -Rf /etc/xdg/openbox/ ~/.config/
$ sudo chown -Rf $USERNAME:USERGROUP $HOME/.config/openbox
$ cd ~/.config/openbox
Then you can see three files named:
autostart.sh  menu.xml    rc.xml
You can edit them for the configuration.

$ sudo install gnome-terminal gedit

############### other Desktops ################

Start user manager
$ sudo users-admin    #This command can be found after installed package "gnome-system-tools", which can be installed by
$ sudo apt-get install gnome-system-tools






$ sudo apt-get install gnome-audio
%
阅读(1992) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~