Sunday, August 30, 2009

speed up video card of T41

Mine is radeon M7500.
And in my xorg.conf, I have:
-------------------------------------------
Section "Device"
Identifier "Configured Video Device"
Boardname "ATI Radeon"
Busid "PCI:1:0:0"
Driver "radeon"
Screen 0
Vendorname "ATI"
Option "MergedFB" "off"
Option "AccelMethod" "EXA"
Option "EXANoComposite" "false"
Option "AGPFastWrite" "On"
Option "FBTexPercent" "50"
Option "MigrationHeuristic" "greedy" # the most effective option
Option "DRI" "true"
Option "GARTSize" "256"
Option "AGPMode" "4"
Option "Colortiling" "On"
EndSection
-------------------------------------------

Saturday, August 15, 2009

ubuntu 256 bit color urxvt (from internet)

Steps used to recompile urxvt with the 256 bit color patch.
$ apt-get source rxvt-unicode
$ sudo apt-get build-dep rxvt-unicode
$ cd rxvt-unicode*
$ patch -p1 < doc/urxvt-8.2-256color.patch
$ sudo dpkg-buildpackage -us -uc
$ sudo dpkg -i rxvt-unicode_9.05-4_i386.deb
$ echo "rxvt-unicode hold" | sudo dpkg --set-selections
in your .Xdefaults file, type: rxvt.termName=xterm, so that most ssh to other machine will support 256 color.

The last step makes sure apt doesn't reinstall the old package the next time you update.

Friday, August 14, 2009

opera keyboard issues

I found that sometime my keyboard didn't respond in opera. I can get this fixed by start a terminal and close it, then my keyboard come back.
But today I found a solution.
It is caused by conflict between it and scim.
So:
sudo apt-get install scim-qtimm
sudo vim /usr/bin/opera

add "export export QT_IM_MODULE=SCIM" at second line.

restart opera and all is fine.

Thursday, August 13, 2009

Opera with Chinese font config

First, you need to have YaHei font, which I think can give you best profile when Chinese+English is showing. I even use it as the font in terminal. I think it is better than WenQuanYi.
Methods of installing YaHei is in another post of mine.

1. Tools->Preferences->advanced->fonts; all change to YaHei Consolas Hybrid.
2. type opera:config in address bar, search antialiasing and dismark it.
3. open a terminal, type:
echo 'html,body,*{font-family:"YaHei Consolas Hybrid" !important;}' > ~/.opera/styles/user/user.css
4. restart opera, view->style->user.css.
tools->preferences->general->language->details->encoding to assume...->gb18030
5. restart opera.
You will find the Chinese font is perfect.

Sunday, June 21, 2009

Chinese configure in wine

1. add wine-cn source
wget -O- 'http://keyserver.ubuntu.com:11371/pks/lookup?op=get&search=0x84DD336194625C2F' | sudo apt-key add -

echo -e "deb http://ppa.launchpad.net/wine-cn/ppa/ubuntu jaunty main\ndeb-src http://ppa.launchpad.net/wine-cn/ppa/ubuntu jaunty main" | sudo tee /etc/apt/sources.list.d/wine-cn.list


2.
sudo apt-get update
sudo apt-get install wine


3.
If you "Locale" is not zh_CN, MODIFY the command line in ~/.local/share/applications/wine-Programs-XXX.desktop TO env LANG=zh_CN.UTF-8 wine "C:\Program Files\XXX.exe" to provide Chinese support.

Saturday, June 20, 2009

Chinese font configuration in ubuntu 9.04

I prefer YaHei font, due to its good mix of Chinese and English
1. Download from http://rs54l33.rapidshare.com/files/34563809/5101584/YaHei.Consolas.1.11b.zip
2. Copy the ttf file to ~/.fonts
3. fc-cache -fv (to refresh the font list)
4. Right click on desktop -> Change Desktop Background -> Fonts. Change all to YaHei ....

Done.

Thursday, June 18, 2009

watch video in ubuntu 9.04

1. Remove totem media player.

Remove totem media player from synaptic.
sudo rm /usr/share/applications/totem.desktop

2. Install mplayer, codec and plugin for firefox

sudo apt-get install mplayer mplayer-fonts mozilla-mplayer
download all-20071007.tar.bz2 from http://www2.mplayerhq.hu/MPlayer/releases/codecs/
tar jxvf all-20071007.tar.bz2 /usr/lib/codecs/

3. Fix realplayer codec: drvc.so

sudo apt-get install libstdc++5

4. Add restricted video format

sudo apt-get install ubuntu-restricted-extras

5. Also better to do the following:

sudo wget http://www.medibuntu.org/sources.list.d/jaunty.list --output-document=/etc/apt/sources.list.d/medibuntu.list
sudo apt-get update && sudo apt-get install medibuntu-keyring && sudo apt-get update
sudo apt-get install w32codecs


Enjoy now!