Hi Omar,
The "white line" is caused by your original background color 0xFFFFF0, which is nearly white.
At the edge of some objects (eg. a pie sector), because of anti-alias, your 0xFFFFF0 color will mix up with the sector color to create smooth anti-alias effect. So the color there is not exact 0xFFFFF0, but is still quite light. As you are using single color transparency, only 0xFFFFF0 will be treated as transparent. the mixed up edge color will not be treated as transparent. When you use a dark background, you will see it clearly as a light color border.
To solve the problem, there are two methods:
(a) Use alpha transparency. This is the perfect method to use transparency with anti-alais. However, note that IE 6 does not support alpha transparency (it will change the transparent color into grey). IE 7 or above, FireFox, Chrome and Safari supports alpha transparency. To use alpha transparency, please use Transparent as the background color, and then use $this->c->setTransparentColor(-1);
or
(b) Instead of using 0xFFFFF0 as the background color, please use background color very close to your real background, such as 0x010101 for your current case (and setTransparentColor(0x010101)). Although the border still exists, it is very hard to notice.
Hope this can help.
Regards
Peter Kwan |