tag:blogger.com,1999:blog-79828842008-07-17T07:06:26.911+08:00Li Zhao's HomepageLi-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comBlogger171125tag:blogger.com,1999:blog-7982884.post-58783241025736293082008-05-10T21:52:00.000+08:002008-05-10T21:54:22.027+08:00Google services down in Singapore?Nothing special is at this weekend, but I cannot access google services (google search, google reader, etc.) today.
<br/>
It's funny that I must revert to yahoo/msn to do search.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-13853307168303750822007-11-15T15:30:00.000+08:002007-11-15T15:50:29.031+08:00Maemo Mapper 2 for n770Maemo mapper 2 supports 770, and can download map easily.
I am staying in Singapore, and the map I downloaded includes:
1. 1'28"04.66N/103'41"10.47E to 1'17"48.99N/103'52"04.18E
2. 1'25"29.74N/103'52"04.18E to 1'17"48.99N/103'58"57.12E
3. 1'17"48.99N/103'44"37.56E to 1'14"20.82N/103'54"15.55E
These areas does not cover whole Singapore, but should be more than enough for me.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-86642577268139765222007-11-10T17:24:00.000+08:002007-11-10T17:36:02.780+08:00N810 application is accepted<a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://www.mobilewhack.com/nokia-n810-internet-tablet.jpg"><img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px;" src="http://www.mobilewhack.com/nokia-n810-internet-tablet.jpg" border="0" alt="" /></a>
I found the email when I got up this afternoon, :D, and so glad that I haven't read the news from maemo news Web site. Otherwise, I might think my application hasn't be accepted.
<br/><br/>
For sure, it's a great deal to buy such an amazing gadgets with 99Euro, and what also makes me happy is maemo thank contributors in this way.
<br/><br/>
Thanks, maemo.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-89872975339583068802007-09-20T12:44:00.000+08:002007-09-20T13:07:31.380+08:00How to create a blogger feed for a given categoryBlogger publish ATOM feed for recent posts by default, including posts from all categories.
<br/>
To publish a feed with only posts from a given category is also very simple. For example, in a blogger site http://blog.lizhao.net/ with category named 'maemo', the feed is:
<br/>
http://blog.lizhao.net/feeds/posts/default/-/maemo
<br/>
For more discussion about the format, plz refer to <a href="http://groups.google.com/group/bloggerDev/browse_thread/thread/9dc569c0ca720319/b19a7c0ba31ba697?#b19a7c0ba31ba697">another article</a>Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-64220410469034790172007-09-17T14:36:00.000+08:002007-09-20T12:40:05.048+08:00make minimo maemo more stableMicorB for ITOS2007HE may be on the way, but who knows when will it finally arrive. Based on the waiting experience, I decided to reinstall minimo, while waiting it.
<br/><br/>
When I tried minino 1 mth ago, it is not stable on 770, but I also heard if increase memory buffer size, it can perform much better. So, I try to set the buffer size to 4096 or 8192, according to <a href="http://kb.mozillazine.org/Browser.cache.memory.capacity">mozilla site</a>.
<br/><br/>
On 770, just run: vi /home/user/.mozilla/minimo/prefs.js and add one line:<br/>
user_pref("browser.cache.memory.capacity", 8192);
<br/>
trying google calendar/reader/gmail for a while, yea, it is much more stable, but an annoying bug is still there.
<br/>
I feel if there is unknown errors happened in rendering a page, the corresponding tab can not be closed, or refresh, and it will affect other tabs.
<br/>
If anybody know how to solve this, plz tell me. :-)
<br/>
try: user_pref("network.http.max-connections", 8); and user_pref("network.http.max-connections-per-server", 4);Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-45547971136595919462007-09-17T10:05:00.000+08:002007-09-20T12:40:05.048+08:00Display Icon in Maemo Application ManagerAfter making a deb package for maemo platform, and depolying it to a repository recognized by Maemo application manager, it is valuable to let application manager display a interesting icon beside the package name.
<BR/><BR/>
There are several points need to note:
<BR/><BR/>
<ol><li>encode a 26x26 png image into base64 format, this can be done by: uuencode -m xxx_26x26.png /dev/stdout . Then the encoded texts (between the 1st and the last line) will be used in package.</li><li>embed the texts into debian/control, in a section named: XB-Maemo-Icon-26. There must be a space before each line in this section.</li><li>run dpkg-scanpackages to generate Packages.gz, and make sure the XB-Maemo-Icon-26 section is also copied into Packages.gz</li></ol>Actually, application manager display icon based on the base64 data found in Packages.gz.
<BR/><BR/>
However, I found dpkg-scanpackages of some versions dismiss the icon section. For these versions, here is the workaround:
<BR/><BR/>
change:
<BR/><BR/>
<code>
dpkg-scanpackages ....... > .../Packages.gz
</code>
<BR/><BR/>
to:
<BR/><BR/>
<code>
dpkg_scanpackages="/tmp/dpkg_scanpackages-$$"<BR/>
cat $BIN_SCANPACKAGES | $BIN_SED -e "s/('Package',/('Package', 'Maemo-Icon-26',/" > $dpkg_scanpackages #this is for dpkg-scanpackage 1.3<BR/>
cat $dpkg_scanpackages | $BIN_SED -e "s/Size MD5sum Section Priority Description))/Size MD5sum Section Priority Description Maemo-Icon-26))/" > $dpkg_scanpackages #this is for dpkg-scanpackage 1.4<BR/>
chmod 755 $dpkg_scanpackages<BR/>
<BR/>
$dpkg_scanpackages ....... > .../Packages.gz
</code>Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-55279347558897396572007-09-03T12:39:00.000+08:002007-09-03T12:43:56.938+08:00Free Video Converter for Home DVD playerMost DVD players sold today have DivX support, I think. So, it is a good choice to convert videos to DivX and enjoy thems in sofa.
<br/><br/>
The free version of <a href="http://www.any-video-converter.com/download/">any video converter</a> do the job quite well.
<br/><br/>
You may want to test the video converted with <a href="http://www.divx.com/divx/windows/">DivX Player</a> before burning CDs.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-81340645697689974962007-08-20T10:32:00.000+08:002007-09-20T12:40:05.049+08:00SDCV for Nokia Internet Tabletsdcv is a lightweight console version of StarDict dictionary.
<br/>
<b>Now, sdcv for maemo has a simple GUI, which can speak words, and this page is depreciated! plz visit http://sdcv.garage.maemo.org/</b>
<br/>
<h2>Releases</h2>
<br/>
For all releases, please download at <a href="https://garage.maemo.org/projects/sdcv">its maemo garage project site</a>
<h2>Usage</h2>
After install, please execute sdcv from console (osso-xterm). type "sdcv --help" for details.<br/>
Please goto <a href="http://stardict.sourceforge.net/Dictionaries.php">stardict dictonary page</a> to download dictionaries, and install following its instruction.
<h2>Changes</h2>
Version 0.4.2-2
<br/>
Minor bug fix based on the same version of ubuntuLi-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-70218015131085124552007-08-16T22:18:00.000+08:002007-09-20T12:40:05.049+08:00Dictionary for Nokia Internet Tablet N770/N800We have two GUI dictionary tools for N770/N800 (or ITOS 2007, or maemo 3.1/3.2) --- stardict and sdictviewer.
<br/><br/>
sdictviewer is based on python, and runs slowly on the slow devices. It even takes several seconds to search a word. I also prefer dictionaries provided by stardict.
<br/><br/>
However, stardict.garage.maemo.org hasn't release anything so far. I tried a version compiled by a friend, and found it is slow too. What even worse is lots of bugs cause it always crash on 770 with 2007 HE.
<br/><br/>
So, the command line version of stardict may be a good alternative. The latest source deb from ubuntu can be compiled on maemo development environment (scratchbox), without any change.
<br/><br/>
The problem is the compiled binary can be executed on scratchbox smoothly, but crashs on 770 device. I spend hours to figure out the bugs, and now it works great on 770 device.
<br/><br/>
So, it should be good idea to share the patch. A new project at garage.maemo.org is opened, named sdcv (StarDictCommandVersion). Source and binary will be uploaded soon. <a href="http://act.lizhao.net/sdcv/">Welcome to test it on both 770 and 800.</a>Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-83565163192493166662007-08-07T14:09:00.000+08:002007-09-20T12:40:05.049+08:00sdcv on 770/800 (ITOS 2007)In <a href="http://blog.lizhao.net/2007/06/how-to-cross-platform-compile-stardict.html">previous article</a>, we give stardict as an example to compile deb package on ITOS2007 platform. However, after trying stardict, I found it is slow and bug-full on my 770.
<br/><br/>
So, I decide to use the text mode version of stardict -- sdcv.
<br/><br/>
It is relative easier to build sdcv than stardict, as it does not need support of GUI libs, therefore, no need to change config files for automake tools.
<br/><br/>
The trouble I met is to install libglib2.0-dev on my scratchbox, as it need pkg-config package. Downloading libglib deb and forcing dpkg to install it can bypass this problem.
<br/><br/>
another problem is the config of libreadline, I do not bother to study into config file, and just replaced all @libreadline@ with -lreadline.
<br/><br/>
Now, you can download the <a href="http://act.lizhao.net/sdcv/">deb package.</a>Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-56596745959238086832007-07-25T14:25:00.000+08:002007-09-20T12:40:05.049+08:00Nokia N770: ITOS2007 HE MK2I decided to get a Nokia internet tablet, when I found the basic Chinese support works.
Last week, I got 2 Nokia n770 instead of n800 for my wife and me, as I can not reject the price ($250 for 2). IMHO, I also prefer its design to N800. Actually my wife love it as soon as she got it, although she does not want a tablet at all before that. It can save her much effort to bring slides, books or laptop, while the screen size is acceptable.
From maemo.org/news, we know N800 will get support for next two version of maemo, while N770 has no support for even ITOS2007. It's OK. As the hacker edition (HE) of ITOS2007 works great. maemo news also announces a new hacker edition will come soon. But I decide that I had better to install ITOS2007 HE MK2 on 770, other than just waiting the new version.
This article lists what I did on the 770, for future reference. It is only for ITOS2007 HE MK2. For a new comer, it is good to start from
<ol><li>http://maemo.org/community/wiki/howto/ (general problem)
</li><li>http://www.internettablettalk.com/forums/ (ask question)
</li><li>http://maemo.org/downloads (install software)
</li><li>http://guoyong.org (CJK support)</li></ol> <h2> Flash ITOS2007 to 770</h2>In office, I use Windows, so, need to download the exe from http://www.nokia.com/A4144790, install it and then follow its simple wizard.
In home, on Ubuntu, just follow <a href="http://maemo.org/community/wiki/howto_flashlatestnokiaimagewithlinux/" class="wikipage default" title="/HOWTO FlashLatestNokiaImageWithLinux">Flash the latest Nokia image to your Nokia 770/800 device with Linux</a> from maemo wiki.
<h2>Install becomeroot, xterm</h2>This step is prerequirement for other operations, as it allow me to become root user. Please follow <a title="maemo wiki." href="http://maemo.org/community/wiki/howto_easily_becomeroot/">maemo wiki.</a>
<h2>Partition of MMC</h2>I bought 2G MMC Mobile card for the gadget. ITOS2007 requires the 1st partition of the MMC is vfat format. If we want to install OS into the MMC, I guess we need a ext2 partition it. So, it is time to do partition.
The vfat partition can be recognized by Windows when connect with USB cable. So, it is convenient to share files using this partition. I think 950M is enough for it (virtual memory file is also on it). Please follow <a title="maemo wiki" href="http://maemo.org/community/wiki/howto_easily_partition_your_mmc_card/">maemo wiki</a> to do the partition, and the following texts are parameters I use:
<pre>/dev/mmcblk0p1:1,30000,6
/dev/mmcblk0p2:30001,,</pre>PS: The largest swap file ITOS2007 can manage is 64M, sb. says we can use swap partition larger than 60M, however, I failed.
<h2> Install dual boot menu for 770</h2>With the ext2 partition on MMC, we can install OS on it. The basic idea is copy the OS in flash into MMC and then generate a dual boot menu when tablet starts. Thank <a class="bigusername" href="http://www.internettablettalk.com/forums/member.php?u=1382">fanoush</a>, it is easy. Please follow <a title="maemo wiki." href="http://maemo.org/community/wiki/howto_easily_boot_from_mmc_card/">maemo wiki.</a> If want to set default OS to the one in MMC, we need to modify bootmenu.conf before install the dual boot menu.
Please do:
<pre># cp bootmenu.conf.n800.example bootmenu.conf
# vi bootmenu.conf
</pre>change the parameters in bootmenu.conf, and then install.
<h2>Duplicate OS from flash to MMC</h2>After reboot, it is time to copy OS. Please follow rear part of <a title="maemo wiki." href="http://maemo.org/community/wiki/howto_easily_boot_from_mmc_card/">maemo wiki</a> to do it.
<h2>Patch kernel for fast MMC access</h2> By default, ITOS2007 kernel only support low speed of MMC card. Sb. say the reason may be high speed can cause shorter life of the card. Who care when we have lifetime warranty for the card? It is dangerous to do the patch before following <a title="maemo wiki." href="http://maemo.org/community/wiki/howto_easily_boot_from_mmc_card/">maemo wiki</a> to copy OS into MMC, as I failed to copy OS with the patch.
Please follow <a class="bigusername" href="http://www.internettablettalk.com/forums/member.php?u=7416">weezedog</a>'s <a title="step by step guide" href="http://www.internettablettalk.com/forums/showthread.php?t=7342&highlight=2007+770">step by step guide</a> to do the patch.
<h2>Install Chinese support</h2>Please goto <a title="maemocjk Web site" href="http://maemocjk.garage.maemo.org/install.html">maemocjk Web site</a> to install it.
<h2>Install Minimo</h2>Opera come with 770 is not compatible with lots of Web sites, and mozilla based minimo should be a better choice. Now, minimo is one-click installable from maemo.org/downloads
<h2>Conclusion</h2>
This is my 2nd time to do the procedure (as I have two). and cost about 1 hour to finish all steps. So, it is not difficult and very time consuming to improve performance of the gadget. I just suggest do not install other software before duplicating OS successfully, as sb. reported failure after that.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-62418774897409461822007-06-30T12:27:00.000+08:002007-09-20T12:40:05.049+08:00How to cross-platform compile stardict for Nokia N770I am still staying in S'pore, where Nokia just begin n800 trial session, and the unknown date to sell. Last week, I booked a N800 from Amazon and my wife will goto US to pick up it for me.
Interesting, the second day woot promoted Nokia N770 at $130. Wow, what price!
So, canceled the 800 and I booked two 770 for my wife and me. What even more interesting is I found online shop all around the world begin to promote the N770, and <a href="http://www.expansys.com.sg/p.aspx?i=141019">expansys</a> even deliver to S'pore with lower price.
It's OK. The reason I love Nokia internet tablets is they are using Linux as OS, so that I can compile software I am interested in.
Although I can only get the 770 next mth, I can not resist to do sth. for it. Due to my native language (Chinese), I think a good dictionary is a good startpoint. <a href="http://www.blogger.com/guoyong.org">Guoyong</a> has write a <a href="http://guoyong.org/2007/04/20/316">brief description</a> of how to compile it.
It's a great article, however, for a beginner, more details may be better. So, I add several points here.
<ol><li><span style="font-weight: bold;">install cross-platform environment (scratchbox): </span>please follow the instruction to install scratchbox (<a href="http://maemo.org/development/sdks/maemo-3-x--bora-.html">here</a>)
</li><li><span style="font-weight: bold;">adjust auto build tools in scratchbox:</span> please refer to <a href="http://maemo.org/development/documentation/how-tos/3-x/howto_porting_to_maemo_bora.html">this article</a> to add a exectuable script autogen.sh into scratchbox.
</li><li><span style="font-weight: bold;">download a proper stardict source deb package: </span>the reason to download a PROPER version of stardict is that the latest version need more dependences unsupported on the tablet. It's OK to use older version, as the new eye candy is not very important for me. We can get 2.4.5 from <a href="http://packages.ubuntu.com/">http://packages.ubuntu.com/</a>.
</li><li>unpackage the source deb and apply patch: after download <a href="http://archive.ubuntu.com/ubuntu/pool/universe/s/stardict/stardict_2.4.5-1.1.dsc">[dsc]</a> <a href="http://archive.ubuntu.com/ubuntu/pool/universe/s/stardict/stardict_2.4.5.orig.tar.gz">[stardict_2.4.5.orig.tar.gz]</a> <a href="http://archive.ubuntu.com/ubuntu/pool/universe/s/stardict/stardict_2.4.5-1.1.diff.gz">[stardict_2.4.5-1.1.diff.gz]</a>, untar orig.tar.gz and zcat ../<a href="http://archive.ubuntu.com/ubuntu/pool/universe/s/stardict/stardict_2.4.5-1.1.diff.gz">stardict_2.4.5-1.1.diff.gz</a> | patch -p1 </li><li>modify configure.in in the source to disable some dependences unsupported on scratchbox</li><li>modify debian/rules and debian/control in source to help debian package build system work</li><li>dpkg-buildpackage</li></ol>Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-75144564741792676982007-06-21T23:21:00.000+08:002007-06-21T23:35:31.086+08:00Shining flash of wordnetsWhen I was writing papers, choices of words always cause troubles for me, whose native language is not English. WordNets can help me much.
<br/>
<br/>
Of cause, WordNets' use is not limited to this scenario. Many guys love this tool, and if you are one of them, I guess you must like <a href="http://www.visuwords.com">Visuwords</a>
<br/>
<br/>
Visuwords presents a flash visual interface to wordnets, which can attract your eyes quickly. Now, we do not need to click the dropdown list many times to see synonyms, hypernyms, hyponyms, meronyms, and holonyms of a word.
<br/>
<br/>
If I get more free time in near future, I may try to integrate Visuwords with stardict.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-89780883518392479082007-05-22T10:57:00.000+08:002007-05-22T11:05:47.593+08:00Alternatives to EndNotesWithout reference management software, writing long papers sometimes can end as a disaster. As I was used to write paper using latex, it is not a problem util now when I need to write in MS Word.
<br/><br/>
OK, I know EndNotes is the de-facto standard for Word to manage references, but it is a bit expensive.
<br/><br/>
Fornunately, there are free/opensource alternatives we can use, please refer to http://en.wikipedia.org/wiki/Comparison_of_reference_management_software for more info.
<br/><br/>
I tried Zotero with Word, and found it is so convenient, although it supports a few reference/citation styles. But that's enough for me so far.
<br/><br/>
Hope it keep going and supports more features.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-69522286020289861082007-04-22T12:17:00.000+08:002007-04-23T10:14:12.758+08:00sopcast to NBA<a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://bp2.blogger.com/_RSEOLRZx9vc/RirnGKuSQxI/AAAAAAAAAB0/V5T73Ek07_c/s1600-h/IMG_0996.JPG"><img style="margin: 0pt 0pt 10px 10px; float: right; cursor: pointer;" src="http://bp2.blogger.com/_RSEOLRZx9vc/RirnGKuSQxI/AAAAAAAAAB0/V5T73Ek07_c/s400/IMG_0996.JPG" alt="" id="BLOGGER_PHOTO_ID_5056107624820523794" border="0" /></a>
I must stay in home today to wait a cleaner, our home is so dirty now.
<br/><br/>
While I was so boring that I wander around to find anything interesting to do, I recalled today is the first game in the series of houston VS. utan.
<br/><br/><br/><br/><br/><br/><br/>
<a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://bp2.blogger.com/_RSEOLRZx9vc/RirikKuSQwI/AAAAAAAAABs/qiHJwSMvPDQ/s1600-h/IMG_0995.JPG"><img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer;" src="http://bp2.blogger.com/_RSEOLRZx9vc/RirikKuSQwI/AAAAAAAAABs/qiHJwSMvPDQ/s400/IMG_0995.JPG" alt="" id="BLOGGER_PHOTO_ID_5056102642658460418" border="0" /></a>
I haven't subscribed any sports channel like ESPN, so the only chance is to try whether those P2P network TV can work.
<br/><br/>
I downloaded sopcast and installed its GUI gsopcast on my kubuntu.
<br/><br/>
So great that free China sports channels are broadcasting this game and can play smoothly using sopcast.
What even better is the result. :-DLi-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-21468777394527832592007-04-15T12:41:00.000+08:002007-04-15T12:52:32.080+08:00How to print duplex pages using Brother DCP-115CIt is not convenient to print duplex pages on Brother DCP-115C, here gives the tips.
<ul><li>Print duplex, long edge:</li></ul><ol><li>print odd pages, with reverse order</li><li>remove the printed papers from output tray</li><li>rotate the papers 180'C</li><li>insert the papers to input tray</li><li>print even pages</li></ol><ul><li>Print duplex, short edge</li></ul><ol><li>print odd pages, with reverse order</li><li>remove the printed papers from output tray
</li><li>insert the printed papers to input tray</li><li>print even pages</li></ol>
For word, the print dialog may have no options to print odd/even pages, so:
<ul><li>Word's extra setting to print odd pages in reverse order
</li></ul><ol><li>check manual duplex option</li><li>click option button in print dialog, to open option dialog</li><li>check the front side box</li></ol>Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-52800310314763468772007-04-13T14:10:00.000+08:002007-04-13T14:46:39.941+08:00How to remove annoying location auto-detection by GoogleIf you are in some countries, when you search in Google, it may auto-redirect you to search results specified according to your location. For example, if you are in Hongkong, Google will automatically search from google.com.uk, which is undesired for many of us.
<br/><br/>
I just submitted a search plugin to Firefox community, you can install it to avoid Google to do that, i.e., it always search from google.com.
<br/><br/>
Please search "Li, Zhao", and install the plugin with id=16536 (when mouse move over, the ID will display) from:<br/>
<a href="http://mycroft.mozdev.org/download.html?name=google&category=all&country=all&language=all&submitform=Search&sherlock=yes&opensearch=yes&skipcache=yes">all google's search plugins</a><br/>Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-89090598442553413062007-04-09T11:22:00.000+08:002007-04-09T11:48:34.775+08:00startup vnc server automatically with xdmYou may expect a xdm will display when you open a vnc viewer to a server, there are at least two benefits:
<ol><li>no need vnc to maintain its own password</li><li>automatically start vnc service</li></ol>There are some links you can follow to set as you desired:
<ul><li>http://ubuntuforums.org/showthread.php?t=259448</li><li>http://www.oreilly.com/catalog/morelnxsvrhks/chapter/hack13.pdf</li><li>http://gentoo-wiki.com/HOWTO_RealVNC,_TightVNC,_XF4VNC</li></ul>I am using kubuntu 7.04, and found some gtk applications always complain vnc4server, for reasons such as xinputextension is missed, or 109 erros (I do not know what's these). But tightvncserver works well. So, I choose tightvnc, and my /etc/xinet.d/vnc is:<br/><br/>
<code>
<span style="color: rgb(51, 51, 153);">{</span><br/>
<span style="color: rgb(51, 51, 153);"> socket_type = stream</span><br/>
<span style="color: rgb(51, 51, 153);"> protocol = tcp</span><br/>
<span style="color: rgb(51, 51, 153);"> wait = no</span><br/>
<span style="color: rgb(51, 51, 153);"> user = nobody</span><br/>
<span style="color: rgb(51, 51, 153);"> server = /usr/bin/Xvnc</span><br/>
<span style="color: rgb(51, 51, 153);"> server_args = -inetd -ac -query localhost -once -geometry 1300x900 -depth 16</span><br/>
<span style="color: rgb(51, 51, 153);">}
</span><br/></code>
<span style="color: rgb(0, 0, 0);">The reason to use 16 depth instead of 8 is eclipse cannot run on 256 colors.</span>Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-6801824610107583072007-03-11T22:37:00.000+08:002007-03-12T10:33:14.517+08:00How to install chinese fonts for Damn Small Linux DSL 中文支持I have a very old laptop with PII 300Mhz CPU. I managed to install Gentoo Linux before, but seldom use it. Today, When I was cleaning my desktop, found it, but I forgot almost everything about Gentoo when I want to install sth.
<br/>
It is burdonsome to install anything on such a old Gentoo box, so, it is the time shift to a light Linux distribution, such as DSL and puppy.
<br/>
After spend 10mins to download DSL 3.3 RC2, it bootup the PII in 1 min. Wow, it really rocks on my ancient machine. Unfortunately, it does not support Chinese. However, by studying mydslPanel (the tools to install software on DSL) for half an hour, my Firefox can display Chinese fonts properly already.
<br/>
To install chinese fonts, please do:
<br/>
<ol> <li>Install japanese-fonts using mydslPanel on desktop, it will download japanese-fonts.tar.gz to /tmp by default.</li> <li>copy /tmp/usr /usr</li> <li>copy some fonts file from another Linux system supporting Chinese. I am running Ubuntu on another laptop, so, I copy all /usr/share/fonts/X11/misc/* from the Ubuntu to /usr/X11R6/lib/X11/fonts/misc</li> <li>run /usr/bin/japanese-install.sh</li> </ol> Now, your DSL is chinese-awared.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-65583418113953069412007-03-04T14:42:00.000+08:002007-03-04T14:53:42.662+08:00JAVA Chinese fonts on UbuntuThese days, I am trying to write a crossplatform tools (https://sourceforge.net/projects/bloghub) using JAVA, on a Kubuntu laptop. Although I expected that Linux JAVA chinese support could be much better than 5 years, when I use JAVA to do development, I am so disappointed that my JAVA system just show all Chinese characters as blank boxes.
<br/><br/>
Fortunately, the solution is quite simple:
<br/>
<ol><li>Search where is your system chinese fonts are, e.g., I use simhei&simsun from M$, at /usr/local/share/fonts.</li><li>cd $JAVA_HOME/jre/lib/fonts</li><li>ln -s /usr/local/share/fonts fallback</li></ol>Is it simple? Sure we can adjust the fonts to display better, but that's enough for me. Good luck!Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-56969513906633051892007-02-12T18:10:00.000+08:002007-02-13T15:29:42.898+08:00Layout UpgradedMy blog finally moved to new blogger now, with brandnew layout. It is good, considering it hasn't been changed for several years.
Another reason to immigrate is I have no time to maintain some features I implemented based on old blogger system, while new blogger provides some attractive ones.
I must say sorry to buddies who are using blogcat services, as it is out of work now.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-64982301315918680132007-01-02T15:19:00.000+08:002007-02-12T15:06:26.044+08:008-steps home-made rice winePre-requisites:
<ol> <li> 糯米 1公斤 glutinous rice 1kg<img src="http://docs.google.com/File?id=dg45b27v_9ctnnnd" style="height: 139px; width: 186px;" title="glutinous rice in bag" /> </li> <li> 甜酒曲 (注意不要是用烧酒曲)yeast for glutinous rice wine<img src="http://docs.google.com/File?id=dg45b27v_4fkg63k" style="height: 94px; width: 126px;" title="yeast for rice wine" /> </li> <li> 高压锅 autoclave </li> <li> 蒸笼 steam box </li> <li> 2.7升大玻璃罐 (或者搪瓷缸)2.7L large glass jug (or enamel jug) </li> </ol>
Steps:
<ol> <li> <span style="font-family:宋体;font-size:85%;"> 浸米[米洗净后用自来水泡一夜];</span> </li> <li> <span style="font-family:宋体;font-size:85%;"> 滤米<wbr>: 把泡好的米,倒在有小孔的盆(漏盆)内,滤水半个小时</span><img src="http://docs.google.com/File?id=dg45b27v_5ck827n" style="height: 210px; width: 279px;" title="soaked rice" /> </li> <li> <span style="font-family:宋体;font-size:85%;"> 蒸米: 将白纱布洗湿后<wbr>,再垫在蒸笼内放入高压锅,把米倒在纱布上(在米上用筷子戳几个孔<wbr>,米熟得快),用高压锅压,待高压锅盖子上气孔发出响声后15分钟关火:</span><img src="http://docs.google.com/File?id=dg45b27v_6fxfc66" style="height: 228px; width: 303px;" title="rice in pot" /> </li> <li> <span style="font-family:宋体;font-size:85%;"> 过水: <wbr>[把糯米饭倒在漏盆内,用筷子把饭团拨开,米饭不能成团粘在–起<wbr>,这很重要!要让每粒米饭,都能冲到自来水];</span><img src="http://docs.google.com/File?id=dg45b27v_7fkk6vb" style="height: 204px; width: 295px;" title="cool rice" /> </li> <li> <span style="font-family:宋体;font-size:85%;"> 滤水:[把冲好自来水的米饭,放在漏盆中滤水<wbr>,一定要滤干!否则糯米饭会变质!需4个小时以上<wbr>!很重要。];</span><img src="http://docs.google.com/File?id=dg45b27v_10czkmxf" style="height: 129px; width: 172px;" title="filter water" /> </li> <li> <span style="font-family:宋体;font-size:85%;"> 拌酒曲:[把米饭倒在玻璃罐(1kg糯米可放于2.7升罐内,IKEA有卖),边撒酒</span><span style="font-family:宋体;font-size:85%;">曲</span><span style="font-family:宋体;font-size:85%;">边搅拌<wbr>,让饭上有曲就可以了,拌均匀更好。再把米饭拍平、拍紧<wbr>,这样可以更好和酒曲发酵,再在米饭中间开一个圆形的洞<wbr>,并在米饭的平面上、洞内都撒一些酒曲];</span><img src="http://docs.google.com/File?id=dg45b27v_11fvsxqf" style="height: 225px; width: 299px;" title="mix yeast with rice" /> </li> <li> <span style="font-family:宋体;font-size:85%;">盖严玻璃罐并密封:[在28度气温下2天以后再打开看一下,如酒汁已经超过玻璃罐一半高度<wbr>,就再把米饭再翻动; 再过一天<wbr>,酒味就会纯、更甜、酒汁也更多的];</span><img src="http://docs.google.com/File?id=dg45b27v_12dnc3s8" style="height: 580px; width: 509px;" title="rice in glass jug" /> </li> <li> <span style="font-family:宋体;font-size:85%;">保存: 只需保持玻璃罐密封即可 (如果一直放于28度室温下,酒将持续发酵,逐渐趋于烧酒口味; 如果要停止发酵,可将罐至于冰箱内)。</span> </li> </ol>Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-40443672905059872002006-11-21T09:26:00.000+08:002006-11-21T09:32:13.512+08:00More online bookmark service is here nowIn a <a href="http://blog.lizhao.net/2005/08/softwarerec-online-bookmark.html">previous post</a>, I introduced an online bookmark service, which allow you to store your bookmark online and then synchronize it among several computers. I encountered some bugs when I use this service, such as browser hangs if service is down (frequently).
But now, there are much more similar service available for our choice.
<ol><li><a href="http://del.icio.us/">del.icio.us</a></li><li> <a href="http://www.google.com/tools/firefox/browsersync/">Google Browser Sync</a></li><li><a href="http://www.foxmarks.com/">Foxmarks</a></li><li><a href="https://www.chipmark.com/Main">Clipmark</a> </li></ol>I am trying del.icio.us from yahoo, which can tag your bookmark instead of organizing in different folder.Li-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-1162868991936028762006-11-07T10:33:00.000+08:002006-11-14T16:11:38.229+08:00Desktop Search for Source AnalysisNow, there are always Gigas source codes for me to pass. Without source analysis tools like source insight or source navigator, it really can be a big trouble sometimes.
<br/>
<br/>
Unfortunately, source insight is a bit expensive to deploy into all my PCs. On the freeware side, source navigator does not support c# so far (even worse, it failed several times when I try to add Gigas c++ files to a project).
<br/>
<br/>
Consider that the main feature I use in source insight is to search reference, caller, definition, etc. of a given entity, can we use a desktop search engine to do these work. Of cause, we stand a little chance to get such a desktop search engine.
<br/>
<br/>
But after I tried some engines, I feel they can help much, when I have no source insight installed. What's better is they usually do search much faster than source insight.
<br/>
<br/>
There are lots desktop search engine today. I have no time to try them all. So, I selected three for reference.
<LI>Microsoft Index Services (MIS)
<LI>Google Desktop Search (GDS)
<LI>Copernic Desktop Search (CDS)
<br/>
<br/>
As MIS is integrated in windows, it is attractive that I donnot need to download and install anything, if it can be used. But I found it is slow, in terms of both indexing and searching. BTW: I use a wiki system based on MIS --- Perspective Wiki.
<br/>
<br/>
Then I tried GDS, it provides search interface integrated into google search page. Maybe it is attractive for thoese google fans, but I guess they will be disappeared when they found GDS almost cannot refine search result, difficult to configure search for each folder, etc.
<br/>
<br/>
After some googling, I found CDS. Its rate is quick good in some reviews. Another reason I select it is I recalled that I used to use another search product from Copernic around 2000. :-)
<br/>
<br/>
Based on 1 hour experience, I think CDS is quite good for me to analyze source codes. It can easily start search inside a folder, restrict file name, date in a standalone native program.
<br/>
<br/>
Maybe we can improve source navigator based on these open source desktop search enigne? :-DLi-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.comtag:blogger.com,1999:blog-7982884.post-1162448671964665332006-11-02T14:17:00.000+08:002006-11-14T16:11:38.125+08:00SciTE --- Firefox of text editorSciTE is a light-weight, cross-platform, fast text editor I always use. For example, on windows platform, it can be a single exe file you can copy to anywhere you like, and smaller than 500k, which is much smaller than editplus and ultraedit.
<br/><br/>
Despite of its small size, it is highly configurable, there are menu items to edit its default properties, e.g., whether to show line number, where to wrap long line, etc.
<br/> <br/>
For example, the following four lines make scite wrap and show line num automatically, and prompt a user to reload a file when the file is changed out of scite.<br/>
wrap=1<br/>
line.margin.visible=1<br/>
load.on.activate=1<br/>
are.you.sure.on.reload=1<br/>
For more documents, please refer to http://www.scintilla.org/SciTEDoc.htmlLi-Zhao 李钊http://www.blogger.com/profile/08007907669125875950noreply@blogger.com