WebRenderer Swing and Server Edition

I use WebRenderer to export HTML5 pages to images on the server. The problem is that the only release that supports HTML5 is the swing version. However, I can use jar files from the swing version and create a new IMozillaBrowserCanvas object, rather than link it to a JFrame / JPanel and convert the html5 page without a GUI.

Are there any differences between swing and server when using IMozillaBrowserCanvas ? The only information I could find was:

WebRenderer Server Edition 4.0 scales better on the server and without any other Java browser configurations because rendering is not performed in the Swing Thread. Saving rendering from Swing Thread, and multi-threading rendering leads to improved scalability. [ Source ]

Also, what happens at the back when the spawnMozilla() method is called from the BrowserFactory class? As far as I know, this is just a clean java browser and does not work on the xserver server in the background.

0
source share
1 answer

I contacted the developer from WebRenderer. He said:

Basically, there are internal architectural differences between the server and Swing Editions WebRenderer. The server version was designed primarily for creating page images, while Swing Edition is a fully functional browser. However, this does not prevent Swing Edition is effectively used to create page images.

The API is similar, although the Server has convenient methods for various sizes / types of image generation, and in the Swing Edition more functions are available. The Mozilla base browser version is much more recent in Swing Edition, so it is able to render pages using technologies such as HTML5.

While rendering is done in Java, a Mozilla component is required to process each platform. It does not start xserver, but a call to spawnMozilla () will configure these native components, they are extracted to the .webrendererswing6 directory in the user's default home folder.

+2
source

All Articles