2009/06/11

The long way to port my onlinedic on Android platform

P5045763 (by plateaukao)
Cannes.France

坎城除了大家比較熟悉的海邊的星光大道外,
其實在車站的另一個方向有個舊城區。

跟海邊的人潮比起來,
這兒顯得寧靜許多(不過沒有上空美女就是了。
看著清一色的橘紅色屋頂和遠方的山水,晒著不會太炙熱的陽光,
這兒真的很適合度假。
難怪在Bienvenue chez les Chi'tis裡的那個老婆,那麼想要搬到法國南部;
而在南法,特地搬來這兒住的英國人也是屬一屬二多的。

****

After glancing through the basic documents of Android SDK, I still have a lot of work to do before porting my onlinedic to this platform:

1. Find the UI components that I need:
1.1 EditControl
1.2 Button (for start searching)
1.3 HTML viewer
2. How to create and use its menu
3. Find the component to open http requests
4. Find the component to post-process the received html file


As for item 1, it's not so difficult because the UI components I need are few.
Except for the 1.3 HTML viewer, I spent some time to make it work.

First of all, the component to display html content on android is
android.webkit.WebView
You can create this component in the resource and find it by id in the java source code.

Secondly, you need to add a permission line in the Manifest xml file in order to have the access to load URLs.
<uses-permission android:name="android.permission.INTERNET" />

Since I will only use this component to display the processed results of the html, I don't have to study too much about what actions it supports.

As for 2, 3, and 4, I will update later once I know how to accomplish them.

voila, here's the result of today's work:

IMAG0427 (by plateaukao)

****

好久沒到韓風饌吃東西了。
久久吃一次也是不錯的。
新拿到的傢伙太大隻了。
拍起照來手會不穩。
不過,看電子書應該很過癮吧。

IMAG0319 (by plateaukao)

2009/06/10

日文一級文法 (4)

P2181785 (by plateaukao)
Rome.Italie

にもまして / 更…;更加…

以前にもまして、彼の日本語は上達している。

〜たところで / 即使…;即使…也;就是…也…

いまさらダイエットをしたところで、意味がない。

ものを... / 可是;然而;卻



なりに、なりの / 獨特的

mixiを自分なりにリニューアルしてみた。

2009/06/09

食記 羊肉麵 / 燉奶

_1282212 (by plateaukao)
Flower

IMAG0086 (by plateaukao)

中午和同事到橋另一邊的羊肉麵店吃飯。
太陽很大,不過進了店的最裡頭,就涼快多了。

IMAG0087 (by plateaukao)
我點的是羊肉麵。
除了幾塊很嫩的羊肉之外,就是灑在上頭的香菜。
就配料來看,其實不算多。
不知道一般在吃羊肉麵是不是也會加酸菜呢?

IMAG0088 (by plateaukao)
另外大家還合點了一碗鴨血,剛好一人一塊。
這兒的鴨血有入味,所以很好吃。

臨走前,還買了支百香果的冰棒。
30元一支,有點貴,不過…看在是手工做的份上,就別計較那麼多了。

****

IMAG0090 (by plateaukao)
晚上比較早離開公司(說早,也是九點的事了
騎車到仁愛路上的一家港式甜點店,
吃台北不常見的燉奶。

IMAG0093 (by plateaukao)
這次叫的是冰芒果燉奶。
吃起來的感覺還是一樣順口。
不過芒果沒有很冰,有點常溫的感覺。
不曉得讓它熱一點或是冰一點,是不是會更搭一點呢?

****

工作沒有什麼動力了。
還是吃吃東西吧。

沒有目標

R8075148.JPG (by plateaukao)
House with iron ladders.Hong Kong

印象中在日劇中很常出現的鐵樓梯。
在長洲這個無車的小島上也隨處可見。

****

The Big Bang Theory,之前看過幾集。
這一兩天又把它收集了一下,打算花些時間再看看。
沒想到一收集,竟然收集到法文版的。
原本英文版的對話就已經夠快,又難懂了。
現在在換成法文,就更加難懂了。

扣掉專業的討論不算,單純的對話似乎沒有想像中的難。
我想,這應該是因為重新配音的關係吧,咬字和發音都會特別清楚。

2009/06/08

First Android program on real device

R8072380
Pipes.Paris

It's hard to put all the lines in order. So does the life.

****
Finally, I wrote my first android program and put it on the device. Although it's just a small hello world program, it took me some time install the necessary development tools and read some conceptual documents.

From now on, I can start to do some real programming. I plan to port my onlindic to android platform. It's a system to live with internet access; so is my onlinedic (although now it supports local dictionary files already). Hope this can be done in this summer.

The following reference is a tool that can help you to quickly create the UI layout for android applications.

REF:
http://code.google.com/p/droiddraw/

2009/06/07

vimperator 2.0 tips

R8075502.JPG
油條.Taipei

I've been using Firefox + vimperator 2.0 for quite some time. It makes my browsing experiences as smoothly as the silk. Today, I found some tips about how to make vimperator even better! These tips exist long before I found them. It's a pity that I did not do much survey on this before.

First of all, some key mappings to make navigation more easily:

map <c-c> Y
map <c-g> YP
map j 8<c-e>
map k 8<c-y>
map H gT
map L gt


With these settings, you can use copy keyboard shortcut as before; the movement of pressing j and k is more obvious now (8 lines each time); and change among the tabs by H and L. It's easier than gt/gT or C-n, C-p.

Another good tip that I can't find til today: to disable system input method while switching to command line mode.

style -name commandline-ime chrome://* #liberator-commandline-command input {ime-mode: inactive;}

Moreover, starting from vimperator 2.0, it supports colorscheme just as vim does. You can download several color schemes from following link:

http://github.com/VoQn/vimperator-colorscheme/tree

To jump quickly within current opened tabs, you can turn on the numbering label on tabs by following setting:

set guioptions=n/N

N means displaying the number on the tab icon; n means displaying the number after the icon.

Enfin Veuve

 R8075120.JPG
龍舟.Hong Kong

隔了很久,終於把它看玩了。




REF:
http://www.imdb.com/title/tt1024899/

乩童警探 一二集

接連看了兩集。第一集還算新鮮,到了第二集就看得比較慢了。一來,劇情雖然常會提到乩童,但真的跟乩童又沒有什麼關係。第二集後半大概就猜出是怎麼一回事了,但還是很享受在作者解釋的過程。只是前面舖陳有點久,而且人物有點多,再加上我是斷斷續續的看,看到後來都快忘了誰是誰,或是誰曾經出過什麼...