[dev-context] Wiki Text Problems.

Taco Hoekwater taco at elvenkind.com
Tue Sep 6 15:29:23 CEST 2005

Hi Mojca,

Mojca Miklavec wrote:
> I'm sorry. It was my request to use pngalpha for figures on background 
> that is not white (for "the question marks" for example, for math inside 
> tables with gray background, ...), so if anyone is to blame: please, 
> blame me!

I'll blame Microsoft.

Of course, Patrick could keep on using PNG transparancy with a
"IE renders this page badly, please upgrade to a decent browser"
remark in the side bar. I certainly wouldn't mind, but I'm not
sure how many of the reader potential of the wiki are IE based.

> I didn't notice any weird functionality on IE since I don't use it, but 
> Taco's observation is true (sad enough).

I also believe png is generally the better format, but because
I think you are a bit misinformed, here is some extra information:

> No, please, no GIFs!!! If it has to be, let's keep opaque PNGs, GIFs are 
> the very last option. Besides the licence (I don't know anything about 
> it), 

Gif is free, these days (the patent is finally expired)

> the number of colors is limited, 

True in general, but it has the same number of colors (256) that
ghostscripts "png256" device that the wiki uses. (more colors
leads to larger file sizes, and usually unneeded on the web).

>they aren't compressed (as PNGs 
> are) 

Gif images really are compressed, and in fact quite well, using
a variable-length LZW algorithm (that's what the patent was for).
Add to that that gif has a smaller file format overhead then PNG,
so it usually performs better (smaller files) than png for really
small images (icon/bullet size). Also, gif supports animation.

Gif format has it's uses in web design.

A 1 by 1 pixel transparant image, stored as compactly as possible
(gimp 2.0):

   43 bytes  empty.gif
   95 bytes  empty.png

A 32 by 32 pixels 256 color rainbow (from the pngsuite):

   1729 bytes   basi3p08.gif
   1527 bytes   basi3p08.png

> and I would say (althoug I don't claim it and I didn't take time to 
> check) that transparency is implemented as a "transparent color" rather 
> than transparent gradient in GIFs.

You are right. (if you want to, you can do transparancy in that way
inside a PNG image as well, btw. It allows smaller file sizes than a
full alpha channel).

> Shame on Microsoft!

Very, very, very much so!


More information about the dev-context mailing list