xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Philip Arad" <philip_a...@hotmail.com>
Subject Re: Gamma correction in IE5.5
Date Mon, 07 Apr 2003 08:56:15 GMT
Dear Chris

Thanks for your reply.
There are no standard definition of the value of 1.942, it is used after
a serie of experiments to find the best correction, that will give best

For example:
We need to create a png that has the color:

iTabColor = "#708090";

We pass this attribute to the method that creates a SVG document:

public Document iSVGDocument;

 public void createSVGDocument() throws Exception
  iSVGDocument = createBaseDocument(iName);
  Element vRoot = iSVGDocument.getDocumentElement();
  createTabBodyElement(iSVGDocument, vRoot, iTabColor);
<------------------ here

 private void createTabBodyElement(Document aDoc, Element aRoot, String
  Element g;
  g = aDoc.createElementNS(iSvgNS, "g");
  g.setAttributeNS(null, "id", "TagBody");
  String vFillColor = "fill:" + aColor;
  g.setAttributeNS(null, "style", vFillColor); <-------------------------

Then we use:
vSVGFileURI = new File(aFullSVGFileName).toURL().toString();
TranscoderInput vInput = new TranscoderInput(vSVGFileURI);
PNGTranscoder vTranscoder = new PNGTranscoder();<-------------here we use
this one, as it is, to recieve the wrong color
vTranscoder.transcode(vInput, vOutput);

The color of the image recieved is:#657586 (darker).

For the color: #CCCCCC
I recieve:#C6C6C6

1)I have made a test with #FF0000 (red) and for this color there is no
2)There is no problem with Netscape/Mozilla.

My conclusion is that the problem is not Batik, but IE.


To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
For additional commands, e-mail: batik-users-help@xml.apache.org

View raw message