Re: [WSG] PNG Question

2005-11-14 Thread Ben Curtis


Only supported in IE 6 with a hack, kind of an ugly one too as it  
renders the PNG's transparent area with a mid gray until it has  
finished loading, I guess if it's on a small image it's ok.


I've had a lot of luck with PNG Behavior:
http://webfx.eae.net/dhtml/pngbehavior/pngbehavior.html

It's an .htc, which you may have to configure your server to deliver  
properly. You assign the behavior to the img elements via your CSS  
rules. Handles src changes to/from other pngs or non-pngs. (This only  
works with actual img tags; if you want to affect pngs as your  
background-image, then you should apply the filter directly in your  
CSS, and my advice is to make the image the same size as the  
container it's backgrounding.)


I've hacked this a bit, so that the img is visibility:hidden; until  
the htc loads/runs, avoiding the ghostly gray-background issues. The  
trick is that you must only do this if JS is running, otherwise you  
might wind up with a site with no images. (The hack is testing right  
now -- NRFPT.)


--

Ben Curtis : webwright
bivia : a personal web studio
http://www.bivia.com
v: (818) 507-6613




**
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list  getting help
**



Re: [WSG] PNG Question

2005-11-14 Thread Alan Trick
Terrence Wood wrote:
 Patrick H. Lauke said:
 
IE does not natively support 24 bit alpha transparency on PNGs without
some seriously hacky workarounds.
 
 
 ...which is to say that IE *does* support 8-bit transparency (i.e. same as
 gif).
 

That is about the only reason to ever use the GIF any more. Apart from
that GIF is pretty much useless. Everthing it can do PNG does better.
**
The discussion list for  http://webstandardsgroup.org/

 See http://webstandardsgroup.org/mail/guidelines.cfm
 for some hints on posting to the list  getting help
**



Re: [WSG] PNG Question

2005-11-14 Thread Patrick H. Lauke

Alan Trick wrote:

Terrence Wood wrote:

...which is to say that IE *does* support 8-bit transparency (i.e. same as
gif).


That is about the only reason to ever use the GIF any more.


And, as I mentioned, the fact that very old browsers don't know what a 
PNG is...which is only an issue if you know for sure that a sizeable 
part of your audience still uses these user agents (e.g. some government 
or education sites).


--
Patrick H. Lauke
__
re·dux (adj.): brought back; returned. used postpositively
[latin : re-, re- + dux, leader; see duke.]
www.splintered.co.uk | www.photographia.co.uk
http://redux.deviantart.com
__
Web Standards Project (WaSP) Accessibility Task Force
http://webstandards.org/
__
**
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list  getting help
**



Re: [WSG] PNG Question

2005-11-14 Thread Terrence Wood
Alan Trick said:
 ...which is to say that IE *does* support 8-bit transparency (i.e. same
 as
 gif).
 That is about the only reason to ever use the GIF any more. Apart from

I meant it supports png with 8-bit transparency.

kind regards
Terrence Wood.

**
The discussion list for  http://webstandardsgroup.org/

 See http://webstandardsgroup.org/mail/guidelines.cfm
 for some hints on posting to the list  getting help
**



[WSG] PNG Question

2005-11-13 Thread Joseph R. B. Taylor

Greetings all,

I wanted to see what people's comments were as to using .png's vs. .gifs 
these days.


I have a design that will require those nice transparency effects only a 
.png can provide if I want it to be just like the mockup.  Do most 
browsers support that yet, or do I have to go with the gif that has been 
carefully shaved?


If you care, the mockup is http://sausalito.sitesbyjoe.com/ and the 
shadow in question is on the logo - the problem is created by the 
pattern in the background behind it - blah blah blah.


Thanks,

Joe Taylor
http://sitesbyjoe.com

**
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list  getting help
**



Re: [WSG] PNG Question

2005-11-13 Thread Samuel Richardson
Only supported in IE 6 with a hack, kind of an ugly one too as it 
renders the PNG's transparent area with a mid gray until it has finished 
loading, I guess if it's on a small image it's ok.


Joseph R. B. Taylor wrote:


Greetings all,

I wanted to see what people's comments were as to using .png's vs. 
.gifs these days.


I have a design that will require those nice transparency effects only 
a .png can provide if I want it to be just like the mockup.  Do most 
browsers support that yet, or do I have to go with the gif that has 
been carefully shaved?


If you care, the mockup is http://sausalito.sitesbyjoe.com/ and the 
shadow in question is on the logo - the problem is created by the 
pattern in the background behind it - blah blah blah.


Thanks,

Joe Taylor
http://sitesbyjoe.com

**
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list  getting help
**



**
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list  getting help
**



Re: [WSG] PNG Question

2005-11-13 Thread Patrick H. Lauke

Joseph R. B. Taylor wrote:

I have a design that will require those nice transparency effects only a 
.png can provide if I want it to be just like the mockup.  Do most 
browsers support that yet, or do I have to go with the gif that has been 
carefully shaved?


IE does not natively support 24 bit alpha transparency on PNGs without 
some seriously hacky workarounds. 
http://www.alistapart.com/stories/pngopacity/


Also, if you're still getting visits from users of older browsers such 
as Netscape 4.x (yes, I know, less and less of a consideration, but 
worth mentioning nonetheless) GIF is the safest choice (as they don't 
even understand 8 bit PNGs).


P
--
Patrick H. Lauke
__
re·dux (adj.): brought back; returned. used postpositively
[latin : re-, re- + dux, leader; see duke.]
www.splintered.co.uk | www.photographia.co.uk
http://redux.deviantart.com
__
Web Standards Project (WaSP) Accessibility Task Force
http://webstandards.org/
__
**
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list  getting help
**



Re: [WSG] PNG Question

2005-11-13 Thread Patrick H. Lauke
Additionally: you may be best off using a fallback mechanism, so that 
browsers which are not capable of displaying 24 bit PNGs can still get 
*something*. An idea (by no means the best around) is my little 
experiment in PNG image replacement 
http://www.splintered.co.uk/experiments/19/


--
Patrick H. Lauke
__
re·dux (adj.): brought back; returned. used postpositively
[latin : re-, re- + dux, leader; see duke.]
www.splintered.co.uk | www.photographia.co.uk
http://redux.deviantart.com
__
Web Standards Project (WaSP) Accessibility Task Force
http://webstandards.org/
__
**
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list  getting help
**



Re: [WSG] PNG Question

2005-11-13 Thread Adam Hope

Hi

I've had fairly good results using PNGs, however IE on Windows does  
not support transparency in PNGs and usually replaces it with a grey  
filler colour. A situation at work meant I simply had to use some  
PNGs with transparency, and make them work in IE, which lead me to  
PieNG (http://www.bazon.net/mishoo/articles.epl?art_id=430) The  
script gets around the problem with some IE filters and a transparent  
gif.


It wasn't quite over though, I can't remember why now, but this  
script does not work on images which are not visible when the page  
loads e.g. those used for mouse over effects. I re-wrote some of it  
to remove that limitation and can dig it out if you like.


One last issue I had with PNGs was trying to match them to background  
colours specified in CSS which proved to be seriously hit and miss  
but if you play with the settings enough it can be done. The  
difference was only slight but enough to upset a few people.


Adam H

p.s. my first post on here...


Greetings all,

I wanted to see what people's comments were as to using .png's  
vs. .gifs these days.


I have a design that will require those nice transparency effects  
only a .png can provide if I want it to be just like the mockup.   
Do most browsers support that yet, or do I have to go with the gif  
that has been carefully shaved?


If you care, the mockup is http://sausalito.sitesbyjoe.com/ and the  
shadow in question is on the logo - the problem is created by the  
pattern in the background behind it - blah blah blah.


Thanks,

Joe Taylor
http://sitesbyjoe.com

**
The discussion list for  http://webstandardsgroup.org/

See http://webstandardsgroup.org/mail/guidelines.cfm
for some hints on posting to the list  getting help
**



Re: [WSG] PNG Question

2005-11-13 Thread Terrence Wood
Patrick H. Lauke said:
 IE does not natively support 24 bit alpha transparency on PNGs without
 some seriously hacky workarounds.

...which is to say that IE *does* support 8-bit transparency (i.e. same as
gif).

The other gotcha you need to watch out for is the gamma correction applied
by different browsers which can cause problems with color matching.

Futher discussion and comparision table at: http://hsivonen.iki.fi/png-gamma/

kind regards
Terrence Wood.


**
The discussion list for  http://webstandardsgroup.org/

 See http://webstandardsgroup.org/mail/guidelines.cfm
 for some hints on posting to the list  getting help
**