I tried to align the columns using valign attribute of the
Saturday, February 6, 2010
Fixed border problem around smiley icons
Fixed border problem around smiley icons. Default blogspot CSS has a border around the image, but Small Apple doesn't have that.
Note: Small Apple uses JavaScript to map the smiley class to gif.
Thursday, February 4, 2010
Reward points make a difference
A comparison of the rewards from the big three oil companies.
Assumptions:
- Pump formula 98
- $1.93/litre (3 Feb 2009)
- 12% discount (5% station + 7% credit card)
- Spend $1,000
- The reward points is used to redeem petrol voucher
| Caltex | 1 Thanks! point per litre. 1400 points for $40 petrol voucher. | 589 points ($1000 / (1.93 * 0.88)) Equivalent to $16.80 petrol voucher. |
| ExxonMobil | 1 Smiles point for every $1.25 spent. 750 points for $30 petrol voucher. | 800 points ($1000 / 1.25) Equivalent to $32 petrol voucher. |
| Shell | 1 Escape point per litre. 600 points for $20 petrol voucher. | 589 points ($1000 / (1.93 * 0.88)) Equivalent to $19.60 petrol voucher. |
As you can see, ExxonMobil has the best reward based on the current assumptions. The higher the price, the better the reward. However, if the price is very low, say $1/litre, then Shell has the best reward, and Caltex and ExxonMobil are about the same.
Wednesday, January 20, 2010
Ohhh, preferred platinum card
When I started working, there were two common credit cards: normal (S$30k annual income) and gold (S$60k annual income).
Just about anyone could get a normal credit card if they earn S$2,000 — most fresh grads do — so it was no big deal. (They crossed the $30k mark with bonuses and employer's CPF contribution.) People aspired to get the gold card as it signaled their earning power.
The gold card got easier and easier to apply for — everyone wanted one, you see. A few years later, it eventually became the same as the normal card, which was renamed the classic card. The platinum card, which was really prestigious in the past (S$100k annual income?), became the new gold card.
Fast forward another few years. I just recevied a platinum card to replace my soon-to-expire classic card. I don't want a platinum card. I don't want to pay the annual fees and I especially don't want to change my credit card number.
So I called up my bank to ask if I could continue with my classic card. No, it can't be done, the operator said, the platinum card is the classic card now.
(Except that it is free for the first 3 years rather than lifetime.)
Okay.
I checked a few banks' website and found that platinum is really the new normal! This must have happened a while ago. Can't blame me for not knowing as I live under a rock. ![]()
So what is considered prestigious these days? Black card, white card, signature card, preferred card; it depends on the bank. There are a few ways to tell: (i) high annual income requirement, (ii) high annual fees, (iii) high minimum required spending, (iv) by invitation only.
For me, I just need a card I can use to buy stuff online. Damn, I need to update all my accounts again. ![]()
My brief credit card history
| Corporate gold card | I like it for the easy-to-remember number and the company logo (well, it sets it apart). |
| Classic card | Some time later, I applied for a personal credit card, but I never used it, so I canceled it. |
| Classic card 2 | The corporate card was discontinued, so I had to apply for my own card again. |
| Classic card 3 | The old card was canceled when I reported a suspicious transaction. It turned out to be a mistake on my part. I was unable to keep the card — I was on the verge of memorizing the number. |
| Platinum card | My latest card. |
Sunday, January 17, 2010
jQuery 1.4 is out
Key milestones:
| Date | Version | Size | Zipped |
|---|---|---|---|
| Aug 2006 | 1.0 | 16.7 kB | 8.8 kB |
| Jul 2007 | 1.1.3 | 20.9 kB | 10.9 kB |
| May 2008 | 1.2.6 | 54.4 kB | 16.6 kB |
| Feb 2009 | 1.3.2 | 55.9 kB | 19.4 kB |
| Jan 2010 | 1.4 | 68.2 kB | 23.3 kB |
jQuery has grown very large over the years. Of course, it has also added much new functionality. However, I wonder if we will see jQuery Lite — a return to its 20+ kB roots, perhaps.
(A typical webpage may have just 3-10 kB of compressed JavaScript. Compare this to jQuery/jQuery UI's 50+ kB — the library is far bigger!)
What is so attractive about jQuery?
I'll have to say it is (i) easy-to-use, (ii) lite and, (iii) easily extensible.
Easy to use: jQuery makes it so much easier to manipulate the DOM. Its small size that makes it a no-brainer to use. However, it is not always true now.
Lite: jQuery is a library, not a framework. You can use any one of its functions standalone without having to learn anything else.
Extensible: it is trivial to add your own functions to jQuery.
jQuery is such a game-changer for me that I've decided to contribute to its cause — I've donated US$10 to them. ![]()
Sunday, January 10, 2010
The hunt for dead pixels
A friend got a new plasma HDTV and asked me to help him spot dead pixels. Without a video diagnostics disc, the easiest way is to hook up a notebook to the TV and set the desktop wallpaper to a solid color.
In the past, I only checked black and white screens. Black is to spot stuck pixels, and white is to spot dead pixels.
Stuck pixels are very annoying, so there should not be any at all. Luckily, they are easy to spot. I've never seen stuck pixels on a new display, though.
In theory, checking the white screen for dead pixels is sufficient because as long as any of the RGB sub-pixels are not working, it won't show up as white. While this is true, it turns out that white is the hardest to check. I have never caught a dead pixel without knowing where it was.
Online wisdom is to check the R, G and B components separately. For completeness, I also check Cyan (G-B), Magenta (R-B) and Yellow (R-G).
Checking individual components is easier than white. It is either the color or black. Even so, it is not easy to spot a dead pixel. You have to scan the screen at a nose's length away. (But once you spotted one, you can see it from 1-2 metres away.) A plasma screen makes it harder due to its inherent noise.
After 45 minutes — 1920 x 1080 is a lot of pixels — I spotted one fully dead red pixel and two partially dead blue and red pixels. I thought the dead red pixel was a dead RGB pixel, but the macro photo showed that it was just the red pixel.
There are three levels of severity:
- Fully dead RGB pixel: obvious (relatively speaking), but also very rare.
- Single dead sub-pixel: not obvious, but once you found it, you can spot it again easily (within 2 metres).
- Partially dead sub-pixel: hard to find even though you know where it is
The dead pixels are all at the peripheral, so I recommend to my friend to keep his unit. I also decided to do him a favour by not telling him the location of the dead pixels. ![]()
(My own LCD TV has one fully dead pixel and several partially dead pixels. The dead pixel is an eye sore — if I look at it. The other dead pixels are not noticeable. I missed all of them until I saw the dead pixel by chance a few months after I got the TV.
)
Saturday, January 9, 2010
Finally, a netbook I can live with
Netbooks have always been too small and too slow for me, but no longer. Enter the Asus Eee PC 1201N: 1.6 GHz dual-core Atom, 2 GB RAM, ION, 12.1" (1366x768), 250GB HD at 1.45 kg and US$500.
It does not have a built-in optical drive and is a little on the heavy side, but hey, you can't expect everything to be perfect.
Atom is good enough for office apps and surfing net, but it is too slow for playing 720p videos. That's where the ION comes in: dedicated graphics. With it, netbooks can play 1080p videos without a hitch.
(The dual-core Atom N330 is a gimmick, though. It is actually meant for desktop use, so it has less power saving features — the 1201N can last just a little over 3 hours on battery. It is low by netbook standard, but it is good enough for me.)
The 1201N is almost perfect for me. However, it also almost triggered my instant-discard filter: an extra column of keys beside the backspace. I absolutely hated that. When I need to correct mistakes while touch-typing, I naturally use the edge of the notebook to "home".
Something I like about the 1201N: RAM. Unlike many other Atom netbooks, it can use more than 2 GB RAM. This is important as I need 3 GB RAM to run my apps comfortably.
Screen size
Most people feel that 10" is the perfect netbook size. However, I find it too small. 12" is the minimum for me — I'll be hard-pressed to even consider 11.6".
My ideal notebook
To me, a notebook is meant to be carried around, so I have always been willing to trade features/speed for weight. Specs:
- Light: 1.3 kg
- Small, but not too small: 12.1" (1280 x 800)
- Run apps and store files comfortably: 1.6 GHz dual-core CPU, 3 GB RAM, 120 GB HD
- 2.5 hours battery life
- Optional optical drive
- Able to play 720p video
- Backspace/enter by the right edge
- Must look sleek
There is one ultra-portable notebook that meets all my requirements: the HP EliteBook 2530p. Unfortunately, it is also very expensive. The Eee PC 1201N is the first netbook to meet most of them.
(Sidenote: the 1.3 kg 13.3" MSI X340 would have been the first if it had dual-core instead of one [Core2Solo]. Its keyboard was very flimsy and it had short battery life due to its 4-cell battery.)
12" is the battlefield
12" is where netbooks and ultra-portable notebooks will fight over for a while — and I believe netbooks will prevail. This is unfortunate because I want a notebook with a dual-core CULV CPU. No matter how you look at it, an Atom CPU is slow.
Tuesday, January 5, 2010
Do I have 1 TB or not?
A 1 TB HD has a capacity of 1,000,202,272,768 bytes, but it shows up as 931.5 GB. This is thanks to the use of binary units (1 kB = 1024 bytes) than the decimal SI units (1k = 1000).
Binary prefixes have been defined — KiB, MiB, GiB and TiB — but they are still not in common use.
AFAIK, only memory and flash are still using binary units to indicate their capacity — a 1 GB SD card is really 1 GiB. All others, including bandwidth and throughput, are in SI units.
Software
Software is a big issue. You'll never know whether it uses 1,000 or 1,024 unless you can see the actual number of bytes.
On my part, I'll try to do the right thing from now on and use k- for SI prefixes and Ki- for binary prefixes.