You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-users@xmlgraphics.apache.org by Mark Claassen <ma...@donnell.com> on 2003/08/14 23:06:20 UTC

initial transforms

Is there a reason that the initial transform stuff in SVGComponent and
GVTComponent were not fully implemented?  It looks like there was a
start to do this.  There is a method to get the initial transform, but
then it is just created as the identity transform in lots of places as
well.

I modified the code so that all uses of the "initialTransform" variables
were pointing to the instance in GVTComponent and everything (so far)
works fine.

Mark

---------------------
"Nonviolence is the answer to the crucial political and moral questions
of our time; the need for man to overcome oppression and violence
without resorting to oppression and violence. "
-- Martin Luther King Jr.

Mark Claassen
Donnell Systems, Inc.
300 S. St. Louis Blvd. Ste. 203 
South Bend, IN 46617
E-mail: mailto:mark.claassen@donnell.com
Voice: (574)232-3784
Fax: (574)232-4014


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


Re: initial transforms

Posted by Thomas DeWeese <Th...@Kodak.com>.
Mark Claassen wrote:
> We were experimenting with having the initial view set so that the whole
> document fit within the user's window.  I was wondering if using the
> initial transform was the way to go, that way we don't have to start
> rendering it one way, and then render it again, this time the way we
> want.

   This is not the way to go. What you describe is the default behaviour
of the canvas.  What you want to do is ensure that after setMySize is
called the JSVGCanvas has the size you want it to have.  It will
then adjust it's display to that size.  By putting it in the viewport
it is becoming as large as it want's to be, you should put additional
logic in setMySize to query the visibleRect and set the preferred size
to that (or something along those lines).

>>-----Original Message-----
>>From: Thomas DeWeese [mailto:Thomas.DeWeese@Kodak.com] 
>>Sent: Thursday, August 14, 2003 4:22 PM
>>To: Batik Users
>>Subject: Re: initial transforms
>>
>>
>>Mark Claassen wrote:
>>
>>>Is there a reason that the initial transform stuff in 
>>
>>SVGComponent and 
>>
>>>GVTComponent were not fully implemented?  It looks like there was a 
>>>start to do this.  There is a method to get the initial 
>>
>>transform, but 
>>
>>>then it is just created as the identity transform in lots 
>>
>>of places as 
>>
>>>well.
>>
>>    Originally this held the viewbox transform but that has 
>>now been moved into the SVG element.  So it does appear that 
>>it is now a useless remnent.
>>
>>
>>>I modified the code so that all uses of the "initialTransform" 
>>>variables were pointing to the instance in GVTComponent and 
>>
>>everything 
>>
>>>(so far) works fine.
>>
>>   You could create an IDENTITY_TRANSFORM static final 
>>variable and use that instead (it would be less potentially 
>>confusing).
>>
>>
>>>Mark
>>>
>>>---------------------
>>>"Nonviolence is the answer to the crucial political and moral 
>>>questions of our time; the need for man to overcome oppression and 
>>>violence without resorting to oppression and violence. "
>>>-- Martin Luther King Jr.
>>>
>>>Mark Claassen
>>>Donnell Systems, Inc.
>>>300 S. St. Louis Blvd. Ste. 203
>>>South Bend, IN 46617
>>>E-mail: mailto:mark.claassen@donnell.com
>>>Voice: (574)232-3784
>>>Fax: (574)232-4014
>>>
>>>
>>>
>>
>>---------------------------------------------------------------------
>>
>>>To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
>>>For additional commands, e-mail: batik-users-help@xml.apache.org
>>>
>>>
>>
>>
>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
>>For additional commands, e-mail: batik-users-help@xml.apache.org
>>
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: batik-users-help@xml.apache.org
> 
> 




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


RE: initial transforms

Posted by Mark Claassen <ma...@donnell.com>.
We were experimenting with having the initial view set so that the whole
document fit within the user's window.  I was wondering if using the
initial transform was the way to go, that way we don't have to start
rendering it one way, and then render it again, this time the way we
want.

Mark

> -----Original Message-----
> From: Thomas DeWeese [mailto:Thomas.DeWeese@Kodak.com] 
> Sent: Thursday, August 14, 2003 4:22 PM
> To: Batik Users
> Subject: Re: initial transforms
> 
> 
> Mark Claassen wrote:
> > Is there a reason that the initial transform stuff in 
> SVGComponent and 
> > GVTComponent were not fully implemented?  It looks like there was a 
> > start to do this.  There is a method to get the initial 
> transform, but 
> > then it is just created as the identity transform in lots 
> of places as 
> > well.
> 
>     Originally this held the viewbox transform but that has 
> now been moved into the SVG element.  So it does appear that 
> it is now a useless remnent.
> 
> > I modified the code so that all uses of the "initialTransform" 
> > variables were pointing to the instance in GVTComponent and 
> everything 
> > (so far) works fine.
> 
>    You could create an IDENTITY_TRANSFORM static final 
> variable and use that instead (it would be less potentially 
> confusing).
> 
> > Mark
> > 
> > ---------------------
> > "Nonviolence is the answer to the crucial political and moral 
> > questions of our time; the need for man to overcome oppression and 
> > violence without resorting to oppression and violence. "
> > -- Martin Luther King Jr.
> > 
> > Mark Claassen
> > Donnell Systems, Inc.
> > 300 S. St. Louis Blvd. Ste. 203
> > South Bend, IN 46617
> > E-mail: mailto:mark.claassen@donnell.com
> > Voice: (574)232-3784
> > Fax: (574)232-4014
> > 
> > 
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
> > For additional commands, e-mail: batik-users-help@xml.apache.org
> > 
> > 
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: batik-users-help@xml.apache.org
> 


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


Re: initial transforms

Posted by Thomas DeWeese <Th...@Kodak.com>.
Mark Claassen wrote:
> Is there a reason that the initial transform stuff in SVGComponent and
> GVTComponent were not fully implemented?  It looks like there was a
> start to do this.  There is a method to get the initial transform, but
> then it is just created as the identity transform in lots of places as
> well.

    Originally this held the viewbox transform but that has now
been moved into the SVG element.  So it does appear that it is now
a useless remnent.

> I modified the code so that all uses of the "initialTransform" variables
> were pointing to the instance in GVTComponent and everything (so far)
> works fine.

   You could create an IDENTITY_TRANSFORM static final variable
and use that instead (it would be less potentially confusing).

> Mark
> 
> ---------------------
> "Nonviolence is the answer to the crucial political and moral questions
> of our time; the need for man to overcome oppression and violence
> without resorting to oppression and violence. "
> -- Martin Luther King Jr.
> 
> Mark Claassen
> Donnell Systems, Inc.
> 300 S. St. Louis Blvd. Ste. 203 
> South Bend, IN 46617
> E-mail: mailto:mark.claassen@donnell.com
> Voice: (574)232-3784
> Fax: (574)232-4014
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: batik-users-help@xml.apache.org
> 
> 




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