ubuntu7.04的设置

来源:互联网 发布:mac程序卡住了怎么办 编辑:程序博客网 时间:2024/06/07 04:50
ubuntu7.04的设置  
[ 作者:stephen  加入时间:2007-04-30 10:31:35  来自:blog ]
   
<script type="text/javascript"><!--google_ad_client = "pub-3701573918329010";google_ad_width = 336;google_ad_height = 280;google_ad_format = "336x280_as";google_ad_type = "text_image";google_ad_channel ="";google_color_border = "F7F7F7";google_color_bg = "F7F7F7";google_color_link = "191919";google_color_text = "191919";google_color_url = "191919";//--></script> <script src="http://pagead2.googlesyndication.com/pagead/show_ads.js" type="text/javascript"></script> <iframe width="336" scrolling="no" height="280" frameborder="0" name="google_ads_frame" src="http://pagead2.googlesyndication.com/pagead/ads?client=ca-pub-3701573918329010&amp;dt=1178604018692&amp;lmt=1177900578&amp;format=336x280_as&amp;output=html&amp;url=http%3A%2F%2Fwww.xxlinux.com%2Flinux%2Farticle%2Faccidence%2Finstall%2F20070430%2F8332.html&amp;color_bg=F7F7F7&amp;color_text=191919&amp;color_link=191919&amp;color_url=191919&amp;color_border=F7F7F7&amp;ad_type=text_image&amp;ref=http%3A%2F%2Fwww.google.com%2Fsearch%3Fq%3Dubuntu%2B%25E8%25AE%25BE%25E7%25BD%25AEVIM%26ie%3Dutf-8%26oe%3Dutf-8%26aq%3Dt%26rls%3Dcom.ubuntu%3Aen-US%3Aofficial%26client%3Dfirefox-a&amp;cc=39&amp;flash=9&amp;u_h=768&amp;u_w=1024&amp;u_ah=720&amp;u_aw=1024&amp;u_cd=24&amp;u_tz=480&amp;u_his=4&amp;u_java=true&amp;u_nplug=6&amp;u_nmime=15" marginwidth="0" marginheight="0" vspace="0" hspace="0" allowtransparency="true"></iframe>
一、首先添加源,我用的这些源速度蛮不错的,可以删除掉sources.list中的所有源写入下面的源

    sudo gedit /etc/apt/sources.list

deb http://ubuntu.cn99.com/ubuntu/ feisty main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ feisty-security main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ feisty-updates main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ feisty-proposed main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ feisty-backports main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ feisty main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ feisty-security main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ feisty-updates main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ feisty-proposed main restricted universe multiverse
deb-src http://ubuntu.cn99.com/ubuntu/ feisty-backports main restricted universe multiverse


deb http://mirror.lupaworld.com/ubuntu feisty main restricted universe multiverse
deb http://mirror.lupaworld.com/ubuntu feisty-security main restricted universe multiverse
deb http://mirror.lupaworld.com/ubuntu feisty-updates main restricted universe multiverse
deb http://mirror.lupaworld.com/ubuntu feisty-backports main restricted universe multiverse
deb-src http://mirror.lupaworld.com/ubuntu feisty main restricted universe multiverse
deb-src http://mirror.lupaworld.com/ubuntu feisty-security main restricted universe multiverse
deb-src http://mirror.lupaworld.com/ubuntu feisty-updates main restricted universe multiverse
deb-src http://mirror.lupaworld.com/ubuntu feisty-backports main restricted universe multiverse cn99.com
 
    sudo apt-get update
    sudo apt-get dist-upgrade

    安装中文支持:
在 桌面工具栏的“系统-系统管理-语言支持” 里面把”Chinese”勾选上(一定要打勾,不要只是一条横线,否则中文支持不完全)。

