Shekhar Bhati <firstname.lastname@example.org> wrote
on 09/18/2009 09:03:55 AM:
> We have this applet inside a jsp and we are setting the size by using
Setting the size of what?
> When I increase the size of the frame the new
area which appears is
> not active but when I refersh the page ,then it gets active so I
> thought probably the canvas resizing is not happening at runtime so
> thought of updatemanager thread.
Is stuff being rendered in the new area?
In squiggle the
canvas resizes as needed for the frame, perhaps you
at that code? (batik.apps.svgbrowser)
Really I'm not going to be able to help
you without a better
description of what you are doing.
> Please suggest.
> On Fri, Sep 18, 2009 at 4:04 PM, <email@example.com>
> > Hi Shekhar,
> > Shekhar Bhati <firstname.lastname@example.org> wrote on 09/18/2009
> >> I am facing an issue with activating the canvas on frame
> >> I am using batik to show complex images for my application.
> >> have some objects for which I have a functionality of
> >> highlight/unhighlight the objects. It works like when I click
> >> the object, it gets highlighted and when I click anywhere
> >> background it gets unhighlighted.
> > How do you receive the click events on the 'background'?
> > this is done by having a 'white' or transparent rectangle that
> > the entire canvas as the first thing in the SVG file (so it's
> > everything else).
> >> We have inherited the class JSVGScrollPane for scrollbars
as we have
> >> huge images.
> >> The issue is that ,the area which I can see on the first
go is active
> >> , but when I scroll(pan/zoom out) then the new area which
> >> not active, to make it active I have to refresh the page,
> >> unhighlight does not work on that area which appears after
> >> the page.
> > It sounds like your background rect for handling
> > cover the entire contents of the canvas. This is fairly
easy to test
> > by simply 'tinting' your background rectangle so you can see
> > My guess is that you are using x="0" y="0"
> > as the size of the rectangle - this will cover the 'initial'
> > but as you scroll or pan in/out it won't cover the full screen
> > The correct thing would be to calculate the actual
> > the document and use that to populate the rectangle dimensions.
> > simple thing to do is use something like:
> > 'x="-5000%" y="-5000%"
> >> I have heard about the update manager thread and also used
it at many
> >> places , but here I am not getting which code to put inside
> >> UpdateManager thread to make this hidden area active on scrolling
> >> runtime.
> > I don't think this is your problem. You could
> > the UpdateManager to update your background rectangles position/size
> > on scroll/zoom...
> To unsubscribe, e-mail: email@example.com
> For additional commands, e-mail: firstname.lastname@example.org