<br><br><div class="gmail_quote">On Tue, May 20, 2008 at 9:53 AM, bvh <<a href="mailto:bvh-osm@irule.be">bvh-osm@irule.be</a>> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="Ih2E3d">On Tue, May 20, 2008 at 02:34:03AM +0200, Francisco R. Santos wrote:<br>
> > > A custom XULRunner app is probably a bit heavyweight for what we want. I<br>
> > > would suggest that the YWMS team look into creating a lightweight<br>
> > > Firefox extension which uses some form of IPC to exchange data with the<br>
> > > running JOSM.<br>
> ><br>
> > So what we need is a firefox expert...<br>
> ><br>
> > I guess the alternative is a java native interface that invokes Gecko<br>
> > directly or something?<br>
> I already tested that way, but heavyweight components (XULRunner) don't<br>
> combine well with Swing components (JOSM). I have a very basic prototype<br>
> using a swing browser component (the Cobra library) inside JOSM displaying<br>
> an openlayers frame, but didn't have time to continue it. If anyone is<br>
> interested to continue it, I can give the sources or commit it to SVN.<br>
<br>
</div>Merkaartor from svn uses webkit for Y! images. This works really<br>
well : no external processes needed. This is both a technical<br>
advantage (obviously) as a legal advantage : less possibilities<br>
of Y! complaining we store and transmit their images.<br>
<br>
Maybe there is a webkit wrapper for java?<br>
<br></blockquote><div>The problem with all wrappers around native  libraries that I've tried are two: 1) all are heavyweight components, but JOSM is based on Swing, that uses lightweight components. They use different rendering technics and the heavyweight components are displayed always on top of the lightweight ones, so the heaviweight must be used hidden and requested to be displayed in a hidden image that in turn is displayed on the lightweight frame, and 2) creating this hidden image is veeeery slow, so it can't be used as a normal frame in the program.<br>
<br>BTW, the way I've been working with the new library is totally different from the YWMS approach. This new approach is to display a OpenLayers background, the same way that Potlatch, that updates automatically whenever the user pans or zooms. For this reason, problem 2) makes these wrappers not usable.<br>
<br>Regards,<br>Quico<br></div></div>