二、安装Nvidia显卡驱
动:(第6、7、8步最好记下来,因为会切换到终端)
1. 到http://www.nvidia.com/ 下载驱动
2. 删除原来的驱动(如果你装过驱动)
sudo apt-get --purge remove nvidia-glx
3. 备份当前的显示设置,这样可以在驱动安装失败时恢复到原来的设置
sudo cp /etc/X11/xorg.conf.backup /etc/X11/xorg.conf
4. 安装驱动程序编译环境
sudo apt-get install build-essential linux-headers-`uname -r`
5. 禁止系统使用默认的驱动
sudo gedit /etc/default/linux-restricted-modules-common
在最后的双引号中添加nv,即“”改成“nv”
6. 按Ctrl+Alt+F1,登录,停止gdm
sudo /etc/init.d/gdm stop
7. 进入下载的驱动安装文件 nvidia-linux-x86-1.0-9631-pkg1.run所在目录(请确定xorg-dev软件包已经安装,编译过程中可能会用到)
sudo sh nvidia-linux-x86-*.run
如果提示缺少某某模块(modules),询问是否上网下载,选no;
8. 安装完成后,启动gdm
sudo /etc/init.d/gdm start

此时,就会看到NVIDIA的LOGO了,驱动安装成功。

对宽屏来说,此时可能需要改变分辨率,在UBUNTU中,选择菜单“应用程序”─“系统工具”─“NVIDIA X Server Settings”,进入便可以改变分辨率;
同时要修改/etc/X11/xorg.conf文件,把里面的1024x768都修改为你选择的分辨率:
sudo gedit /etc/X11/xorg.conf
打开修改就可以了。
在这两处都修改才能保证每次重新启动后分辨率不会改回到原来的1024x768.


点 击桌面工具栏的系统-首选项-桌面效果,会提示安装beryl。安装后重新启动,应用桌面效果。可以选择开启或者关闭桌面效果,也可以单独启用窗口晃动或 3D 工作区。全部窗口和状态栏都带有阴影效果,非常漂亮,真是爽呆了。(3D工作区用法:同时按Ctrl+Alt+左或者右键)
三、安装mplayer与解码器,设置中文字幕
        sudo apt-get install mplayer mozilla-mplayer totem-xine libxine-extracodecs
        sudo apt-get install gstreamer0.10-*
        wget -c http://www.debian-multimedia.org/pool/main/w/w32codecs/w32codecs_20061022-0.0_i386.deb
        sudo dpkg -i
w32codecs_20061022-0.0_i386.deb

       如果运行mplayer播放电影的时候出现以下字样而不能正常运行的时候

open: No such file or directory
[MGA] Couldn't open: /dev/mga_vid
Error opening/initializing the selected video_out (-vo) device.

 
       首先运行gmplayer,
然后在preference-video里选择xv X11/Xv就可以正常播放了。

        中文字幕设置方法:
            1) 在 Preferences-Font 里面点击 ”Browse” 选择一个中文字体,如:
                    /usr/share/fonts/truetype/arphic/uming.ttf
                Encodeing 选择 Unicode。
            2) 在 Preferences-Subtitle&OSD 里面的 Encoding 选择:
               Simplified Chinese Charset(cp936)
            3) 把 Preferences-Font 中的“Text scale”调整为3.8,默认字幕太大了。

四、安装配置vim
       1、安装vim
            sudo apt-get install vim
       2、配置文件
           在用户家目录下建立.vimrc文件
               cd; gedit .vimrc
          写入以下内容:
set nocompatible
set hlsearch

if !exists("syntax_on")
syntax on
endif

"设置tab字符个数
set tabstop=4
set shiftwidth=4
"自动缩进
set autoindent
"更方便的退格键
set backspace=2

"自动检测文件类型
filetype on

"配色文件
colorscheme desert

"字体
if (has("gui_running"))
set guifont=Bitstream/ Vera/ Sans/ Mono/ 10
endif

"----------------below for txt file
"让文本文件也有高亮,thanks to xbeta@smth
augroup filetypedetect
au BufNewFile,BufRead *.* setf ztxt
augroup END

"缓冲区写入文件的时候自动检查文件类型
au BufWritePost * filet detect

"设定文件编码类型,彻底解决中文编码问题
let &termencoding=&encoding
set fileencodings=utf-8,gbk,ucs-bom,cp936


五、安装星际译王stardict
        sudo apt-get install stardict

        到
http: //stardict.sourceforge.net/Dictionaries.php下载词典,因为我需要用英汉和汉英词典,所以下载的是 http://stardict.sourceforge.net/Dictionaries_zh_CN.php页面中推荐的那几个词典以及计算机词 汇。
        解压为每个辞典一个目录,把词典目录放到/usr/share/stardict/dic中,启动stardict就可。
Linux联盟收集整理
 
原创粉丝点击