xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thomas DeWeese <Thomas.DeWe...@Kodak.com>
Subject Re: Problem Using the getIntersectionList method
Date Fri, 29 Oct 2004 19:08:00 GMT
TJ Teegan wrote:

> I am pretty sure you have to use viewbox coordinates not screen 
> coordinates.

    Yes, getIntersectionList takes the SVGRect in the user
coordinate system of the svg element you call it on.  This
is the same as the 'viewBox' coordinate system.

>> From: Jorg Heymans <jh@domek.be>
>> Reply-To: "Batik Users" <batik-users@xml.apache.org>
>> To: batik-users@xml.apache.org
>> Subject: Re: Problem Using the getIntersectionList method
>> Date: Fri, 29 Oct 2004 17:38:26 +0200
>>
>> Hi !
>>
>> I just tried this but it doesn't have any effect. I am running batik 
>> (src from 9th October) inside an applet using client side crimson 
>> parser - but i really think this shouldn't make a difference...
>>
>> Do I need to specify x,y and width,height from the rectangle in 
>> viewboxcoordinates rather than screencoordinates maybe?
>>
>> Thanks for your help
>> Jorg
>>
>> TJ Teegan wrote:
>>
>>> Hi there,
>>>
>>> Try something like this:
>>>
>>> SVGRect rect = SVGDoc.getRootElement().createSVGRect();
>>> //
>>> //set the values for the rect element: width, height, etc.
>>> //
>>> SVGElement svge = SVGDoc.getRootElement().getViewportElement();
>>> NodeList nodes = SVGDoc.getRootElement().getIntersectionList(rect, 
>>> svge);
>>>
>>> I don't think you can use the root element as a paramater.  I use the 
>>> viewport instead and have not had any problems.
>>>
>>> Good Luck,
>>> TJ Teegan
>>>
>>>
>>>
>>>> From: Jorg Heymans <jh@domek.be>
>>>> Reply-To: "Batik Users" <batik-users@xml.apache.org>
>>>> To: batik-users@xml.apache.org
>>>> Subject: Re: Problem Using the getIntersectionList method
>>>> Date: Fri, 29 Oct 2004 16:41:20 +0200
>>>>
>>>> Hi,
>>>>
>>>> Is there a catch on how to use this function? I have statically 
>>>> defined a rectangle that should cover about 90% of my canvas, then call
>>>> doc.getRootElement().getEnclosureList(rectangle, 
>>>> doc.getRootElement()) where doc is the SVGDocument.
>>>>
>>>> My document is nothing but <svg> with a few <g> elements where
each 
>>>> <g> has a few <path> elements in it.
>>>>
>>>> Thoughts?
>>>> Jorg
>>>>
>>>> Thomas DeWeese wrote:
>>>>
>>>>> Hi,
>>>>>    I just delivered it.
>>>>>
>>>>>    You can pick it up tomorrow from the nightly build or
>>>>> you can get it from CVS immediately.
>>>>>
>>>>> TJ Teegan wrote:
>>>>>
>>>>>> Thanks a ton.
>>>>>>
>>>>>> I am assuming I should keep checking the nightly builds listed in

>>>>>> the CVS Repository for the next release.  Is that true?
>>>>>>
>>>>>> Thanks again,
>>>>>> TJ Teegan
>>>>>>
>>>>>>
>>>>>>> From: Andreas Neumann <neumann@karto.baug.ethz.ch>
>>>>>>> Reply-To: "Batik Users" <batik-users@xml.apache.org>
>>>>>>> To: Batik Users <batik-users@xml.apache.org>
>>>>>>> Subject: Re: Problem Using the getIntersectionList method
>>>>>>> Date: Fri, 08 Oct 2004 10:31:43 +0200
>>>>>>>
>>>>>>> good to hear.
>>>>>>>
>>>>>>> looking forward to using getIntersectionList() - I think it will

>>>>>>> be a very useful feature for webmapping applications.
>>>>>>>
>>>>>>> Andreas
>>>>>>>
>>>>>>> Thomas DeWeese wrote:
>>>>>>>
>>>>>>>> Hi TJ,
>>>>>>>>
>>>>>>>> TJ Teegan wrote:
>>>>>>>>
>>>>>>>>> I am trying to find all the elements in a given area.
 I am 
>>>>>>>>> assuming I should be using the getIntersectionList method,

>>>>>>>>> however I must be using it incorrectly because I always
get a 
>>>>>>>>> java.lang.Error when I call it.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>     That's because it isn't implemented yet (except in my
local 
>>>>>>>> copy
>>>>>>>> of Batik ;).  I've been working on this for the past couple
days.
>>>>>>>> Expect a delivery shortly (I'm wrapping up a few details
with
>>>>>>>> text and use elements).
>>>>>>>>
>>>>>>>>> Here is an example of the code I am using:
>>>>>>>>>
>>>>>>>>> public NodeList myMethod(){
>>>>>>>>>     SVGRect rect;
>>>>>>>>>     SVGElement ele;
>>>>>>>>>     NodeList nodes;
>>>>>>>>>
>>>>>>>>>     rect = SVGDocument.getRootElement().createSVGRect();
>>>>>>>>>     rect.setX(0);
>>>>>>>>>     rect.setY(0);
>>>>>>>>>     rect.setWidth(100);
>>>>>>>>>     rect.setHeight(100);
>>>>>>>>>     ele = SVGDocument.getRootElement();
>>>>>>>>>     nodes = 
>>>>>>>>> SVGDocument.getRootElement().getIntersectionList(rect,
ele);
>>>>>>>>>     return nodes;
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>> I apologize if this has been covered else where.  I searched

>>>>>>>>> the mail list archive but was unsuccessful in finding
an 
>>>>>>>>> answer.  Any help is appreciated.
>>>>>>>>>
>>>>>>>>> Thank you,
>>>>>>>>> TJ Teegan
>>>>
>>>>
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
>>>> For additional commands, e-mail: batik-users-help@xml.apache.org
>>>>
>>>
>>> _________________________________________________________________
>>> Don�t just search. Find. Check out the new MSN Search! 
>>> http://search.msn.click-url.com/go/onm00200636ave/direct/01/
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: batik-users-unsubscribe@xml.apache.org
>> For additional commands, e-mail: batik-users-help@xml.apache.org
>>
> 
> _________________________________________________________________
> Don’t just search. Find. Check out the new MSN Search! 
> http://search.msn.click-url.com/go/onm00200636ave/direct/01/
> 
> 
> ---------------------------------------------------------------------
> 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


Mime
View raw message